SparseLibrary
Version 1.6.0
|
Same as treeIterator, but does in-order traversal instead of pre-order. More...
#include <Upscaler.hpp>
Public Member Functions | |
treeInOrderIterator (Upscaler< T > *_p, const unsigned long int initial, std::vector< bool > *_pp=NULL) | |
Base constructor. More... | |
virtual bool | next () |
Moves iterator to its next position. More... | |
Public Member Functions inherited from Upscaler< T >::treeIterator | |
treeIterator (Upscaler< T > *_p, const unsigned long int initial, std::vector< bool > *_pp=NULL) | |
Base constructor. More... | |
unsigned long int | position () |
Additional Inherited Members | |
Protected Attributes inherited from Upscaler< T >::treeIterator | |
unsigned long int | walk |
Current position of the iterator. More... | |
unsigned long int | ID |
Starting position of the iterator. More... | |
std::vector< bool > | processed |
Processed[ i ] is true when this iterator has visited its i-th child. More... | |
std::vector< bool > * | p_processed |
Pointer to the `processed'-vector actually used. More... | |
Upscaler< T > * | p |
Class this iterator works on. More... | |
Same as treeIterator, but does in-order traversal instead of pre-order.
|
inline |
Base constructor.
_p | Iterates on this object. |
initial | Initial position. |
_pp | Buffer where the visited subtrees may be stored. |
References Upscaler< T >::treeIterator::ID, Upscaler< T >::treeInOrderIterator::next(), and Upscaler< T >::treeIterator::p_processed.
|
inlinevirtual |
Moves iterator to its next position.
Reimplemented from Upscaler< T >::treeIterator.
References SBDTree::NO_SUCH_NODE, Upscaler< T >::treeIterator::p, Upscaler< T >::treeIterator::p_processed, and Upscaler< T >::treeIterator::walk.
Referenced by Upscaler< T >::getSubTree(), and Upscaler< T >::treeInOrderIterator::treeInOrderIterator().