/** * INTERNAL USE ONLY * @param GraphEdge $oEdge * @throws SimpleGraphException */ public function _RemoveEdge(GraphEdge $oEdge) { if (!array_key_exists($oEdge->GetId(), $this->aEdges)) { throw new SimpleGraphException('Cannot remove edge (id=' . $oEdge->GetId() . ') from the graph. The edge was not found.'); } $oEdge->GetSourceNode()->_RemoveOutgoingEdge($oEdge); $oEdge->GetSinkNode()->_RemoveIncomingEdge($oEdge); unset($this->aEdges[$oEdge->GetId()]); }