|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jgrapht.alg.CycleDetector<V,E>
public class CycleDetector<V,E>
Performs cycle detection on a graph. The inspected graph is specified at construction time and cannot be modified. Currently, the detector supports only directed graphs.
Constructor Summary | |
---|---|
CycleDetector(DirectedGraph<V,E> graph)
Creates a cycle detector for the specified graph. |
Method Summary | |
---|---|
boolean |
detectCycles()
Performs yes/no cycle detection on the entire graph. |
boolean |
detectCyclesContainingVertex(V v)
Performs yes/no cycle detection on an individual vertex. |
java.util.Set<V> |
findCycles()
Finds the vertex set for the subgraph of all cycles. |
java.util.Set<V> |
findCyclesContainingVertex(V v)
Finds the vertex set for the subgraph of all cycles which contain a particular vertex. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CycleDetector(DirectedGraph<V,E> graph)
graph
- the DirectedGraph in which to detect cyclesMethod Detail |
---|
public boolean detectCycles()
public boolean detectCyclesContainingVertex(V v)
v
- the vertex to test
public java.util.Set<V> findCycles()
public java.util.Set<V> findCyclesContainingVertex(V v)
v
- the vertex to test
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |