org.javanetworkanalyzer.model
Class AsUnweightedDirectedG<V extends VId,E extends EdgeID>

java.lang.Object
  extended by org.jgrapht.graph.AbstractGraph<V,E>
      extended by org.jgrapht.graph.GraphDelegator<V,E>
          extended by org.jgrapht.graph.AsUnweightedDirectedGraph<V,E>
              extended by org.javanetworkanalyzer.model.AsUnweightedDirectedG<V,E>
All Implemented Interfaces:
Serializable, DirectedG<V,E>, KeyedGraph<V,E>, org.jgrapht.DirectedGraph<V,E>, org.jgrapht.Graph<V,E>

public class AsUnweightedDirectedG<V extends VId,E extends EdgeID>
extends org.jgrapht.graph.AsUnweightedDirectedGraph<V,E>
implements DirectedG<V,E>

Author:
Adam Gouge
See Also:
Serialized Form

Constructor Summary
AsUnweightedDirectedG(DirectedG<V,E> g)
           
 
Method Summary
 E addEdge(int source, int target)
          Add an edge from the vertex with id source to the vertex with id target.
 E addEdge(int source, int target, int edgeID)
          Add an edge from the vertex with id source to the vertex with id target and set the edge id.
 boolean addVertex(int id)
          Add a vertex with the given id.
 V getVertex(int id)
          Get the vertex with the given id.
 
Methods inherited from class org.jgrapht.graph.AsUnweightedDirectedGraph
getEdgeWeight
 
Methods inherited from class org.jgrapht.graph.GraphDelegator
addEdge, addEdge, addVertex, containsEdge, containsVertex, degreeOf, edgeSet, edgesOf, getAllEdges, getEdge, getEdgeFactory, getEdgeSource, getEdgeTarget, incomingEdgesOf, inDegreeOf, outDegreeOf, outgoingEdgesOf, removeEdge, removeEdge, removeVertex, setEdgeWeight, toString, vertexSet
 
Methods inherited from class org.jgrapht.graph.AbstractGraph
assertVertexExist, containsEdge, equals, hashCode, removeAllEdges, removeAllEdges, removeAllEdges, removeAllVertices, toStringFromSets
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.jgrapht.DirectedGraph
incomingEdgesOf, inDegreeOf, outDegreeOf, outgoingEdgesOf
 
Methods inherited from interface org.jgrapht.Graph
addEdge, addEdge, addVertex, containsEdge, containsEdge, containsVertex, edgeSet, edgesOf, getAllEdges, getEdge, getEdgeFactory, getEdgeSource, getEdgeTarget, getEdgeWeight, removeAllEdges, removeAllEdges, removeAllVertices, removeEdge, removeEdge, removeVertex, vertexSet
 

Constructor Detail

AsUnweightedDirectedG

public AsUnweightedDirectedG(DirectedG<V,E> g)
                      throws NoSuchMethodException
Throws:
NoSuchMethodException
Method Detail

addVertex

public boolean addVertex(int id)
Description copied from interface: KeyedGraph
Add a vertex with the given id.

Specified by:
addVertex in interface KeyedGraph<V extends VId,E extends EdgeID>
Parameters:
id - Id
Returns:
True if the vertex was added.

getVertex

public V getVertex(int id)
Description copied from interface: KeyedGraph
Get the vertex with the given id.

Specified by:
getVertex in interface KeyedGraph<V extends VId,E extends EdgeID>
Parameters:
id - Id.
Returns:
The vertex with the given id.

addEdge

public E addEdge(int source,
                 int target)
Description copied from interface: KeyedGraph
Add an edge from the vertex with id source to the vertex with id target.

Specified by:
addEdge in interface KeyedGraph<V extends VId,E extends EdgeID>
Parameters:
source - Source id.
target - Target Id.
Returns:
The newly added edge, or null if it was not added.

addEdge

public E addEdge(int source,
                 int target,
                 int edgeID)
Description copied from interface: KeyedGraph
Add an edge from the vertex with id source to the vertex with id target and set the edge id.

Specified by:
addEdge in interface KeyedGraph<V extends VId,E extends EdgeID>
Parameters:
source - Source id.
target - Target id.
edgeID - Edge id.
Returns:
The newly added edge, or null if it was not added.


Copyright © 2014. All Rights Reserved.