|
CoreComponents 3.0.0
A Modern C++ Toolkit
|
Array iterator More...
#include <cc/ArrayIterator>
Public Member Functions | |
| ArrayIterator (Container &c, long i) | |
| Create an array iterator pointing to the i-th item of array c. | |
| operator bool () const | |
| Check if this iterator is valid (explicitly cast to bool) | |
| ArrayIteratorItemAccess< Container >::Type | operator* () const |
| Get access to current item value. | |
| ArrayIterator & | operator++ () |
| Step to the next item and return the old iterator value (postfix increment operator) | |
| ArrayIterator & | operator-- () |
| Step to the previous item and return the old iterator value (postfix decrement operator) | |
| ArrayIterator | operator+ (long delta) |
| Get iterator value stepped delta items forward (addition operator) | |
| ArrayIterator | operator- (long delta) |
| Get iterator value stepped delta items backward (substraction operator) | |
| int | operator- (const ArrayIterator &b) const |
| Get distance between this and another iterator (substraction operator) | |
| bool | operator== (const ArrayIterator &b) const |
| Equality operator. | |
| std::strong_ordering | operator<=> (const ArrayIterator &b) const |
| Ordering operator. | |
Array iterator
| Container | Container type |
| Dir | Direction (1 for forward iterator, -1 for backward iterator) |
| ArrayIterator | ( | Container & | c, |
| long | i ) |
Create an array iterator pointing to the i-th item of array c.
|
explicit |
Check if this iterator is valid (explicitly cast to bool)
| ArrayIteratorItemAccess< Container >::Type operator* | ( | ) | const |
Get access to current item value.
| ArrayIterator & operator++ | ( | ) |
Step to the next item and return the old iterator value (postfix increment operator)
| ArrayIterator & operator-- | ( | ) |
Step to the previous item and return the old iterator value (postfix decrement operator)
| ArrayIterator operator+ | ( | long | delta | ) |
Get iterator value stepped delta items forward (addition operator)
| ArrayIterator operator- | ( | long | delta | ) |
Get iterator value stepped delta items backward (substraction operator)
| int operator- | ( | const ArrayIterator< Container, Dir > & | b | ) | const |
Get distance between this and another iterator (substraction operator)
| bool operator== | ( | const ArrayIterator< Container, Dir > & | b | ) | const |
Equality operator.
| std::strong_ordering operator<=> | ( | const ArrayIterator< Container, Dir > & | b | ) | const |
Ordering operator.