Google

Main Page   Class Hierarchy   Compound List   File List   Compound Members  

csHashIterator Class Reference

An iterator to iterate over elements in the hashmap. More...

#include <hashmap.h>

Inheritance diagram for csHashIterator:

csHashIteratorReversible List of all members.

Public Methods

 csHashIterator (csHashMap *hash)
 Constructor for an iterator to iterate over all elements in a hashmap. More...

 csHashIterator (csHashMap *hash, csHashKey Key)
 Constructor for an iterator to iterate over all elements with the given key. More...

bool HasNext ()
 Is there a next element in this iterator?

csHashObject Next ()
 Get the next element.

void DeleteNext ()
 Delete next element and fetches new one. More...


Friends

class  csHashMap
class  csHashIteratorReversible

Detailed Description

An iterator to iterate over elements in the hashmap.

When you have an open iterator you should not alter the hashmap that this object iterates over. The only safe operation that you can do is to call 'Delete' on this iterator to delete one element from the map. The iterator will correctly point to the next element then.


Constructor & Destructor Documentation

csHashIterator::csHashIterator ( csHashMap * hash )
 

Constructor for an iterator to iterate over all elements in a hashmap.

Note that you should not do changes on the hashmap when you have open iterators.

csHashIterator::csHashIterator ( csHashMap * hash,
csHashKey Key )
 

Constructor for an iterator to iterate over all elements with the given key.

Note that you should not do changes on the hashmap when you have open iterators.


Member Function Documentation

void csHashIterator::DeleteNext ( )
 

Delete next element and fetches new one.

@@ Not implemented yet!


The documentation for this class was generated from the following file:
Generated for Crystal Space by doxygen 1.2.5 written by Dimitri van Heesch, ©1997-2000