ARTS 2.5.4 (git: 4c0d3b4d)
|
The iterator class for sub vectors. More...
#include <matpackI.h>
Public Types | |
using | difference_type = Index |
using | value_type = Numeric |
using | pointer = Numeric * |
using | reference = Numeric & |
using | iterator_category = std::random_access_iterator_tag |
Public Member Functions | |
Iterator1D ()=default | |
Default constructor. More... | |
Iterator1D (Numeric *x, Index stride) ARTS_NOEXCEPT | |
Explicit constructor. More... | |
Iterator1D & | operator++ () ARTS_NOEXCEPT |
Prefix increment operator. More... | |
Numeric & | operator* () const ARTS_NOEXCEPT |
Dereferencing. More... | |
bool | operator!= (const Iterator1D &other) const ARTS_NOEXCEPT |
Not equal operator, needed for algorithms like copy. More... | |
bool | operator== (const Iterator1D &other) const ARTS_NOEXCEPT |
Index | operator- (const Iterator1D &other) const ARTS_NOEXCEPT |
Private Attributes | |
Numeric * | mx {nullptr} |
Current position. More... | |
Index | mstride {0} |
Stride. More... | |
Friends | |
void | copy (ConstIterator1D origin, const ConstIterator1D &end, Iterator1D target) |
Copy data between begin and end to target. More... | |
The iterator class for sub vectors.
This takes into account the defined stride.
Definition at line 395 of file matpackI.h.
using Iterator1D::difference_type = Index |
Definition at line 397 of file matpackI.h.
using Iterator1D::iterator_category = std::random_access_iterator_tag |
Definition at line 401 of file matpackI.h.
using Iterator1D::pointer = Numeric* |
Definition at line 399 of file matpackI.h.
using Iterator1D::reference = Numeric& |
Definition at line 400 of file matpackI.h.
using Iterator1D::value_type = Numeric |
Definition at line 398 of file matpackI.h.
|
default |
Default constructor.
Explicit constructor.
Definition at line 407 of file matpackI.h.
|
inline |
Not equal operator, needed for algorithms like copy.
Definition at line 424 of file matpackI.h.
References mx.
Referenced by operator==().
|
inline |
|
inline |
|
inline |
Definition at line 433 of file matpackI.h.
|
inline |
Definition at line 429 of file matpackI.h.
References operator!=().
|
friend |
Copy data between begin and end to target.
Target must be a valid area of memory. Note that the strides in the iterators can be different, so that we can for example copy data between different kinds of subvectors.
Definition at line 304 of file matpackI.cc.
|
private |
|
private |
Current position.
Definition at line 447 of file matpackI.h.
Referenced by operator!=(), operator*(), operator++(), and operator-().