ARTS  2.0.49
Iterator2D Class Reference

The row iterator class for sub matrices. More...

#include <matpackI.h>

Public Member Functions

 Iterator2D ()
 Default constructor. More...
 
 Iterator2D (const Iterator2D &o)
 Copy constructor. More...
 
 Iterator2D (const VectorView &x, Index stride)
 Explicit constructor. More...
 
Iterator2Doperator++ ()
 Prefix increment operator. More...
 
bool operator!= (const Iterator2D &other) const
 Not equal operator, needed for algorithms like copy. More...
 
VectorViewoperator-> ()
 The -> operator is needed, so that we can write i->begin() to get the 1D iterators. More...
 
VectorViewoperator* ()
 Dereferencing. More...
 

Private Attributes

VectorView msv
 Current position. More...
 
Index mstride
 Row stride. More...
 

Detailed Description

The row iterator class for sub matrices.

This takes into account the defined row stride. The iterator points to a row of the matrix, which acts just like a VectorView.

Definition at line 459 of file matpackI.h.

Constructor & Destructor Documentation

◆ Iterator2D() [1/3]

Iterator2D::Iterator2D ( )
inline

Default constructor.

Definition at line 463 of file matpackI.h.

◆ Iterator2D() [2/3]

Iterator2D::Iterator2D ( const Iterator2D o)
inline

Copy constructor.

Definition at line 466 of file matpackI.h.

◆ Iterator2D() [3/3]

Iterator2D::Iterator2D ( const VectorView x,
Index  stride 
)
inline

Explicit constructor.

Definition at line 470 of file matpackI.h.

Member Function Documentation

◆ operator!=()

bool Iterator2D::operator!= ( const Iterator2D other) const
inline

Not equal operator, needed for algorithms like copy.

Definition at line 478 of file matpackI.h.

References ConstVectorView::mdata, ConstVectorView::mrange, Range::mstart, and msv.

◆ operator*()

VectorView& Iterator2D::operator* ( )
inline

Dereferencing.

Definition at line 491 of file matpackI.h.

References msv.

◆ operator++()

Iterator2D& Iterator2D::operator++ ( )
inline

Prefix increment operator.

Definition at line 475 of file matpackI.h.

References ConstVectorView::mdata, mstride, and msv.

◆ operator->()

VectorView* Iterator2D::operator-> ( )
inline

The -> operator is needed, so that we can write i->begin() to get the 1D iterators.

Definition at line 488 of file matpackI.h.

References msv.

Member Data Documentation

◆ mstride

Index Iterator2D::mstride
private

Row stride.

Definition at line 497 of file matpackI.h.

Referenced by operator++().

◆ msv

VectorView Iterator2D::msv
private

Current position.

Definition at line 495 of file matpackI.h.

Referenced by operator!=(), operator*(), operator++(), and operator->().


The documentation for this class was generated from the following file: