PLearn 0.1
|
Model of the Random Access Iterator concept for iterating through a single column of a TMat, one row at a time. More...
#include <TMatColRowsIterator_decl.h>
Model of the Random Access Iterator concept for iterating through a single column of a TMat, one row at a time.
The basic idea is that operator* returns a T for the given column of the current row. Very useful for passing to STL algorithms.
Definition at line 59 of file TMatColRowsIterator_decl.h.
typedef ptrdiff_t PLearn::TMatColRowsIterator< T >::difference_type |
Definition at line 65 of file TMatColRowsIterator_decl.h.
typedef random_access_iterator_tag PLearn::TMatColRowsIterator< T >::iterator_category |
Some useful typedefs.
Definition at line 63 of file TMatColRowsIterator_decl.h.
typedef T* PLearn::TMatColRowsIterator< T >::pointer |
Definition at line 66 of file TMatColRowsIterator_decl.h.
typedef T& PLearn::TMatColRowsIterator< T >::reference |
Definition at line 67 of file TMatColRowsIterator_decl.h.
typedef T PLearn::TMatColRowsIterator< T >::value_type |
Definition at line 64 of file TMatColRowsIterator_decl.h.
PLearn::TMatColRowsIterator< T >::TMatColRowsIterator | ( | ) | [inline] |
Definition at line 74 of file TMatColRowsIterator_decl.h.
PLearn::TMatColRowsIterator< T >::TMatColRowsIterator | ( | T * | p, |
int | m | ||
) | [inline] |
This constructor assumes that p points to the proper initial element.
Definition at line 78 of file TMatColRowsIterator_decl.h.
reference PLearn::TMatColRowsIterator< T >::operator* | ( | ) | [inline] |
Definition at line 86 of file TMatColRowsIterator_decl.h.
{ return *ptr; }
TMatColRowsIterator<T> PLearn::TMatColRowsIterator< T >::operator+ | ( | difference_type | n | ) | [inline] |
Definition at line 124 of file TMatColRowsIterator_decl.h.
References n.
{ TMatColRowsIterator<T> r(*this); r += n; return r; }
TMatColRowsIterator<T>& PLearn::TMatColRowsIterator< T >::operator++ | ( | ) | [inline] |
Definition at line 95 of file TMatColRowsIterator_decl.h.
TMatColRowsIterator<T> PLearn::TMatColRowsIterator< T >::operator++ | ( | int | ) | [inline] |
Definition at line 100 of file TMatColRowsIterator_decl.h.
TMatColRowsIterator<T>& PLearn::TMatColRowsIterator< T >::operator+= | ( | difference_type | n | ) | [inline] |
Definition at line 119 of file TMatColRowsIterator_decl.h.
TMatColRowsIterator<T> PLearn::TMatColRowsIterator< T >::operator- | ( | difference_type | n | ) | [inline] |
Definition at line 135 of file TMatColRowsIterator_decl.h.
References n.
{ TMatColRowsIterator<T> r(*this); r -= n; return r; }
difference_type PLearn::TMatColRowsIterator< T >::operator- | ( | const TMatColRowsIterator< T > & | y | ) | [inline] |
Definition at line 141 of file TMatColRowsIterator_decl.h.
References PLearn::TMatColRowsIterator< T >::ptr.
TMatColRowsIterator<T>& PLearn::TMatColRowsIterator< T >::operator-- | ( | ) | [inline] |
Definition at line 107 of file TMatColRowsIterator_decl.h.
TMatColRowsIterator<T> PLearn::TMatColRowsIterator< T >::operator-- | ( | int | ) | [inline] |
Definition at line 112 of file TMatColRowsIterator_decl.h.
TMatColRowsIterator<T>& PLearn::TMatColRowsIterator< T >::operator-= | ( | difference_type | n | ) | [inline] |
Definition at line 130 of file TMatColRowsIterator_decl.h.
reference PLearn::TMatColRowsIterator< T >::operator-> | ( | ) | [inline] |
< works if T is some kind
< of smart pointer
Definition at line 90 of file TMatColRowsIterator_decl.h.
{ return *ptr; }
bool PLearn::TMatColRowsIterator< T >::operator< | ( | const TMatColRowsIterator< T > & | y | ) | [inline] |
Definition at line 149 of file TMatColRowsIterator_decl.h.
{ return ptr < y.ptr; }
bool PLearn::TMatColRowsIterator< T >::operator== | ( | const TMatColRowsIterator< T > & | other | ) | const [inline] |
Definition at line 82 of file TMatColRowsIterator_decl.h.
References PLearn::TMatColRowsIterator< T >::mod, and PLearn::TMatColRowsIterator< T >::ptr.
reference PLearn::TMatColRowsIterator< T >::operator[] | ( | difference_type | n | ) | [inline] |
Definition at line 145 of file TMatColRowsIterator_decl.h.
int PLearn::TMatColRowsIterator< T >::mod [private] |
mod in underlying matrix
Definition at line 71 of file TMatColRowsIterator_decl.h.
Referenced by PLearn::TMatColRowsIterator< T >::operator==().
T* PLearn::TMatColRowsIterator< T >::ptr [private] |
current element pointer
Definition at line 70 of file TMatColRowsIterator_decl.h.
Referenced by PLearn::TMatColRowsIterator< T >::operator-(), and PLearn::TMatColRowsIterator< T >::operator==().