PHP Class Gliph\Algorithm\ConnectedComponent

Datei anzeigen Open project: sdboyer/gliph Class Usage Examples

Public Methods

Method Description
tarjan_scc ( Gliph\Graph\Digraph $graph, Gliph\Visitor\TarjanSCCVisitor $visitor = NULL ) : Gliph\Visitor\TarjanSCCVisitor Finds connected components in the provided directed graph.

Method Details

tarjan_scc() public static method

Finds connected components in the provided directed graph.
public static tarjan_scc ( Gliph\Graph\Digraph $graph, Gliph\Visitor\TarjanSCCVisitor $visitor = NULL ) : Gliph\Visitor\TarjanSCCVisitor
$graph Gliph\Graph\Digraph The Digraph to search for connected components.
$visitor Gliph\Visitor\TarjanSCCVisitor The visitor that will collect and store the connected components. One will be created if not provided.
return Gliph\Visitor\TarjanSCCVisitor The finalized visitor.