All Packages Class Hierarchy This Package Previous Next Index
Class jdsl.core.algo.graphtraversals.FindPathDFS
java.lang.Object
|
+----jdsl.core.algo.graphtraversals.DFS
|
+----jdsl.core.algo.graphtraversals.FindPathDFS
- public class FindPathDFS
- extends DFS
This class specializes DFS to determine, given a vertex v, if there is
a path from the start vertex to v in the connected component of the
start vertex. The algorithm returns an enumeration of vertices in the
path, or an empty enumeration if the path does not exist.
- Version:
- Tue Sep 2 18:02:45 1997
- Author:
- Natasha Gelfand
-
done
-
-
path
-
-
targetVert
-
-
FindPathDFS()
-
-
execute(InspectableGraph, Vertex, Object)
- Runs the depth first search algorithm on a graph.
-
finishVisit(Vertex)
- Called when the search has finished with the vertex.
-
isDone()
- Tests if the depth first search is done.
-
startVisit(Vertex)
- Called when a vertex is visited.
path
protected Sequence path
done
protected boolean done
targetVert
protected Vertex targetVert
FindPathDFS
public FindPathDFS()
execute
public Object execute(InspectableGraph g,
Vertex start,
Object info)
- Runs the depth first search algorithm on a graph.
- Overrides:
- execute in class DFS
startVisit
protected void startVisit(Vertex v)
- Called when a vertex is visited.
- Overrides:
- startVisit in class DFS
finishVisit
protected void finishVisit(Vertex v)
- Called when the search has finished with the vertex.
- Overrides:
- finishVisit in class DFS
isDone
protected boolean isDone()
- Tests if the depth first search is done.
- Overrides:
- isDone in class DFS
All Packages Class Hierarchy This Package Previous Next Index