Gephi Toolkit Javadoc

org.gephi.algorithms.shortestpath
Class BellmanFordShortestPathAlgorithm

java.lang.Object
  extended by org.gephi.algorithms.shortestpath.AbstractShortestPathAlgorithm
      extended by org.gephi.algorithms.shortestpath.BellmanFordShortestPathAlgorithm

public class BellmanFordShortestPathAlgorithm
extends AbstractShortestPathAlgorithm

Author:
Mathieu Bastian

Field Summary
protected  DirectedGraph graph
           
protected  java.util.HashMap<Node,Edge> predecessors
           
protected  TimeInterval timeInterval
           
 
Fields inherited from class org.gephi.algorithms.shortestpath.AbstractShortestPathAlgorithm
colors, distances, maxDistance, sourceNode
 
Constructor Summary
BellmanFordShortestPathAlgorithm(DirectedGraph graph, Node sourceNode)
           
 
Method Summary
 void compute()
           
protected  double edgeWeight(Edge edge)
           
 Node getPredecessor(Node node)
           
 Edge getPredecessorIncoming(Node node)
           
 
Methods inherited from class org.gephi.algorithms.shortestpath.AbstractShortestPathAlgorithm
getDistances, getMaxDistance, relax
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

graph

protected final DirectedGraph graph

predecessors

protected final java.util.HashMap<Node,Edge> predecessors

timeInterval

protected TimeInterval timeInterval
Constructor Detail

BellmanFordShortestPathAlgorithm

public BellmanFordShortestPathAlgorithm(DirectedGraph graph,
                                        Node sourceNode)
Method Detail

compute

public void compute()
Specified by:
compute in class AbstractShortestPathAlgorithm

edgeWeight

protected double edgeWeight(Edge edge)
Overrides:
edgeWeight in class AbstractShortestPathAlgorithm

getPredecessor

public Node getPredecessor(Node node)
Specified by:
getPredecessor in class AbstractShortestPathAlgorithm

getPredecessorIncoming

public Edge getPredecessorIncoming(Node node)
Specified by:
getPredecessorIncoming in class AbstractShortestPathAlgorithm

Gephi Toolkit Javadoc