Public Types | |
typedef ACCESSOR::MatrixType | MatrixType |
Public Member Functions | |
MatrixIterator (MatrixType *matrix, const unsigned int row=0, const unsigned int index=0) | |
template<class OtherAccessor > | |
MatrixIterator (const MatrixIterator< OtherAccessor > &other) | |
MatrixIterator & | operator++ () |
MatrixIterator | operator++ (int) |
const ACCESSOR & | operator* () const |
const ACCESSOR * | operator-> () const |
bool | operator== (const MatrixIterator &) const |
bool | operator!= (const MatrixIterator &) const |
bool | operator< (const MatrixIterator &) const |
bool | operator> (const MatrixIterator &) const |
Private Attributes | |
ACCESSOR | accessor |
Friends | |
class | MatrixIterator |
This iterator is abstracted from the actual matrix type and can be used for any matrix having the required ACCESSOR type.
typedef ACCESSOR::MatrixType MatrixIterator< ACCESSOR >::MatrixType |
Typedef for the matrix type (including constness) we are to operate on.
MatrixIterator< ACCESSOR >::MatrixIterator | ( | MatrixType * | matrix, | |
const unsigned int | row = 0 , |
|||
const unsigned int | index = 0 | |||
) | [inline] |
Constructor. Create an iterator into the matrix matrix
for the given row
and the index
within it.
MatrixIterator< ACCESSOR >::MatrixIterator | ( | const MatrixIterator< OtherAccessor > & | other | ) | [inline] |
Copy from another matrix iterator. Mostly implemented to allow initialization of a constant iterator from a non constant, this function only requires that a conversion from the other iterator's accessor to this accessor object is possible.
MatrixIterator< ACCESSOR > & MatrixIterator< ACCESSOR >::operator++ | ( | ) | [inline] |
Prefix increment.
References MatrixIterator< ACCESSOR >::accessor.
MatrixIterator< ACCESSOR > MatrixIterator< ACCESSOR >::operator++ | ( | int | ) | [inline] |
Postfix increment.
References MatrixIterator< ACCESSOR >::accessor.
const ACCESSOR & MatrixIterator< ACCESSOR >::operator* | ( | ) | const [inline] |
Dereferencing operator.
References MatrixIterator< ACCESSOR >::accessor.
const ACCESSOR * MatrixIterator< ACCESSOR >::operator-> | ( | ) | const [inline] |
Dereferencing operator.
References MatrixIterator< ACCESSOR >::accessor.
bool MatrixIterator< ACCESSOR >::operator== | ( | const MatrixIterator< ACCESSOR > & | other | ) | const [inline] |
Comparison. True, if both accessors are equal.
References MatrixIterator< ACCESSOR >::accessor.
bool MatrixIterator< ACCESSOR >::operator!= | ( | const MatrixIterator< ACCESSOR > & | other | ) | const [inline] |
Inverse of ==
.
bool MatrixIterator< ACCESSOR >::operator< | ( | const MatrixIterator< ACCESSOR > & | other | ) | const [inline] |
Comparison operator. Result is true if either the first row number is smaller or if the row numbers are equal and the first index is smaller.
This function is only valid if both iterators point into the same matrix.
References MatrixIterator< ACCESSOR >::accessor, and Assert.
bool MatrixIterator< ACCESSOR >::operator> | ( | const MatrixIterator< ACCESSOR > & | other | ) | const [inline] |
Comparison operator. Works in the same way as above operator, just the other way round.
friend class MatrixIterator [friend] |
Allow other iterators access to private data.
ACCESSOR MatrixIterator< ACCESSOR >::accessor [private] |
Store an object of the accessor class.
Referenced by MatrixIterator< ACCESSOR >::operator*(), MatrixIterator< ACCESSOR >::operator++(), MatrixIterator< ACCESSOR >::operator->(), MatrixIterator< ACCESSOR >::operator<(), and MatrixIterator< ACCESSOR >::operator==().