removeChild method
Removes a single child from this node and set its parent to null.
Implementation
void removeChild(TreeNode child) {
final wasRemoved = _children.remove(child);
if (wasRemoved) {
child._parent = null;
}
}
Removes a single child from this node and set its parent to null.
void removeChild(TreeNode child) {
final wasRemoved = _children.remove(child);
if (wasRemoved) {
child._parent = null;
}
}