DUNE PDELab (git)

Dune::Amg::Hierarchy< T, A >::LevelIterator< C, T1 > Class Template Reference

Iterator over the levels in the hierarchy. More...

#include <dune/istl/paamg/hierarchy.hh>

Public Types

typedef LevelIterator< C, T1 > DerivedType
 The type of derived iterator. More...
 
typedef T1 Value
 The type of value accessed through the iterator.
 
typedef T1 * Pointer
 The pointer to the Value.
 
typedef std::ptrdiff_t DifferenceType
 The type of the difference between two positions.
 
typedef T1 & Reference
 The type of the reference to the values accessed.
 

Public Member Functions

 LevelIterator ()=default
 Constructor.
 
template<class C_ , class T1_ , std::enable_if_t< std::is_same_v< std::remove_const_t< C >, std::remove_const_t< C_ > >, int > = 0, std::enable_if_t< std::is_same_v< std::remove_const_t< T1 >, std::remove_const_t< T1_ > >, int > = 0>
 LevelIterator (const LevelIterator< C_, T1_ > &other)
 Copy constructor.
 
bool equals (const LevelIterator< typename std::remove_const< C >::type, typename std::remove_const< T1 >::type > &other) const
 Equality check.
 
bool equals (const LevelIterator< const typename std::remove_const< C >::type, const typename std::remove_const< T1 >::type > &other) const
 Equality check.
 
T1 & dereference () const
 Dereference the iterator.
 
void increment ()
 Move to the next coarser level.
 
void decrement ()
 Move to the next fine level.
 
bool isRedistributed () const
 Check whether there was a redistribution at the current level. More...
 
T1 & getRedistributed () const
 Get the redistributed container. More...
 
Reference operator* () const
 Dereferencing operator.
 
DerivedTypeoperator++ ()
 Preincrement operator.
 
DerivedType operator++ (int)
 Postincrement operator.
 
DerivedTypeoperator-- ()
 Preincrement operator.
 
DerivedType operator-- (int)
 Postincrement operator.
 

Detailed Description

template<typename T, typename A = std::allocator<T>>
template<class C, class T1>
class Dune::Amg::Hierarchy< T, A >::LevelIterator< C, T1 >

Iterator over the levels in the hierarchy.

operator++() moves to the next coarser level in the hierarchy. while operator--() moves to the next finer level in the hierarchy.

Member Typedef Documentation

◆ DerivedType

typedef LevelIterator< C, T1 > Dune::BidirectionalIteratorFacade< LevelIterator< C, T1 > , T1 , T1 & , std::ptrdiff_t >::DerivedType
inherited

The type of derived iterator.

The iterator has to define following functions have to be present:

// Access the value referred to.
// Compare for equality with j
bool equals(j);
// position the iterator at the next element.
void increment()
// position the iterator at the previous element.
void decrement()
T1 & dereference() const
Dereference the iterator.
Definition: hierarchy.hh:170
bool equals(const LevelIterator< typename std::remove_const< C >::type, typename std::remove_const< T1 >::type > &other) const
Equality check.
Definition: hierarchy.hh:154
void increment()
Move to the next coarser level.
Definition: hierarchy.hh:176
void decrement()
Move to the next fine level.
Definition: hierarchy.hh:182
T1 & Reference
The type of the reference to the values accessed.
Definition: iteratorfacades.hh:330

For an elaborate explanation see the STL Documentation

Member Function Documentation

◆ getRedistributed()

template<typename T , typename A = std::allocator<T>>
template<class C , class T1 >
T1 & Dune::Amg::Hierarchy< T, A >::LevelIterator< C, T1 >::getRedistributed ( ) const
inline

Get the redistributed container.

Returns
The redistributed container.

◆ isRedistributed()

template<typename T , typename A = std::allocator<T>>
template<class C , class T1 >
bool Dune::Amg::Hierarchy< T, A >::LevelIterator< C, T1 >::isRedistributed ( ) const
inline

Check whether there was a redistribution at the current level.

Returns
True if there is a redistributed version of the container at the current level.

The documentation for this class was generated from the following file:
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Nov 24, 23:30, 2024)