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

Function NewOptionalOp

src/execution_plan/ops/op_optional.c:14–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12static OpBase *OptionalClone(const ExecutionPlan *plan, const OpBase *opBase);
13
14OpBase *NewOptionalOp(const ExecutionPlan *plan) {
15 Optional *op = rm_malloc(sizeof(Optional));
16 op->emitted_record = false;
17
18 // Set our Op operations
19 OpBase_Init((OpBase *)op, OPType_OPTIONAL, "Optional", NULL, OptionalConsume,
20 OptionalReset, NULL, OptionalClone, NULL, false, plan);
21
22 return (OpBase *)op;
23}
24
25static Record OptionalConsume(OpBase *opBase) {
26 Optional *op = (Optional *)opBase;

Callers 2

OptionalCloneFunction · 0.85
_buildOptionalMatchOpsFunction · 0.85

Calls 2

rm_mallocFunction · 0.85
OpBase_InitFunction · 0.85

Tested by

no test coverage detected