com.phoenixst.plexus.traversals
public class PostOrderTraverser extends Object implements Traverser
Traverser
for a
Graph
, with no cycle detection. The last node
returned is the start node, and no Edge
is traversed
to reach it. All of the caveats concerning the ordering of the
operations hasNext()
, next()
, and
remove()
detailed by the Traverser class
documentation apply here.
Since: 1.0
Version: $Revision: 1.6 $
Constructor Summary | |
---|---|
PostOrderTraverser(Object startNode, Graph graph, Predicate traverserPredicate)
Creates a new PostOrderTraverser . | |
PostOrderTraverser(Object startNode, OrientedForest forest)
Creates a new PostOrderTraverser , which
depth-first traverses the descendants of the specified
startNode . | |
PostOrderTraverser(Object startNode, Transformer traverserFactory)
Creates a new PostOrderTraverser . | |
PostOrderTraverser(Object startNode, Graph graph, Transformer traverserFactory)
Creates a new PostOrderTraverser . |
Method Summary | |
---|---|
Graph.Edge | getEdge() |
boolean | hasNext() |
Object | next() |
void | remove() |
void | removeEdge() |
PostOrderTraverser
.PostOrderTraverser
, which
depth-first traverses the descendants of the specified
startNode
. The specified startNode
cannot be removed by PostOrderTraverser when using this
constructor.PostOrderTraverser
. The specified
startNode
cannot be removed by PostOrderTraverser
when using this constructor.PostOrderTraverser
. If the
graph
argument is null
, the
specified startNode
cannot be removed by PostOrderTraverser.