![]() |
#include <List.h>
Public Member Functions | |
Iterator (List< T > &list) | |
Create iterator positioned at the beginning of the list. | |
Iterator (const Iterator &it) | |
Copy constructor. | |
int | index () const |
Current position in the list. | |
Iterator & | operator++ () |
Prefix increment. | |
bool | end () const |
Check if iterator has reached end of the list. | |
bool | last () const |
Check if iterator has reached the last element. | |
T & | operator * () const |
Return current element. | |
T * | operator-> () const |
Pointer mechanism. | |
operator T * () const | |
Cast to pointer to current element. | |
T * | pointer () const |
Returns pointer to current element. | |
void | operator= (const Iterator &it) |
Assignment. | |
bool | operator== (const Iterator &it) const |
Equality operator. | |
bool | operator!= (const Iterator &it) const |
Inequality operator. |
for (List<T>::Iterator it(list); !it.end(); ++it) { it->...(); }
|
Create iterator positioned at the beginning of the list.
|
|
Copy constructor.
|
|
Check if iterator has reached end of the list.
|
|
Current position in the list.
|
|
Check if iterator has reached the last element.
|
|
Return current element.
|
|
Cast to pointer to current element.
|
|
Inequality operator.
|
|
Prefix increment.
|
|
Pointer mechanism.
|
|
Assignment.
|
|
Equality operator.
|
|
Returns pointer to current element.
|
Documentation automatically generated with Doxygen on 10 Sep 2004.