Class StableStandardMutableNetwork<N,E>

java.lang.Object
com.google.common.graph.StableStandardMutableNetwork<N,E>
Type Parameters:
N - Node parameter type
E - Edge parameter type
All Implemented Interfaces:
com.google.common.graph.MutableNetwork<N,E>, com.google.common.graph.Network<N,E>, com.google.common.graph.PredecessorsFunction<N>, com.google.common.graph.SuccessorsFunction<N>

public final class StableStandardMutableNetwork<N,E> extends Object implements com.google.common.graph.MutableNetwork<N,E>
This is mostly a copy of StandardMutableNetwork that delegates the construction of its underlying connections to a class providing stable iteration order over them.
  • Constructor Details

    • StableStandardMutableNetwork

      public StableStandardMutableNetwork(com.google.common.graph.NetworkBuilder<? super N,? super E> builder)
  • Method Details

    • addNode

      public boolean addNode(N node)
      Specified by:
      addNode in interface com.google.common.graph.MutableNetwork<N,E>
    • addEdge

      public boolean addEdge(N nodeU, N nodeV, E edge)
      Specified by:
      addEdge in interface com.google.common.graph.MutableNetwork<N,E>
    • asGraph

      public com.google.common.graph.Graph<N> asGraph()
      Specified by:
      asGraph in interface com.google.common.graph.Network<N,E>
    • degree

      public int degree(N node)
      Specified by:
      degree in interface com.google.common.graph.Network<N,E>
    • inDegree

      public int inDegree(N node)
      Specified by:
      inDegree in interface com.google.common.graph.Network<N,E>
    • outDegree

      public int outDegree(N node)
      Specified by:
      outDegree in interface com.google.common.graph.Network<N,E>
    • adjacentEdges

      public Set<E> adjacentEdges(E edge)
      Specified by:
      adjacentEdges in interface com.google.common.graph.Network<N,E>
    • edgesConnecting

      public Set<E> edgesConnecting(com.google.common.graph.EndpointPair<N> endpoints)
      Specified by:
      edgesConnecting in interface com.google.common.graph.Network<N,E>
    • edgeConnecting

      public Optional<E> edgeConnecting(N nodeU, N nodeV)
      Specified by:
      edgeConnecting in interface com.google.common.graph.Network<N,E>
    • edgeConnecting

      public Optional<E> edgeConnecting(com.google.common.graph.EndpointPair<N> endpoints)
      Specified by:
      edgeConnecting in interface com.google.common.graph.Network<N,E>
    • edgeConnectingOrNull

      @CheckForNull public E edgeConnectingOrNull(N nodeU, N nodeV)
      Specified by:
      edgeConnectingOrNull in interface com.google.common.graph.Network<N,E>
    • edgeConnectingOrNull

      @CheckForNull public E edgeConnectingOrNull(com.google.common.graph.EndpointPair<N> endpoints)
      Specified by:
      edgeConnectingOrNull in interface com.google.common.graph.Network<N,E>
    • hasEdgeConnecting

      public boolean hasEdgeConnecting(N nodeU, N nodeV)
      Specified by:
      hasEdgeConnecting in interface com.google.common.graph.Network<N,E>
    • hasEdgeConnecting

      public boolean hasEdgeConnecting(com.google.common.graph.EndpointPair<N> endpoints)
      Specified by:
      hasEdgeConnecting in interface com.google.common.graph.Network<N,E>
    • nodes

      public Set<N> nodes()
      Specified by:
      nodes in interface com.google.common.graph.Network<N,E>
    • edges

      public Set<E> edges()
      Specified by:
      edges in interface com.google.common.graph.Network<N,E>
    • isDirected

      public boolean isDirected()
      Specified by:
      isDirected in interface com.google.common.graph.Network<N,E>
    • allowsParallelEdges

      public boolean allowsParallelEdges()
      Specified by:
      allowsParallelEdges in interface com.google.common.graph.Network<N,E>
    • allowsSelfLoops

      public boolean allowsSelfLoops()
      Specified by:
      allowsSelfLoops in interface com.google.common.graph.Network<N,E>
    • nodeOrder

      public com.google.common.graph.ElementOrder<N> nodeOrder()
      Specified by:
      nodeOrder in interface com.google.common.graph.Network<N,E>
    • edgeOrder

      public com.google.common.graph.ElementOrder<E> edgeOrder()
      Specified by:
      edgeOrder in interface com.google.common.graph.Network<N,E>
    • incidentEdges

      public Set<E> incidentEdges(N node)
      Specified by:
      incidentEdges in interface com.google.common.graph.Network<N,E>
    • incidentNodes

      public com.google.common.graph.EndpointPair<N> incidentNodes(E edge)
      Specified by:
      incidentNodes in interface com.google.common.graph.Network<N,E>
    • adjacentNodes

      public Set<N> adjacentNodes(N node)
      Specified by:
      adjacentNodes in interface com.google.common.graph.Network<N,E>
    • edgesConnecting

      public Set<E> edgesConnecting(N nodeU, N nodeV)
      Specified by:
      edgesConnecting in interface com.google.common.graph.Network<N,E>
    • inEdges

      public Set<E> inEdges(N node)
      Specified by:
      inEdges in interface com.google.common.graph.Network<N,E>
    • outEdges

      public Set<E> outEdges(N node)
      Specified by:
      outEdges in interface com.google.common.graph.Network<N,E>
    • predecessors

      public Set<N> predecessors(N node)
      Specified by:
      predecessors in interface com.google.common.graph.Network<N,E>
      Specified by:
      predecessors in interface com.google.common.graph.PredecessorsFunction<N>
    • successors

      public Set<N> successors(N node)
      Specified by:
      successors in interface com.google.common.graph.Network<N,E>
      Specified by:
      successors in interface com.google.common.graph.SuccessorsFunction<N>
    • addEdge

      public boolean addEdge(com.google.common.graph.EndpointPair<N> endpoints, E edge)
      Specified by:
      addEdge in interface com.google.common.graph.MutableNetwork<N,E>
    • removeNode

      public boolean removeNode(N node)
      Specified by:
      removeNode in interface com.google.common.graph.MutableNetwork<N,E>
    • removeEdge

      public boolean removeEdge(E edge)
      Specified by:
      removeEdge in interface com.google.common.graph.MutableNetwork<N,E>