Class GraphicEdge.EdgeGroup

java.lang.Object
org.graphstream.ui.graphicGraph.GraphicEdge.EdgeGroup
Enclosing class:
GraphicEdge

public class GraphicEdge.EdgeGroup
extends Object
An edge group contains the set of edges between two given nodes. This allows to quickly know how many 'multi' edges there is between two nodes in a multigraph and to associate invariant indices to edges (the GraphicEdge.multi attribute) inside the multi-representation.
  • Field Details

  • Constructor Details

    • EdgeGroup

      public EdgeGroup​(GraphicEdge first, GraphicEdge second)
      Create a new edge group, starting with two edges.
      Parameters:
      first - The initial edge.
      second - The second edge.
  • Method Details

    • getEdge

      public GraphicEdge getEdge​(int i)
      I-th edge of the group.
      Parameters:
      i - The edge index.
      Returns:
      The i-th edge.
    • getCount

      public int getCount()
      Number of edges in this group.
      Returns:
      The edge count.
    • increment

      public void increment​(GraphicEdge edge)
      Add an edge in the group.
      Parameters:
      edge - The edge to add.
    • decrement

      public void decrement​(GraphicEdge edge)
      Remove an edge from the group.
      Parameters:
      edge - The edge to remove.