liveRootKeys property
List<TKey>
get
liveRootKeys
Root keys that are not pending deletion.
Matches the input contract of reorderRoots: the reorder API
validates orderedKeys against exactly this set and re-appends
pending-deletion entries internally. Passing the full rootKeys to
reorderRoots would fail the length check when any root is mid-exit.
Implementation
List<TKey> get liveRootKeys {
if (_pendingDeletionCount == 0) return List<TKey>.of(_roots);
final result = <TKey>[];
for (final k in _roots) {
if (!_isPendingDeletion(k)) result.add(k);
}
return result;
}