org.jgrapht.graph

• Type Parameters:
V - the graph vertex type
E - the graph edge type
All Implemented Interfaces:
DirectedGraph<V,E>, Graph<V,E>

implements DirectedGraph<V,E>
A directed graph that is a MaskSubgraph of another graph.
Since:
July 5, 2007
Author:
Guillaume Boulmier
• Constructor Detail

@Deprecated
Deprecated. in favor of using lambdas
Create a new directed MaskSubgraph of another graph.
Parameters:
base - the base graph
mask - vertices and edges to exclude in the subgraph. If a vertex/edge is masked, it is as if it is not in the subgraph.

Create a new directed MaskSubgraph of another graph.
Parameters:
base - the base graph
vertexMask - vertices to exclude in the subgraph. If a vertex is masked, it is as if it is not in the subgraph. Edges incident to the masked vertex are also masked.
edgeMask - edges to exclude in the subgraph. If an edge is masked, it is as if it is not in the subgraph.
• Method Detail

• inDegreeOf

public int inDegreeOf(V vertex)
Returns the "in degree" of the specified vertex. An in degree of a vertex in a directed graph is the number of inward directed edges from that vertex. See http://mathworld.wolfram.com/Indegree.html.
Specified by:
inDegreeOf in interface DirectedGraph<V,E>
Parameters:
vertex - vertex whose degree is to be calculated.
Returns:
the degree of the specified vertex.
• incomingEdgesOf

public Set<E> incomingEdgesOf(V vertex)
Returns a set of all edges incoming into the specified vertex.
Specified by:
incomingEdgesOf in interface DirectedGraph<V,E>
Parameters:
vertex - the vertex for which the list of incoming edges to be returned.
Returns:
a set of all edges incoming into the specified vertex.
• outDegreeOf

public int outDegreeOf(V vertex)
Returns the "out degree" of the specified vertex. An out degree of a vertex in a directed graph is the number of outward directed edges from that vertex. See http://mathworld.wolfram.com/Outdegree.html.
Specified by:
outDegreeOf in interface DirectedGraph<V,E>
Parameters:
vertex - vertex whose degree is to be calculated.
Returns:
the degree of the specified vertex.
• outgoingEdgesOf

public Set<E> outgoingEdgesOf(V vertex)
Returns a set of all edges outgoing from the specified vertex.
Specified by:
outgoingEdgesOf in interface DirectedGraph<V,E>
Parameters:
vertex - the vertex for which the list of outgoing edges to be returned.
Returns:
a set of all edges outgoing from the specified vertex.