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

Function UndoLog_AddLabels

src/undo_log/undo_log.c:469–487  ·  view source on GitHub ↗

undo node add label

Source from the content-addressed store, hash-verified

467
468// undo node add label
469void UndoLog_AddLabels
470(
471 UndoLog log, // undo log
472 Node *node, // updated node
473 LabelID *label_ids, // added labels
474 size_t labels_count // number of removed labels
475) {
476 ASSERT(node != NULL);
477 ASSERT(label_ids != NULL);
478
479 UndoOp op;
480
481 op.type = UNDO_SET_LABELS;
482 op.labels_op.node = *node;
483 op.labels_op.label_ids = array_new(LabelID, labels_count);
484 memcpy(op.labels_op.label_ids, label_ids, sizeof(LabelID)*labels_count);
485 op.labels_op.labels_count = labels_count;
486 UNDOLOG_ADD_OP(log, op);
487}
488
489// undo node remove label
490void UndoLog_RemoveLabels

Callers 1

UpdateNodeLabelsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected