BaseGraph.
The methods implemented in this class should not be overridden unless the subclass admits a more efficient implementation.
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public int | degree(N node)
Implements com. node's incident edges, counting self-loops twice (equivalently,
the number of times an edge touches node).
|
| protected long | |
| public Set | edges()
Implements com. BaseGraph#edges() defined in terms of Graph#nodes() and
successors(Object).
|
| public boolean | hasEdgeConnecting(N nodeU, N nodeV)
Implements com. nodeU to nodeV.
|
| public boolean | hasEdgeConnecting(EndpointPair<N> endpoints)
Implements com. endpoints (in the order, if
any, specified by endpoints).
|
| public ElementOrder | incidentEdgeOrder()
Implements com. ElementOrder that specifies the order of iteration for the elements of
edges(), adjacentNodes(Object), predecessors(Object), successors(Object) and incidentEdges(Object).
|
| public Set | incidentEdges(N node)
Implements com. node.
|
| public int | inDegree(N node)
Implements com. node's incoming edges (equal to predecessors(node).size())
in a directed graph.
|
| protected final boolean | isOrderingCompatible(EndpointPair<?> endpoints)
Returns |
| protected final <T> Set | |
| protected final <T> Set | |
| public int | outDegree(N node)
Implements com. node's outgoing edges (equal to successors(node).size())
in a directed graph.
|
| protected final void | validateEndpoints(EndpointPair<?> endpoints)
Throws |
| AbstractBaseGraph | back to summary |
|---|---|
| pack-priv AbstractBaseGraph() | |
| degree | back to summary |
|---|---|
| public int degree(N node) Implements com. Doc from com. Returns the count of For directed graphs, this is equal to For undirected graphs, this is equal to If the count is greater than
| |
| edgeCount | back to summary |
|---|---|
| protected long edgeCount() Returns the number of edges in this graph; used to calculate the size of | |
| edges | back to summary |
|---|---|
| public Set Implements com. An implementation of
| |
| hasEdgeConnecting | back to summary |
|---|---|
| public boolean hasEdgeConnecting(N nodeU, N nodeV) Implements com. Doc from com. Returns true if there is an edge that directly connects In an undirected graph, this is equal to
| |
| hasEdgeConnecting | back to summary |
|---|---|
| public boolean hasEdgeConnecting(EndpointPair<N> endpoints) Implements com. Doc from com. Returns true if there is an edge that directly connects Unlike the other
| |
| incidentEdgeOrder | back to summary |
|---|---|
| public ElementOrder Implements com. Doc from com. Returns an
| |
| incidentEdges | back to summary |
|---|---|
| public Set Implements com. Doc from com. Returns a live view of the edges in this graph whose endpoints include This is equal to the union of incoming and outgoing edges. If
| |
| inDegree | back to summary |
|---|---|
| public int inDegree(N node) Implements com. Doc from com. Returns the count of If the count is greater than
| |
| isOrderingCompatible | back to summary |
|---|---|
| protected final boolean isOrderingCompatible(EndpointPair<?> endpoints) Returns | |
| nodeInvalidatableSet | back to summary |
|---|---|
| protected final <T> Set | |
| nodePairInvalidatableSet | back to summary |
|---|---|
| protected final <T> Set | |
| outDegree | back to summary |
|---|---|
| public int outDegree(N node) Implements com. Doc from com. Returns the count of If the count is greater than
| |
| validateEndpoints | back to summary |
|---|---|
| protected final void validateEndpoints(EndpointPair<?> endpoints) Throws | |