ParentChangedCallback typedef

ParentChangedCallback = void Function(int nid, int oldParent, int newParent)

Signature for the NodeStore.onParentChanged observer.

Fired by NodeStore.setParent after the parent write and the _ancestorsExpandedByNid cache propagation. Both oldParent and newParent are nid values; either may be kNoParentNid (root).

Fires unconditionally — including the no-op oldParent == newParent case. Subscribers are responsible for short-circuiting no-ops.

Implementation

typedef ParentChangedCallback = void Function(
  int nid,
  int oldParent,
  int newParent,
);