public class StronglyConnectedComponentsFast<N>
extends java.lang.Object
DirectedGraph| Modifier and Type | Field and Description |
|---|---|
protected java.util.List<java.util.List<N>> |
componentList |
protected DirectedGraph<N> |
g |
protected int |
index |
protected java.util.Map<N,java.lang.Integer> |
indexForNode |
protected java.util.Map<N,java.lang.Integer> |
lowlinkForNode |
protected java.util.Stack<N> |
s |
protected java.util.List<java.util.List<N>> |
trueComponentList |
| Constructor and Description |
|---|
StronglyConnectedComponentsFast(DirectedGraph<N> g) |
| Modifier and Type | Method and Description |
|---|---|
java.util.List<java.util.List<N>> |
getComponents() |
java.util.List<java.util.List<N>> |
getTrueComponents() |
protected void |
iterate(N x) |
protected void |
recurse(N v) |
protected final java.util.List<java.util.List<N>> componentList
protected final java.util.List<java.util.List<N>> trueComponentList
protected int index
protected java.util.Map<N,java.lang.Integer> indexForNode
protected java.util.Map<N,java.lang.Integer> lowlinkForNode
protected java.util.Stack<N> s
protected DirectedGraph<N> g
public StronglyConnectedComponentsFast(DirectedGraph<N> g)
g - a graph for which we want to compute the strongly connected
components.DirectedGraphprotected void recurse(N v)
protected void iterate(N x)
public java.util.List<java.util.List<N>> getComponents()
public java.util.List<java.util.List<N>> getTrueComponents()