#include <List.h>
Collaboration diagram for List< T >::Pos:
Public Member Functions | |
Pos () | |
Empty constructor. | |
Pos (Data *p) | |
Constructor. | |
Pos & | operator++ () |
The pre-increment operator moves the iterator to the successor in the list. | |
Pos & | operator-- () |
The pre-decrement operator moves the iterator to the predecessor in the list. | |
Pos | operator++ (int) |
The post-increment operator moves the iterator to the successor in the list. | |
Pos | operator-- (int) |
The post-decrement operator moves the iterator to the predecessor in the list. | |
operator bool () const | |
The operator returns whether the iterator points to a list entry. | |
bool | operator== (const Pos &pos) const |
The operator determines whether two iterators point to the same list element. | |
bool | operator!= (const Pos &pos) const |
The operator determines whether two iterators point to different list elements. | |
Private Attributes | |
Data * | entry |
A pointer to the current list entry. | |
Friends | |
class | List< T > |
Definition at line 43 of file List.h.
|
Empty constructor. The iterator points nowhere. Definition at line 53 of file List.h. References List< T >::Pos::entry. |
|
Constructor. The iterator points to the given list node.
Definition at line 60 of file List.h. References List< T >::Pos::entry. |
|
The pre-increment operator moves the iterator to the successor in the list. If the iterator is moved behind the end of the list, it will point nowhere. Note that the iterator must point to a list element before this operation.
Definition at line 69 of file List.h. References List< T >::Pos::entry, and List< T >::Data::next. |
|
The pre-decrement operator moves the iterator to the predecessor in the list. If the iterator is moved before the beginning of the list, it will point nowhere. Note that the iterator must point to a list element before this operation.
Definition at line 78 of file List.h. References List< T >::Pos::entry, and List< T >::Data::prev. |
|
The post-increment operator moves the iterator to the successor in the list. If the iterator is moved behind the end of the list, it will point nowhere. Note that the iterator must point to a list element before this operation.
Definition at line 87 of file List.h. References List< T >::Pos::entry, and List< T >::Data::next. |
|
The post-decrement operator moves the iterator to the predecessor in the list. If the iterator is moved before the beginning of the list, it will point nowhere. Note that the iterator must point to a list element before this operation.
Definition at line 96 of file List.h. References List< T >::Pos::entry, and List< T >::Data::prev. |
|
The operator returns whether the iterator points to a list entry. If it does not point to a list entry, it points "nowhere".
Definition at line 103 of file List.h. References List< T >::Pos::entry. |
|
The operator determines whether two iterators point to the same list element.
Definition at line 110 of file List.h. References List< T >::Pos::entry. |
|
The operator determines whether two iterators point to different list elements.
Definition at line 117 of file List.h. References List< T >::Pos::entry. |
|
|
|
A pointer to the current list entry.
Definition at line 46 of file List.h. Referenced by List< T >::insert(), List< T >::Pos::operator bool(), List< T >::Pos::operator!=(), List< T >::Pos::operator++(), List< T >::Pos::operator--(), List< T >::Pos::operator==(), List< T >::operator[](), List< T >::Pos::Pos(), and List< T >::remove(). |