/** * Caller must hold commit lock and exclusive latch on node. This method * should only be called for nodes whose existing data is not needed. */ void redirty(Node node) throws IOException { /*P*/ // [| /*P*/ // if (mFullyMapped) { /*P*/ // mPageDb.dirtyPage(node.mId); /*P*/ // } /*P*/ // ] mDirtyList.add(node, mCommitState); }
/** * Caller must hold commit lock and exclusive latch on node. This method * should only be called for nodes whose existing data is not needed. */ void redirty(Node node) throws IOException { /*P*/ // [| /*P*/ // if (mFullyMapped) { /*P*/ // mPageDb.dirtyPage(node.mId); /*P*/ // } /*P*/ // ] mDirtyList.add(node, mCommitState); }
/** * Caller must hold commit lock and exclusive latch on node. */ private void dirty(Node node, long newId) throws IOException { /*P*/ // [| /*P*/ // if (mFullyMapped) { /*P*/ // if (node.mPage == p_nonTreePage()) { /*P*/ // node.mPage = mPageDb.dirtyPage(newId); /*P*/ // node.asEmptyRoot(); /*P*/ // } else if (node.mPage != p_closedTreePage()) { /*P*/ // node.mPage = mPageDb.copyPage(node.mId, newId); // copy on write /*P*/ // } /*P*/ // } /*P*/ // ] node.mId = newId; mDirtyList.add(node, mCommitState); }
/** * Caller must hold commit lock and exclusive latch on node. */ private void dirty(Node node, long newId) throws IOException { /*P*/ // [| /*P*/ // if (mFullyMapped) { /*P*/ // if (node.mPage == p_nonTreePage()) { /*P*/ // node.mPage = mPageDb.dirtyPage(newId); /*P*/ // node.asEmptyRoot(); /*P*/ // } else if (node.mPage != p_closedTreePage()) { /*P*/ // node.mPage = mPageDb.copyPage(node.mId, newId); // copy on write /*P*/ // } /*P*/ // } /*P*/ // ] node.mId = newId; mDirtyList.add(node, mCommitState); }
/** * Returns a new or recycled Node instance, latched exclusively, marked * dirty and unevictable. Caller must hold commit lock. * * @param mode MODE_UNEVICTABLE if allocated node cannot be automatically evicted */ Node allocDirtyNode(int mode) throws IOException { Node node = mPageDb.allocLatchedNode(this, mode); /*P*/ // [| /*P*/ // if (mFullyMapped) { /*P*/ // node.mPage = mPageDb.dirtyPage(node.mId); /*P*/ // } /*P*/ // ] mDirtyList.add(node, mCommitState); return node; }
/** * Returns a new or recycled Node instance, latched exclusively, marked * dirty and unevictable. Caller must hold commit lock. * * @param mode MODE_UNEVICTABLE if allocated node cannot be automatically evicted */ Node allocDirtyNode(int mode) throws IOException { Node node = mPageDb.allocLatchedNode(this, mode); /*P*/ // [| /*P*/ // if (mFullyMapped) { /*P*/ // node.mPage = mPageDb.dirtyPage(node.mId); /*P*/ // } /*P*/ // ] mDirtyList.add(node, mCommitState); return node; }