concepts::_SubMatrix_iterator< F, _Ref, _Ptr > Class Template Reference
STL like iterator for sub matrices. More...
#include <subMatrixIterator.hh>
Classes | |
struct | MatrixType |
Non-constant matrix for non-constant iterator. More... | |
struct | MatrixType< F_, const F::type &, const F::type * > |
Constant matrix for constant iterator. More... | |
Public Types | |
typedef _Matrix_iterator_base< value_type, _Ref, _Ptr > | _Base |
typedef _SubMatrix_iterator | _Self |
typedef _SubMatrix_iterator< F, const value_type &, const value_type * > | const_iterator |
typedef ptrdiff_t | difference_type |
typedef _SubMatrix_iterator< F, value_type &, value_type * > | iterator |
typedef std::forward_iterator_tag | iterator_category |
typedef MatrixType< F, _Ref, _Ptr >::type | matrix_type |
typedef _Ptr | pointer |
typedef _Ref | reference |
typedef _Base::return_type | return_type |
typedef size_t | size_type |
typedef F::type | value_type |
Public Member Functions | |
_SubMatrix_iterator () | |
Constructor. Iterator stands at the end of any matrix. More... | |
template<class _RefR , class _PtrR > | |
_SubMatrix_iterator (const _SubMatrix_iterator< F, _RefR, _PtrR > &__x) | |
Copy constructor. Also from iterator to constant iterator. More... | |
_SubMatrix_iterator (matrix_type &m, uint r=0) | |
Constructor. More... | |
unsigned int | col () const |
Column. More... | |
MatrixType< F, _Ref, _Ptr >::iterator * | i () const |
const MatrixType< F, _Ref, _Ptr >::iterator * | iend () const |
Set< IndexRange >::index_iterator * | iI () const |
bool | last () const |
Returns true, if iterator is behind the last entry. More... | |
const Set< IndexRange >::index_iterator * | lastI () const |
matrix_type * | m () const |
const unsigned int | nofCols () const |
Number of columns. More... | |
const unsigned int | nofRows () const |
Number of rows. More... | |
return_type | operator* () const |
Dereferencation. More... | |
_Self & | operator++ () |
Increment operator. More... | |
_Self | operator++ (int) |
pointer | operator-> () const |
Returns a pointer to the value. More... | |
template<class _RefR , class _PtrR > | |
_Self & | operator= (const _SubMatrix_iterator< F, _RefR, _PtrR > &__x) |
Assignment. More... | |
unsigned int | row () const |
Row. More... | |
Protected Member Functions | |
virtual std::ostream & | info (std::ostream &os) const |
Returns information in an output stream. More... | |
Protected Attributes | |
unsigned int | col_ |
bool | last_ |
Iterator is behind the last entrance. More... | |
const unsigned int | nofCols_ |
const unsigned int | nofRows_ |
Number of rows and columns. More... | |
unsigned int | row_ |
Current row and column. More... | |
Private Member Functions | |
_Self & | next_ () |
If the iterator is not standing inside submatrix, raise until it's standing inside. More... | |
Private Attributes | |
std::shared_ptr< typename MatrixType< F, _Ref, _Ptr >::iterator > | i_ |
Iterator over matrix entries. More... | |
std::shared_ptr< const typename MatrixType< F, _Ref, _Ptr >::iterator > | iend_ |
Iterator behind last matrix entry. More... | |
std::shared_ptr< Set< IndexRange >::index_iterator > | iI_ |
Iterator over row index range. More... | |
std::shared_ptr< const Set< IndexRange >::index_iterator > | lastI_ |
Iterator behind the last row index. More... | |
matrix_type * | m_ |
Super matrix. More... | |
Detailed Description
template<class F, class _Ref, class _Ptr>
class concepts::_SubMatrix_iterator< F, _Ref, _Ptr >
STL like iterator for sub matrices.
- Parameters
-
F matrix type _Ref reference type of values _Ptr pointer type to values
Definition at line 28 of file subMatrixIterator.hh.
Member Typedef Documentation
◆ _Base
typedef _Matrix_iterator_base<value_type, _Ref, _Ptr> concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::_Base |
Definition at line 42 of file subMatrixIterator.hh.
◆ _Self
typedef _SubMatrix_iterator concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::_Self |
Definition at line 41 of file subMatrixIterator.hh.
◆ const_iterator
typedef _SubMatrix_iterator<F, const value_type&,const value_type*> concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::const_iterator |
Definition at line 49 of file subMatrixIterator.hh.
◆ difference_type
typedef ptrdiff_t concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::difference_type |
Definition at line 40 of file subMatrixIterator.hh.
◆ iterator
typedef _SubMatrix_iterator<F, value_type&, value_type*> concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::iterator |
Definition at line 47 of file subMatrixIterator.hh.
◆ iterator_category
typedef std::forward_iterator_tag concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::iterator_category |
Definition at line 35 of file subMatrixIterator.hh.
◆ matrix_type
typedef MatrixType<F, _Ref, _Ptr>::type concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::matrix_type |
Definition at line 43 of file subMatrixIterator.hh.
◆ pointer
typedef _Ptr concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::pointer |
Definition at line 37 of file subMatrixIterator.hh.
◆ reference
typedef _Ref concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::reference |
Definition at line 38 of file subMatrixIterator.hh.
◆ return_type
typedef _Base::return_type concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::return_type |
Definition at line 44 of file subMatrixIterator.hh.
◆ size_type
typedef size_t concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::size_type |
Definition at line 39 of file subMatrixIterator.hh.
◆ value_type
typedef F::type concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::value_type |
Definition at line 36 of file subMatrixIterator.hh.
Constructor & Destructor Documentation
◆ _SubMatrix_iterator() [1/3]
concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::_SubMatrix_iterator | ( | matrix_type & | m, |
uint | r = 0 |
||
) |
Constructor.
- Parameters
-
m matrix r row
◆ _SubMatrix_iterator() [2/3]
concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::_SubMatrix_iterator | ( | ) |
Constructor. Iterator stands at the end of any matrix.
◆ _SubMatrix_iterator() [3/3]
|
inline |
Copy constructor. Also from iterator to constant iterator.
Definition at line 61 of file subMatrixIterator.hh.
Member Function Documentation
◆ col()
|
inlineinherited |
Column.
Definition at line 75 of file matrixIterator.hh.
◆ i()
|
inline |
Definition at line 109 of file subMatrixIterator.hh.
◆ iend()
|
inline |
Definition at line 112 of file subMatrixIterator.hh.
◆ iI()
|
inline |
Definition at line 115 of file subMatrixIterator.hh.
◆ info()
|
protectedvirtual |
Returns information in an output stream.
Reimplemented from concepts::_Matrix_iterator_base< F::type, _Ref, _Ptr >.
◆ last()
|
inlineinherited |
Returns true, if iterator is behind the last entry.
Definition at line 77 of file matrixIterator.hh.
◆ lastI()
|
inline |
Definition at line 116 of file subMatrixIterator.hh.
◆ m()
|
inline |
Definition at line 119 of file subMatrixIterator.hh.
◆ next_()
|
private |
If the iterator is not standing inside submatrix, raise until it's standing inside.
◆ nofCols()
|
inlineinherited |
Number of columns.
Definition at line 71 of file matrixIterator.hh.
◆ nofRows()
|
inlineinherited |
Number of rows.
Definition at line 69 of file matrixIterator.hh.
◆ operator*()
|
inline |
Dereferencation.
Definition at line 75 of file subMatrixIterator.hh.
◆ operator++() [1/2]
_Self& concepts::_SubMatrix_iterator< F, _Ref, _Ptr >::operator++ | ( | ) |
Increment operator.
◆ operator++() [2/2]
|
inline |
Definition at line 103 of file subMatrixIterator.hh.
◆ operator->()
|
inline |
Returns a pointer to the value.
Definition at line 80 of file subMatrixIterator.hh.
◆ operator=()
|
inline |
Assignment.
Definition at line 87 of file subMatrixIterator.hh.
◆ row()
|
inlineinherited |
Row.
Definition at line 73 of file matrixIterator.hh.
Member Data Documentation
◆ col_
|
protectedinherited |
Definition at line 93 of file matrixIterator.hh.
◆ i_
|
private |
Iterator over matrix entries.
Definition at line 124 of file subMatrixIterator.hh.
◆ iend_
|
private |
Iterator behind last matrix entry.
Definition at line 126 of file subMatrixIterator.hh.
◆ iI_
|
private |
Iterator over row index range.
Definition at line 128 of file subMatrixIterator.hh.
◆ last_
|
protectedinherited |
Iterator is behind the last entrance.
Definition at line 95 of file matrixIterator.hh.
◆ lastI_
|
private |
Iterator behind the last row index.
Definition at line 130 of file subMatrixIterator.hh.
◆ m_
|
private |
Super matrix.
Definition at line 132 of file subMatrixIterator.hh.
◆ nofCols_
|
protectedinherited |
Definition at line 91 of file matrixIterator.hh.
◆ nofRows_
|
protectedinherited |
Number of rows and columns.
Definition at line 91 of file matrixIterator.hh.
◆ row_
|
protectedinherited |
Current row and column.
Definition at line 93 of file matrixIterator.hh.
The documentation for this class was generated from the following file:
- operator/subMatrixIterator.hh