MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / QueryGraph_RemoveEdge

Function QueryGraph_RemoveEdge

src/graph/query_graph.c:603–624  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

601}
602
603QGEdge *QueryGraph_RemoveEdge
604(
605 QueryGraph *qg,
606 QGEdge *e
607) {
608 ASSERT(qg != NULL && e != NULL);
609
610 // disconnect nodes connected by edge
611 QGNode_RemoveOutgoingEdge(e->src, e);
612 QGNode_RemoveIncomingEdge(e->dest, e);
613
614 // remove edge from query graph
615 uint edge_count = QueryGraph_EdgeCount(qg);
616 uint i = 0;
617 for(; i < edge_count; i++) {
618 if(e == qg->edges[i]) {
619 array_del_fast(qg->edges, i);
620 break;
621 }
622 }
623 return e;
624}
625
626QueryGraph **QueryGraph_ConnectedComponents
627(

Callers 3

_RemovePathFromGraphFunction · 0.85
QueryGraph_RemoveNodeFunction · 0.85

Calls 3

QueryGraph_EdgeCountFunction · 0.85

Tested by 1