#include <baseset.h>
This class is derived from STL interators to additionally provide a reference of the container to iterate on. This feature is used to adjust iterators when the actual set gets reallocated due to a Detach() operation. Inheritance is private to ensure that all high-level api functions maintain iteretor refernces consistently. Currently, high-level api iterators support the operators -> ,*, =, ++, --, ==, !=.
Definition at line 447 of file baseset.h.
Public Member Functions | |
Iterator () | |
Default contructor, container unknown. | |
Iterator (const TBaseSet< T, Cmp > *pBaseSet, const typename std::set< T, Cmp >::const_iterator &sit) | |
Construct by members, used by TBaseSet to create temporary iterators. | |
Iterator (const Iterator &fit) | |
Copy constructor, copies container reference, incl attach. | |
~Iterator (void) | |
Destructor. | |
const Iterator & | operator= (const Iterator &rSrc) |
Assigment, tracks container. | |
void | StlIterator (const typename std::set< T, Cmp >::const_iterator &sit) |
Assign STL iterator only. | |
const std::set< T, Cmp >::const_iterator & | StlIterator (void) const |
Get STL iterator only. | |
void | Invalidate (void) |
Invalidate. | |
void | Detach (void) |
Detach. | |
void | DValid (void) const |
Check validity (provoke abort error). | |
const T * | operator-> (void) const |
Reimplement dereference. | |
const T & | operator * (void) const |
Reimplement derefernce. | |
bool | operator== (const Iterator &rOther) const |
Reimplement ==. | |
bool | operator!= (const Iterator &rOther) const |
Reimplement !=. | |
Iterator | operator++ (int step) |
Reimplement postfix ++. | |
const Iterator & | operator++ (void) |
Reimplement prefix ++. | |
Iterator | operator-- (int step) |
Reimplement postfix --. | |
const Iterator & | operator-- (void) |
Reimplement prefix --. | |
Public Attributes | |
const TBaseSet< T, Cmp > * | pBaseSet |
Maintaine container reference. | |
bool | mAttached |
Indocate that this iterator is attached to some baseset. |
|
Default contructor, container unknown.
|
|
Construct by members, used by TBaseSet to create temporary iterators.
|
|
Copy constructor, copies container reference, incl attach.
|
|
Destructor.
|
|
Detach.
|
|
Check validity (provoke abort error).
|
|
Invalidate.
|
|
Reimplement derefernce.
|
|
Reimplement !=.
|
|
Reimplement prefix ++.
|
|
Reimplement postfix ++.
|
|
Reimplement prefix --.
|
|
Reimplement postfix --.
|
|
Reimplement dereference.
|
|
Assigment, tracks container.
|
|
Reimplement ==.
|
|
Get STL iterator only.
|
|
Assign STL iterator only.
|
|
Indocate that this iterator is attached to some baseset.
|
|
Maintaine container reference.
|