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

Function GraphContext_GetIndex

src/graph/graphcontext.c:601–618  ·  view source on GitHub ↗

attempt to retrieve an index on the given label and attribute

Source from the content-addressed store, hash-verified

599
600// attempt to retrieve an index on the given label and attribute
601Index GraphContext_GetIndex
602(
603 const GraphContext *gc,
604 const char *label,
605 Attribute_ID *attrs,
606 uint n,
607 IndexType type,
608 SchemaType schema_type
609) {
610 ASSERT(gc != NULL);
611 ASSERT(label != NULL);
612
613 // Retrieve the schema for this label
614 Schema *s = GraphContext_GetSchema(gc, label, schema_type);
615 if(s == NULL) return NULL;
616
617 return Schema_GetIndex(s, attrs, n, type, false);
618}
619
620// create an exact match index for the given label and attribute
621bool GraphContext_AddExactMatchIndex

Callers 4

reduce_cond_opFunction · 0.85
_validateIndexConfigMapFunction · 0.85
_validateFieldConfigMapFunction · 0.85

Calls 2

GraphContext_GetSchemaFunction · 0.85
Schema_GetIndexFunction · 0.85

Tested by

no test coverage detected