Class Edge

java.lang.Object
org.ddolib.ddo.core.mdd.Edge

public final class Edge extends Object
Represents an edge in a decision diagram that connects two nodes.

Each edge has a source node, an associated decision, and a weight. It is used to represent transitions between nodes in a decision diagram.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final Decision
    The decision associated with this edge.
    final Node
    The source node of this edge.
    double
    The weight of the edge.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Edge(Node src, Decision d, double w)
    Creates a new edge connecting a source node with a decision and a weight.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns a string representation of this edge, including origin, decision, and weight.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

    • origin

      public final Node origin
      The source node of this edge.
    • decision

      public final Decision decision
      The decision associated with this edge.
    • weight

      public double weight
      The weight of the edge.
  • Constructor Details

    • Edge

      public Edge(Node src, Decision d, double w)
      Creates a new edge connecting a source node with a decision and a weight.
      Parameters:
      src - the source node of the edge
      d - the decision taken to traverse this edge
      w - the weight of the edge
  • Method Details

    • toString

      public String toString()
      Returns a string representation of this edge, including origin, decision, and weight.
      Overrides:
      toString in class Object
      Returns:
      a string describing the edge