public override void SetChildAt(IBTreeNode node, int childIndex, int indexDestination, bool throwExceptionIfDoesNotExist) { var childOid = (OID)node.GetChildIdAt(childIndex, throwExceptionIfDoesNotExist); _childrenOids[indexDestination] = childOid; if (childOid != null) { // The parent of the child has changed var child = Btree.GetPersister().LoadNodeById(childOid); child.SetParent(this); Btree.GetPersister().SaveNode(child); } }
public override void SetChildAt(IBTreeNode node, int childIndex, int indexDestination, bool throwExceptionIfDoesNotExist) { var childOid = (OID) node.GetChildIdAt(childIndex, throwExceptionIfDoesNotExist); _childrenOids[indexDestination] = childOid; if (childOid != null) { // The parent of the child has changed var child = Btree.GetPersister().LoadNodeById(childOid); child.SetParent(this); Btree.GetPersister().SaveNode(child); } }