Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

Iterator Class Template Reference

Provides a nlog(n) iterator for AbstractBinaryTree. More...

#include <vdkbtrees.h>

List of all members.

Public Methods


Detailed Description

Provides a nlog(n) iterator for AbstractBinaryTree.

Iterator is implementes as a member of AbstractBinaryTree rather than an external object.


Constructor & Destructor Documentation

Iterator::Iterator AbstractBinaryTree< T, Node > &    _tree,
enum BtreeIteratorMode    start = BtMinKey
[inline]
 

ructor

Parameters:
tree  tree reference
start  where the iterator starts, can be:
  • BtMinKey from lowest key
  • BtRootKey from the tree root
  • BtMaxKey from the highest key

virtual Iterator::~Iterator   [inline, virtual]
 

Destructor


Member Function Documentation

virtual T Iterator::current   [inline, virtual]
 

Dereferencing operator returns the object of the node currently pointed to by the iterator.

virtual void Iterator::Next   [inline, virtual]
 

Move iterator to next key

virtual T* Iterator::Object   [inline, virtual]
 

returns a pointer to the object of the node currently pointed to (as opposed to returning a copy of the node, as the dereferencing operator does).

virtual T Iterator::operator *   [inline, virtual]
 

Dereferencing operator returns the object of the node currently pointed to by the iterator.

virtual Iterator::operator int   [inline, virtual]
 

Returns o if iterator points a non valid node. ie: was moved behind the lowest/highest key

virtual void Iterator::operator++ int    [inline, virtual]
 

Move iterator to next key

virtual void Iterator::operator++   [inline, virtual]
 

Move iterator to next key

virtual void Iterator::operator-- int    [inline, virtual]
 

Move iterator to prev key

virtual void Iterator::operator--   [inline, virtual]
 

Move iterator to prev key

virtual void Iterator::Parent   [inline, virtual]
 

Move iterator to parent node

virtual void Iterator::Previous   [inline, virtual]
 

Move iterator to prev key

virtual T* Iterator::RefObject   [inline, virtual]
 

returns a pointer to the object of the node currently pointed to (as opposed to returning a copy of the node, as the dereferencing operator does).

void Iterator::StartAt enum BtreeIteratorMode    start [inline]
 

Starts iterator over at the minimum, maximum or root node of the binary tree.


The documentation for this class was generated from the following file:
Generated on Wed Apr 17 13:24:58 2002 for vdk 2.0.1 by doxygen1.2.15