All Packages  Class Hierarchy  This Package  Previous  Next  Index  
Class DataStructures.PostOrder
java.lang.Object
    |
    +----DataStructures.TreeIterator
            |
            +----DataStructures.PostOrder
- public class PostOrder
- extends TreeIterator
Postorder iterator class.
 
 s s
- An internal stack if visited nodes.
 
 PostOrder(BinarySearchTree) PostOrder(BinarySearchTree)
- Construct the iterator.
 
 advance() advance()
- Advance the current position to the next node in the tree,
according to the postorder traversal scheme.
 first() first()
- Set the current position to the first item, according
to the postorder traversal scheme.
 
 s
s
protected Stack s
- An internal stack if visited nodes.
 
 
 PostOrder
PostOrder
public PostOrder(BinarySearchTree theTree)
- Construct the iterator.
The current position is set to null.
 
- 
- Parameters:
- theTree - the tree to which the iterator is
permanently bound.
 
 
 first
first
public void first()
- Set the current position to the first item, according
to the postorder traversal scheme.
 
- 
- Overrides:
- first in class TreeIterator
 
 advance
advance
public void advance() throws ItemNotFound
- Advance the current position to the next node in the tree,
according to the postorder traversal scheme.
 
- 
- Throws:
ItemNotFound
- if the current position is null.
- Overrides:
- advance in class TreeIterator
 
All Packages  Class Hierarchy  This Package  Previous  Next  Index