18 #ifndef __itkRootTreeIterator_h
19 #define __itkRootTreeIterator_h
25 template<
typename TTreeType >
61 template<
typename TTreeType >
69 this->
m_Root = tree->GetRoot();
75 template<
typename TTreeType >
83 template<
typename TTreeType >
87 if ( const_cast< TreeNodeType * >( FindNextNode() ) != ITK_NULLPTR )
96 template<
typename TTreeType >
100 this->m_Position =
const_cast< TreeNodeType *
>( FindNextNode() );
101 return this->m_Position->Get();
106 template<
typename TTreeType >
110 if ( this->m_Position == ITK_NULLPTR )
114 if ( this->m_Position == this->m_Root )
118 return this->m_Position->GetParent();
123 template<
typename TTreeType >
Superclass::NodeType NodeType
Represents a node in a tree.
TreeIteratorBase< TTreeType > * Clone()
TTreeType::TreeNodeType TreeNodeType
Superclass::TreeNodeType TreeNodeType
TTreeType::ValueType ValueType
const TreeNodeType * FindNextNode() const
RootTreeIterator(TreeType *tree, const TreeNodeType *start=NULL)
This class provides the base implementation for tree iterators.
TreeIteratorBase< TTreeType > Superclass
TreeNodeType * m_Position
const TreeNodeType * m_Root