|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface DirectedGraph
Specifies a directed graph data structure.
TODO:
| Method Summary | |
|---|---|
boolean |
containsNode(java.lang.Object node)
Determines if the given object is contained as a node within the graph. |
java.util.Collection |
getAncestors(java.lang.Object node)
Return a Collection of node objects in the graph that are ancestors of the node passed in as a parameter. |
java.util.Collection |
getDescendents(java.lang.Object node)
Return a Collection of node objects in the graph that are descendants of the node passed in as a parameter. |
Edge |
getEdge(java.lang.Object source,
java.lang.Object sink)
Return the Edge associated with the given source,sink pair. |
java.util.Collection<? extends Edge> |
getEdges()
Return a Collection of all edges in the graph. |
java.util.Collection<Edge> |
getInputEdges(java.lang.Object node)
Return a Collection of Edge objects that are "inputs" to the given node (i.e. |
java.util.Collection |
getNodes()
Return a Collection of all nodes in the graph. |
java.util.Collection<Edge> |
getOutputEdges(java.lang.Object node)
Return a Collection of Edge objects that are "outputs" to the given node (i.e. |
java.util.Collection |
getPredecessors(java.lang.Object node)
Return a Collection of node objects in the graph that are direct predecessors of the node passed in as a parameter. |
DirectedGraph |
getSubGraph(java.util.Collection nodes)
Return a new DirectedGraph object that is a sub-graph of this graph. |
java.util.Collection |
getSuccessors(java.lang.Object node)
Return a Collection of node objects in the graph that are direct successors of the node passed in as a parameter. |
DirectedGraph |
invert()
|
| Method Detail |
|---|
boolean containsNode(java.lang.Object node)
node - Object to test for graph inclusion.
java.util.Collection getNodes()
java.util.Collection<? extends Edge> getEdges()
java.util.Collection getSuccessors(java.lang.Object node)
java.util.Collection getPredecessors(java.lang.Object node)
java.util.Collection getDescendents(java.lang.Object node)
This is the same as "reachableNodes" in ptolemy.graph.
DirectedGraph getSubGraph(java.util.Collection nodes)
nodes -
java.util.Collection getAncestors(java.lang.Object node)
This is the same as "backwardReachableNodes" in ptolemy.graph.
java.util.Collection<Edge> getInputEdges(java.lang.Object node)
java.util.Collection<Edge> getOutputEdges(java.lang.Object node)
Edge getEdge(java.lang.Object source,
java.lang.Object sink)
TODO: What if there is more than one edge?
DirectedGraph invert()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||