|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.graphstream.algorithm.APSP.APSPInfo
public static class APSP.APSPInfo
Information stored on each node of the graph giving the length of the shortest paths toward each other node.
Field Summary | |
---|---|
static String |
ATTRIBUTE_NAME
|
double |
maxLength
Maximum number of hops to attain another node in the graph from the "from" node. |
double |
minLength
Minimum number of hops to attain another node in the graph from the "from" node. |
org.graphstream.graph.Node |
source
The start node name. |
HashMap<String,APSP.TargetPath> |
targets
Shortest paths toward all other accessible nodes. |
Constructor Summary | |
---|---|
APSP.APSPInfo(org.graphstream.graph.Node node,
String weightAttributeName,
boolean directed)
Create the new information and put in it all the paths between this node and all its direct neighbours. |
Method Summary | |
---|---|
double |
getLengthTo(String other)
Minimum distance between this node and another. |
double |
getMaximumLength()
The maximum distance between this node and another. |
double |
getMinimumLength()
The minimum distance between this node and another. |
String |
getNodeId()
The node represented by this APSP information. |
org.graphstream.graph.Path |
getShortestPathTo(String other)
|
void |
setLengthTo(APSP.APSPInfo other,
double length,
APSP.APSPInfo passBy)
Add or change the length between this node and another and update the minimum and maximum lengths seen so far. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String ATTRIBUTE_NAME
public org.graphstream.graph.Node source
public double maxLength
public double minLength
public HashMap<String,APSP.TargetPath> targets
Constructor Detail |
---|
public APSP.APSPInfo(org.graphstream.graph.Node node, String weightAttributeName, boolean directed)
node
- The node to start from.weightAttributeName
- The key used to retrieve the weight attributes of edges.
This attribute but store a value that inherit Number.directed
- If false, the edge orientation is not taken into account.Method Detail |
---|
public String getNodeId()
public double getLengthTo(String other)
other
- The other node identifier.
public double getMinimumLength()
public double getMaximumLength()
public void setLengthTo(APSP.APSPInfo other, double length, APSP.APSPInfo passBy)
other
- The other node APSP info.length
- The new minimum path lengths between these nodes.public org.graphstream.graph.Path getShortestPathTo(String other)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |