StiKTNIterator Class Reference

#include <StiKTNIterator.h>

Inherited by StiKTNForwardIterator.

List of all members.

Public Member Functions

 StiKTNIterator (KTN_t *leaf=0, int dir=0)
 ctr-dstr
 StiKTNIterator (KTN_t &leaf, int dir=0)
StiKTNIterator begin ()
StiKTNIterator rbegin ()
bool operator== (const StiKTNIterator &rhs) const
 equality:
bool operator!= (const StiKTNIterator &rhs) const
 inequlity
KTN_toperator* ()
KTN_toperator() ()
StiKTNIteratoroperator++ ()
 prefix
StiKTNIterator operator++ (int)
 postfix
StiKTNIteratoroperator-- ()
 prefix
StiKTNIterator operator-- (int)
 postfix

Static Public Member Functions

static const StiKTNIteratorend ()
 We demarcate the end of the traversal via a singular iterator.
static const StiKTNIteratorrend ()
static StiKTNIterator begin (KTN_t *fist)
static StiKTNIterator rbegin (KTN_t *last)


Detailed Description

This class is an STL compliant forward iterator that will traverse from the leaf of a tree upward to a root.

Author:
M.L. Miller (Yale Software)
Note:
We use the defualt copy/assignment generated by compiler.

Singularity (i.e., 'end') is represented by setting mNode=0.

StiKTNIterator is a non-virtual class.

Definition at line 25 of file StiKTNIterator.h.


Member Function Documentation

StiKTNIterator StiKTNIterator::operator++ ( int   )  [inline]

postfix

In the case where the prefix operator increments beyond the root of the tree, the pointer to mNode is set to 0. This demarcates the end of the traversal.

Definition at line 115 of file StiKTNIterator.h.

StiKTNIterator & StiKTNIterator::operator++ (  )  [inline]

prefix

In the case where the prefix operator increments beyond the last leaf of the tree, the pointer to mNode is set to -. This demarcates the end of traversal.

Definition at line 126 of file StiKTNIterator.h.

References StiTreeNode::getNextNode().

StiKTNIterator StiKTNIterator::operator-- ( int   )  [inline]

postfix

In the case where the prefix operator increments beyond the root of the tree, the pointer to mNode is set to 0. This demarcates the end of the traversal.

Definition at line 145 of file StiKTNIterator.h.

StiKTNIterator & StiKTNIterator::operator-- (  )  [inline]

prefix

In the case where the prefix operator increments beyond the root of the tree, the pointer to mNode is set to 0. This demarcates the end of the traversal.

Definition at line 102 of file StiKTNIterator.h.


The documentation for this class was generated from the following files:

Generated on Sat May 26 04:28:19 2012 for StRoot by  doxygen 1.5.9