|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.bigdata.btree.BTree.LeafCursor
public class BTree.LeafCursor
A cursor that may be used to traversal Leafs.
Note: Instances of this class do NOT register an Leaf.ILeafListener
and therefore do NOT notice if mutation causes the current leaf to become
invalid. In general, you need to have a specific key in mind
in order to re-locate the appropriate leaf after such mutation events.
Note: The AbstractBTreeTupleCursor.MutableBTreeTupleCursor does register such listeners.
| Constructor Summary | |
|---|---|
BTree.LeafCursor(byte[] key)
|
|
BTree.LeafCursor(SeekEnum where)
|
|
| Method Summary | |
|---|---|
BTree.LeafCursor |
clone()
Clone the cursor. |
Leaf |
first()
Return the first leaf. |
BTree |
getBTree()
The backing B+Tree. |
Leaf |
last()
Return the last leaf. |
Leaf |
leaf()
The current leaf (always defined). |
Leaf |
next()
Return the next leaf in the natural order of the B+Tree. |
Leaf |
prior()
Materialize the prior leaf in the natural order of the index (this is more general than the right sibling which is restricted to leaves that are children of the same direct parent). |
Leaf |
seek(byte[] key)
Descend from the root node to the leaf spanning that key. |
Leaf |
seek(ILeafCursor<Leaf> src)
Position this cursor on the same leaf as the given cursor. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BTree.LeafCursor(SeekEnum where)
public BTree.LeafCursor(byte[] key)
| Method Detail |
|---|
public Leaf leaf()
ILeafCursor
leaf in interface ILeafCursor<Leaf>public BTree getBTree()
ILeafCursor
getBTree in interface ILeafCursor<Leaf>public BTree.LeafCursor clone()
ILeafCursor
clone in interface ILeafCursor<Leaf>clone in class Objectpublic Leaf first()
ILeafCursor
first in interface ILeafCursor<Leaf>public Leaf last()
ILeafCursor
last in interface ILeafCursor<Leaf>public Leaf seek(byte[] key)
seek in interface ILeafCursor<Leaf>key - The key
null.public Leaf seek(ILeafCursor<Leaf> src)
ILeafCursor
seek in interface ILeafCursor<Leaf>src - A cursor.
public Leaf next()
ILeafCursor
next in interface ILeafCursor<Leaf>null iff there is no next
leaf.public Leaf prior()
As we go down we add each non-leaf node to the hard reference stack.
In order to make this operation atomic, the nodes to be popped are added to a temporary stack until we
prior in interface ILeafCursor<Leaf>null if there is no
predecessor of this leaf.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||