PHP Interface Gliph\Graph\MutableDigraph

Inheritance: extends Gliph\Graph\Digraph, extends Gliph\Graph\MutableVertexSet
Mostra file Open project: sdboyer/gliph

Public Methods

Method Description
ensureArc ( object $tail, object $head ) : Gliph\Graph\MutableDigraph Ensures the provided arc (directed edge) is present in this graph.
removeArc ( $tail, $head ) : Gliph\Graph\MutableDigraph Removes an arc from the graph.

Method Details

ensureArc() public method

Ensures the provided arc (directed edge) is present in this graph.
public ensureArc ( object $tail, object $head ) : Gliph\Graph\MutableDigraph
$tail object An object vertex from which the edge originates. The vertex will be added to the graph if it is not already present.
$head object An object vertex to which the edge points. The vertex will be added to the graph if it is not already present.
return Gliph\Graph\MutableDigraph The current graph instance.

removeArc() public method

Removes an arc from the graph.
public removeArc ( $tail, $head ) : Gliph\Graph\MutableDigraph
$tail The tail vertex in the arc to remove.
$head The head vertex in the arc to remove.
return Gliph\Graph\MutableDigraph The current graph instance.