org.jikesrvm.compilers.opt.util
Class DepthFirstEnumerator
java.lang.Object
org.jikesrvm.compilers.opt.util.DepthFirstEnumerator
- All Implemented Interfaces:
- Enumeration<GraphNode>
public final class DepthFirstEnumerator
- extends Object
- implements Enumeration<GraphNode>
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
stack
private final Stack<GraphNode> stack
visited
private final Set<GraphNode> visited
DepthFirstEnumerator
public DepthFirstEnumerator(GraphNode start)
hasMoreElements
public boolean hasMoreElements()
- Specified by:
hasMoreElements
in interface Enumeration<GraphNode>
nextElement
public GraphNode nextElement()
- Specified by:
nextElement
in interface Enumeration<GraphNode>
notVisited
private boolean notVisited(GraphNode node)