org.jgrapht.graph
public class AsUnweightedDirectedGraph<V,E> extends GraphDelegator<V,E> implements java.io.Serializable, DirectedGraph<V,E>
Note that edges returned by this graph's accessors are really just the edges of the underlying directed graph.
This graph does not pass the hashCode and equals operations through to the backing graph, but relies on Object's equals and hashCode methods. This graph will be serializable if the backing graph is serializable.
| Constructor and Description |
|---|
AsUnweightedDirectedGraph(DirectedGraph<V,E> g)
Constructor for AsUnweightedGraph.
|
| Modifier and Type | Method and Description |
|---|---|
double |
getEdgeWeight(E e)
Returns the weight assigned to a given edge.
|
addEdge, addEdge, addVertex, containsEdge, containsVertex, degreeOf, edgeSet, edgesOf, getAllEdges, getEdge, getEdgeFactory, getEdgeSource, getEdgeTarget, incomingEdgesOf, inDegreeOf, outDegreeOf, outgoingEdgesOf, removeEdge, removeEdge, removeVertex, setEdgeWeight, toString, vertexSetassertVertexExist, containsEdge, removeAllEdges, removeAllEdges, removeAllEdges, removeAllVertices, toStringFromSetsclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitincomingEdgesOf, inDegreeOf, outDegreeOf, outgoingEdgesOfaddEdge, addEdge, addVertex, containsEdge, containsEdge, containsVertex, edgeSet, edgesOf, getAllEdges, getEdge, getEdgeFactory, getEdgeSource, getEdgeTarget, removeAllEdges, removeAllEdges, removeAllVertices, removeEdge, removeEdge, removeVertex, vertexSetpublic AsUnweightedDirectedGraph(DirectedGraph<V,E> g)
g - the backing graph over which an unweighted view is to be
created.public double getEdgeWeight(E e)
GraphWeightedGraph.DEFAULT_EDGE_WEIGHT), allowing
weighted-graph algorithms to apply to them where meaningful.getEdgeWeight in interface Graph<V,E>getEdgeWeight in class GraphDelegator<V,E>e - edge of interestGraph.getEdgeWeight(E)