/** * Moves the cursor to the first subtree internal node, which might be empty. Node remains * latched when method returns normally. * * @param frame frame to bind node to * @param node latched internal node; can have no keys * @return latched first internal node, possibly empty, bound by mFrame */ private Node toFirstInternal(CursorFrame frame, Node node) throws IOException { try { while (true) { frame.bind(node, 0); if (node.mSplit != null) { node = finishSplitShared(frame, node); if (frame.mNodePos != 0) { // Rebind if position changed (possibly negative). frame.bindOrReposition(node, 0); } } if (node.isBottomInternal()) { mFrame = frame; return node; } node = mTree.mDatabase.latchToChild(node, 0); frame = new CursorFrame(frame); } } catch (Throwable e) { throw cleanup(e, frame); } }
if (node.isBottomInternal()) { mFrame = frame; return node;
if (node.isBottomInternal()) { if (childId == child.mId && child.isBottomInternal() && --remainingAttemptsBIN >= 0)
if (node.isBottomInternal()) { if (childId == child.mId && child.isBottomInternal() && --remainingAttemptsBIN >= 0)
if (node.isBottomInternal()) { if (childId == child.mId && child.isBottomInternal() && --remainingAttemptsBIN >= 0)
if (!node.isBottomInternal()) { try { if (node.mPage == p_closedTreePage()) {
if (!node.isBottomInternal()) { if (node.mPage == p_closedTreePage()) { return null;
if (!node.isBottomInternal()) { try { if (node.mPage == p_closedTreePage()) {
if (parentNode.isBottomInternal()) { int childCount = parentNode.retrieveChildEntryCount(parentPos);
if (parentNode.isBottomInternal()) { int childCount = parentNode.retrieveChildEntryCount(parentPos);
if (parentNode.isBottomInternal()) { int childCount = parentNode.retrieveChildEntryCount(parentPos);
if (parentNode.isBottomInternal()) { int childCount = parentNode.retrieveChildEntryCount(parentPos);
if (parentNode.isBottomInternal() && (high == null || parentNode != (highFrame = high.mLeaf.mParentFrame).mNode ||
if (parentNode.isBottomInternal() && (high == null || parentNode != (highFrame = high.mLeaf.mParentFrame).mNode ||