Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

OMF::Iterator Class Reference

#include <Iterator.hpp>

List of all members.


Detailed Description

The Iterator class is a sort of dynamic, generic iterator that works with the container classes. The iterator contains STL iterators of varying types (particularly those defined within the container classes) and references the correct one. Note that once an iterator has been used with one type of container it is extremely unwise to use it with another type.

I'm being lazy so the iterator is only going to support the postincrement operator.


Public Member Functions

 Iterator ()
 Iterator (const Iterator &i)
 Iterator (const ListIterator &i)
 Iterator (const SetIterator &i)
 Iterator (const MapIterator &i)
const Iteratoroperator= (const Iterator &i)
const Iteratoroperator= (const ListIterator &i)
const Iteratoroperator= (const SetIterator &i)
const Iteratoroperator= (const MapIterator &i)
Objectoperator * ()
Objectoperator-> ()
Iteratoroperator++ ()
Iterator operator++ (int)
Iteratoroperator-- ()
Iterator operator-- (int)
bool operator== (const Iterator &i)
bool operator!= (const Iterator &i)

Protected Types

typedef std::list< Object
* >::iterator 
ListIterator
typedef std::set< Object
* >::iterator 
SetIterator
typedef std::map< unsigned,
Object * >::iterator 
MapIterator
enum  Mode { None, List, Set, Map }


Member Typedef Documentation

typedef std::list<Object *>::iterator OMF::Iterator::ListIterator [protected]
 

typedef std::map<unsigned, Object *>::iterator OMF::Iterator::MapIterator [protected]
 

typedef std::set<Object *>::iterator OMF::Iterator::SetIterator [protected]
 


Member Enumeration Documentation

enum OMF::Iterator::Mode [protected]
 

The Mode enum describes the current "mode" of the iterator. The mode can be one of any of the described iterators.

Enumeration values:
None 
List 
Set 
Map 


Constructor & Destructor Documentation

OMF::Iterator::Iterator  ) 
 

OMF::Iterator::Iterator const Iterator i  ) 
 

OMF::Iterator::Iterator const ListIterator i  ) 
 

OMF::Iterator::Iterator const SetIterator i  ) 
 

OMF::Iterator::Iterator const MapIterator i  ) 
 


Member Function Documentation

Object* OMF::Iterator::operator *  ) 
 

bool OMF::Iterator::operator!= const Iterator i  ) 
 

Iterator OMF::Iterator::operator++ int   ) 
 

Iterator& OMF::Iterator::operator++  ) 
 

Iterator OMF::Iterator::operator-- int   ) 
 

Iterator& OMF::Iterator::operator--  ) 
 

Object* OMF::Iterator::operator->  ) 
 

const Iterator& OMF::Iterator::operator= const MapIterator i  ) 
 

const Iterator& OMF::Iterator::operator= const SetIterator i  ) 
 

const Iterator& OMF::Iterator::operator= const ListIterator i  ) 
 

const Iterator& OMF::Iterator::operator= const Iterator i  ) 
 

bool OMF::Iterator::operator== const Iterator i  ) 
 


The documentation for this class was generated from the following file:
Generated on Fri Sep 10 13:07:38 2004 for OpenModelingFramework by doxygen 1.3.8