Interface EdgeLabelledDirectedGraph<N,​L>

    • Method Detail

      • getLabelsForEdges

        List<L> getLabelsForEdges​(N from,
                                  N to)
        Returns a list of labels for which an edge exists between from and to
        Parameters:
        from - out node of the edges to get labels for
        to - in node of the edges to get labels for
        Returns:
      • getEdgesForLabel

        DirectedGraph<N> getEdgesForLabel​(L label)
        Returns a DirectedGraph consisting of all edges with the given label and their nodes. Nodes without edges are not included in the new graph.
        Parameters:
        label - edge label to use as a filter in building the subgraph
        Returns:
      • containsEdge

        boolean containsEdge​(N from,
                             N to,
                             L label)
        Parameters:
        from -
        to -
        label -
        Returns:
        true if the graph contains an edge between the 2 nodes with the given label, false otherwise
      • containsAnyEdge

        boolean containsAnyEdge​(N from,
                                N to)
        Parameters:
        from - out node for the edges
        to - in node for the edges
        Returns:
        true if the graph contains any edges between the 2 nodes, false, otherwise
      • containsAnyEdge

        boolean containsAnyEdge​(L label)
        Parameters:
        label - label for the edges
        Returns:
        true if the graph contains any edges with the given label, false otherwise
      • containsNode

        boolean containsNode​(N node)
        Parameters:
        node - node that we want to know if the graph contains
        Returns:
        true if the graph contains the node, false otherwise