Class EdgeSpring
java.lang.Object
org.graphstream.ui.layout.springbox.EdgeSpring
public class EdgeSpring extends Object
Edge representation.
This is mainly used to store data about an edge, all the computation is done in the node particle.
-
Field Summary
Fields Modifier and Type Field Description doubleattEThe edge attraction energy.StringidThe edge identifier.booleanignoredMake this edge ignored by the layout algorithm ?.NodeParticlenode0Source node.NodeParticlenode1Target node.Point3springThe attraction force on this edge.doubleweightEdge weight. -
Constructor Summary
Constructors Constructor Description EdgeSpring(String id, NodeParticle n0, NodeParticle n1)New edge between two given nodes. -
Method Summary
Modifier and Type Method Description NodeParticlegetOpposite(NodeParticle node)Considering the two nodes of the edge, return the one that was not given as argument.
-
Field Details
-
Constructor Details
-
EdgeSpring
New edge between two given nodes.- Parameters:
id- The edge identifier.n0- The first node.n1- The second node.
-
-
Method Details
-
getOpposite
Considering the two nodes of the edge, return the one that was not given as argument.- Parameters:
node- One of the nodes of the edge.- Returns:
- The other node.
-