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 Details

    • id

      public String id
      The edge identifier.
    • node0

      public NodeParticle node0
      Source node.
    • node1

      public NodeParticle node1
      Target node.
    • weight

      public double weight
      Edge weight.
    • spring

      public Point3 spring
      The attraction force on this edge.
    • ignored

      public boolean ignored
      Make this edge ignored by the layout algorithm ?.
    • attE

      public double attE
      The edge attraction energy.
  • Constructor Details

  • Method Details

    • getOpposite

      public NodeParticle getOpposite​(NodeParticle node)
      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.