org.gephi.algorithms.shortestpath
Class AbstractShortestPathAlgorithm
java.lang.Object
org.gephi.algorithms.shortestpath.AbstractShortestPathAlgorithm
- Direct Known Subclasses:
- BellmanFordShortestPathAlgorithm, DijkstraShortestPathAlgorithm
public abstract class AbstractShortestPathAlgorithm
- extends java.lang.Object
- Author:
- Mathieu Bastian
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
colors
protected final java.util.HashMap<Node,java.awt.Color> colors
distances
protected final java.util.HashMap<Node,java.lang.Double> distances
sourceNode
protected final Node sourceNode
maxDistance
protected double maxDistance
AbstractShortestPathAlgorithm
public AbstractShortestPathAlgorithm(Node sourceNode)
relax
protected boolean relax(Edge edge)
edgeWeight
protected double edgeWeight(Edge edge)
compute
public abstract void compute()
getPredecessor
public abstract Node getPredecessor(Node node)
getPredecessorIncoming
public abstract Edge getPredecessorIncoming(Node node)
getDistances
public java.util.HashMap<Node,java.lang.Double> getDistances()
getMaxDistance
public double getMaxDistance()