org.geotools.graph.traverse
Class DijkstraTraversal
java.lang.Object
org.geotools.graph.traverse.AbstractGraphTraversal
org.geotools.graph.traverse.SourceGraphTraversal
org.geotools.graph.traverse.DijkstraTraversal
- All Implemented Interfaces:
- GraphTraversal
- public class DijkstraTraversal
- extends SourceGraphTraversal
Traverses a graph using Dijkstras shortest path alorithm.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DijkstraTraversal
public DijkstraTraversal(Graph graph,
GraphWalker walker,
GraphComponent source,
DijkstraTraversal.CostFunction cf)
initNodes
public void initNodes()
- Description copied from class:
AbstractGraphTraversal
- Initializes the nodes of a graph by delegating initialization to the
walker.
- Specified by:
initNodes
in interface GraphTraversal
- Overrides:
initNodes
in class AbstractGraphTraversal
- See Also:
GraphTraversal.initNodes()
initEdges
public void initEdges()
- Description copied from class:
AbstractGraphTraversal
- Initializes the edges of a graph by delegating initialization to the
walker.
- Specified by:
initEdges
in interface GraphTraversal
- Overrides:
initEdges
in class AbstractGraphTraversal
- See Also:
GraphTraversal.initNodes()
getCostNode
public DijkstraTraversal.CostNode getCostNode(GraphComponent element)
getActiveElements
public java.util.Collection getActiveElements()
- Description copied from class:
SourceGraphTraversal
- Returns the active elements of the traversal. That is elements that
are in the process of being visited, or are queued to be visited.
- Specified by:
getActiveElements
in class SourceGraphTraversal
initHeap
protected void initHeap(java.util.Collection elements)
walk
protected void walk()
- Specified by:
walk
in class SourceGraphTraversal