SpinParser
1.0
|
Sublattice iterator object. More...
#include <Lattice.hpp>
Public Member Functions | |
SublatticeIterator (int *allowedIds) | |
Construct a new SublatticeIterator object over a list of representative ids. More... | |
SublatticeIterator & | operator++ () |
Prefix increment operator. More... | |
SublatticeIterator & | operator-- () |
Prefix decrement operator. More... | |
![]() | |
LatticeIterator () | |
Construct a new LatticeIterator object, which points to the representative id 0 per default. | |
LatticeIterator (int id) | |
Construct a new LatticeIterator object and initialize it to any representative id. More... | |
bool | operator== (const LatticeIterator &rhs) const |
Comparison operator. More... | |
bool | operator!= (const LatticeIterator &rhs) const |
Negative comparison operator. More... | |
int | operator- (const LatticeIterator &rhs) const |
Subtraction operator. More... | |
Protected Attributes | |
int | offset |
Offset relative to the first entry of SublatticeIterator::allowedIds. | |
int * | allowedIds |
List of representative ids that make up the sublattice. Memory is not owned by the iterator. | |
![]() | |
int | id |
Representative id which the iterator points to. | |
Sublattice iterator object.
|
inline |
Construct a new SublatticeIterator object over a list of representative ids.
The SublatticeIterator does not take ownership of the list. It must be guaranteed that the list remains valid during the entire lifetiem of the iterator object. The list mus be terminated by a lattice->end() entry.
allowedIds | List of representative ids that make up the sublattice. Must be terminated by lattice->end(). |
|
inlinevirtual |
Prefix increment operator.
Reimplemented from LatticeIterator.
|
inlinevirtual |
Prefix decrement operator.
Reimplemented from LatticeIterator.