latest version v1.9 - last update 10 Apr 2010 |
iterator class (allows read and write operations) The use of the iterator classes is similar to the iterators of the STL (Standard Template Library). More...
#include <ltiSmallObjectList.h>
Public Types | |
typedef std::bidirectional_iterator_tag | iterator_category |
Public Member Functions | |
iterator () | |
iterator (const iterator &i) | |
bool | operator== (const iterator &i) const |
bool | operator!= (const iterator &i) const |
reference | operator* () const |
reference | operator* (T obj) const |
pointer | operator-> () const |
iterator & | operator++ () |
iterator | operator++ (int) |
iterator & | operator-- () |
iterator | operator-- (int) |
Protected Member Functions | |
iterator (smallObjectList *l, node *p) |
iterator class (allows read and write operations) The use of the iterator classes is similar to the iterators of the STL (Standard Template Library).
typedef std::bidirectional_iterator_tag lti::smallObjectList< T >::iterator::iterator_category |
Iterator traits.
These are required by the algorithms of the STL.
lti::smallObjectList< T >::iterator::iterator | ( | smallObjectList * | l, | |
node * | p | |||
) | [inline, protected] |
Creates an iterator for the given list, at the given position.
lti::smallObjectList< T >::iterator::iterator | ( | ) | [inline] |
Creates an uninitialized iterator.
lti::smallObjectList< T >::iterator::iterator | ( | const iterator & | i | ) | [inline] |
Copy constructor.
Creates a copy of the given iterator.
bool lti::smallObjectList< T >::iterator::operator!= | ( | const iterator & | i | ) | const [inline] |
Returns false if both iterators are at the same position on the same list, true otherwise.
reference lti::smallObjectList< T >::iterator::operator* | ( | T | obj | ) | const [inline] |
Overwrites the current element with the given element.
reference lti::smallObjectList< T >::iterator::operator* | ( | ) | const [inline] |
Returns a reference to the current element.
iterator lti::smallObjectList< T >::iterator::operator++ | ( | int | ) | [inline] |
Moves forward one element in the list, and returns a copy of itself before the move.
iterator& lti::smallObjectList< T >::iterator::operator++ | ( | ) | [inline] |
Moves forward one element in the list, and returns itself.
iterator lti::smallObjectList< T >::iterator::operator-- | ( | int | ) | [inline] |
Moves backward one element in the list, and returns a copy of itself before the move.
iterator& lti::smallObjectList< T >::iterator::operator-- | ( | ) | [inline] |
Moves backward one element in the list, and returns itself.
pointer lti::smallObjectList< T >::iterator::operator-> | ( | ) | const [inline] |
Returns a pointer to the current element.
bool lti::smallObjectList< T >::iterator::operator== | ( | const iterator & | i | ) | const [inline] |
Returns true if both iterators are at the same position on the same list, false otherwise.