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

Function Constraint_GetAttributes

src/constraint/constraint.c:238–255  ·  view source on GitHub ↗

returns a shallow copy of constraint attributes

Source from the content-addressed store, hash-verified

236
237// returns a shallow copy of constraint attributes
238uint8_t Constraint_GetAttributes
239(
240 const Constraint c, // constraint from which to get attributes
241 const Attribute_ID **attr_ids, // array of constraint attribute IDs
242 const char ***attr_names // array of constraint attribute names
243) {
244 ASSERT(c != NULL);
245
246 if(attr_ids != NULL) {
247 *attr_ids = c->attrs;
248 }
249
250 if(attr_names != NULL) {
251 *attr_names = c->attr_names;
252 }
253
254 return c->n_attr;
255}
256
257// checks if constraint enforces attribute
258bool Constraint_ContainsAttribute

Callers 3

_RdbSaveConstraintFunction · 0.85
Schema_GetConstraintFunction · 0.85
_EmitConstraintFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected