Interface ILabeledGraph<N,​A>

  • Type Parameters:
    N - Node label type
    A - Arc label type
    All Superinterfaces:
    IGraph<N>

    public interface ILabeledGraph<N,​A>
    extends IGraph<N>
    Graphs of this type also assign a label to the edges
    • Method Detail

      • addArc

        void addArc​(N from,
                    N to,
                    A edge)
        Parameters:
        from - Node from which to depart
        to - Node that is targeted by the edge
        edge - Edge label
      • getArcLabel

        A getArcLabel​(N from,
                      N to)
        Gets the label of the edge between two given nodes.
        Parameters:
        from - Node from which to depart
        to - Node that is targeted by the edge
        Returns:
        The label of the edge between the given nodes (if exists, otherwise an IllegalArgumentException may be thrown)