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

Function Graph_RemoveRelation

src/graph/graph.c:1247–1262  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1245}
1246
1247void Graph_RemoveRelation
1248(
1249 Graph *g,
1250 int relation_id
1251) {
1252 ASSERT(g != NULL);
1253 ASSERT(relation_id == Graph_RelationTypeCount(g) - 1);
1254 #ifdef RG_DEBUG
1255 GrB_Index nvals;
1256 GrB_Info info = RG_Matrix_nvals(&nvals, g->relations[relation_id]);
1257 ASSERT(info == GrB_SUCCESS);
1258 ASSERT(nvals == 0);
1259 #endif
1260 RG_Matrix_free(&g->relations[relation_id]);
1261 g->relations = array_del(g->relations, relation_id);
1262}
1263
1264RG_Matrix Graph_GetLabelMatrix
1265(

Callers 1

Calls 3

Graph_RelationTypeCountFunction · 0.85
RG_Matrix_nvalsFunction · 0.85
RG_Matrix_freeFunction · 0.85

Tested by

no test coverage detected