Class OrderedSparseMultigraph<V,​E>

  • All Implemented Interfaces:
    edu.uci.ics.jung.graph.Graph<V,​E>, edu.uci.ics.jung.graph.Hypergraph<V,​E>, edu.uci.ics.jung.graph.MultiGraph<V,​E>, java.io.Serializable
    Direct Known Subclasses:
    SortedSparseMultigraph

    public class OrderedSparseMultigraph<V,​E>
    extends SparseMultigraph<V,​E>
    implements edu.uci.ics.jung.graph.MultiGraph<V,​E>
    An implementation of Graph that orders its vertex and edge collections according to insertion time, is suitable for sparse graphs, and permits directed, undirected, and parallel edges.
    See Also:
    Serialized Form
    • Constructor Detail

      • OrderedSparseMultigraph

        public OrderedSparseMultigraph()
        Creates a new instance.
    • Method Detail

      • getFactory

        public static <V,​E> org.apache.commons.collections4.Factory<edu.uci.ics.jung.graph.Graph<V,​E>> getFactory()
        Returns a Factory that creates an instance of this graph type.
        Type Parameters:
        V - the vertex type for the graph factory
        E - the edge type for the graph factory
      • addVertex

        public boolean addVertex​(V vertex)
        Specified by:
        addVertex in interface edu.uci.ics.jung.graph.Hypergraph<V,​E>
        Overrides:
        addVertex in class SparseMultigraph<V,​E>
      • getPredecessors

        public java.util.Collection<V> getPredecessors​(V vertex)
        Specified by:
        getPredecessors in interface edu.uci.ics.jung.graph.Graph<V,​E>
        Specified by:
        getPredecessors in interface edu.uci.ics.jung.graph.Hypergraph<V,​E>
        Overrides:
        getPredecessors in class SparseMultigraph<V,​E>
      • getSuccessors

        public java.util.Collection<V> getSuccessors​(V vertex)
        Specified by:
        getSuccessors in interface edu.uci.ics.jung.graph.Graph<V,​E>
        Specified by:
        getSuccessors in interface edu.uci.ics.jung.graph.Hypergraph<V,​E>
        Overrides:
        getSuccessors in class SparseMultigraph<V,​E>
      • getNeighbors

        public java.util.Collection<V> getNeighbors​(V vertex)
        Specified by:
        getNeighbors in interface edu.uci.ics.jung.graph.Hypergraph<V,​E>
        Overrides:
        getNeighbors in class SparseMultigraph<V,​E>
      • getIncidentEdges

        public java.util.Collection<E> getIncidentEdges​(V vertex)
        Specified by:
        getIncidentEdges in interface edu.uci.ics.jung.graph.Hypergraph<V,​E>
        Overrides:
        getIncidentEdges in class SparseMultigraph<V,​E>