AuD
Lecture 'Algorithmen und Datenstrukturen' (code examples)
aud.BinaryTreeTraversal< T >.InorderIterator Class Reference

inorder iterator for BinaryTree More...

+ Inheritance diagram for aud.BinaryTreeTraversal< T >.InorderIterator:
+ Collaboration diagram for aud.BinaryTreeTraversal< T >.InorderIterator:

Public Member Functions

BinaryTree< T > next ()
 
- Public Member Functions inherited from aud.BinaryTreeTraversal< T >.RecursiveTraversalIterator
boolean hasNext ()
 
void remove ()
 
- Public Member Functions inherited from aud.BinarySearchTree.Iterator< BinaryTree< T > >
boolean hasNext ()
 
Cursor next ()
 
void remove ()
 not implemented More...
 

Detailed Description

inorder iterator for BinaryTree

Definition at line 83 of file BinaryTreeTraversal.java.

Member Function Documentation

◆ next()

BinaryTree< T > aud.BinaryTreeTraversal< T >.InorderIterator.next ( )

Definition at line 96 of file BinaryTreeTraversal.java.

96 {
97 BinaryTree<T> node=stack_.pop();
98 if (node.getRight()!=null) {
99 stack_.push(node.getRight());
100 descendLeft();
101 }
102
103 return node;
104 }

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