java.lang.Object
org.hsqldb.Node
org.hsqldb.DiskNode
- class DiskNode
- extends Node
Cached table Node implementation.
Only integral references to left, right and parent nodes in the AVL tree
are held and used as offsets to disk data.
tTable is a reference to the table for this node and is used to get a
linked node in the tree.
iId is a reference to the Index object that contains this node.
These fields can be eliminated in the future, by changing the
method signatures to take a Table parameter from Index.java (fredt@users)
- Version:
- 1.7.1
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
iLeft
private int iLeft
iRight
private int iRight
iParent
private int iParent
iId
private int iId
iData
private int iData
tTable
private Table tTable
TYPE_MEMORY
static final int TYPE_MEMORY
- See Also:
- Constant Field Values
TYPE_DISK
static final int TYPE_DISK
- See Also:
- Constant Field Values
TYPE_POINTER
static final int TYPE_POINTER
- See Also:
- Constant Field Values
NO_POS
static final int NO_POS
- See Also:
- Constant Field Values
iBalance
protected int iBalance
rData
protected Row rData
nNext
Node nNext
DiskNode
DiskNode(CachedRow r,
DatabaseRowInputInterface in,
int id)
throws java.io.IOException,
java.sql.SQLException
DiskNode
DiskNode(CachedRow r,
int id)
delete
void delete()
- Description copied from class:
Node
- Method declaration
- Specified by:
delete in class Node
getKey
int getKey()
- Description copied from class:
Node
- File offset of Node. Used with CachedRow objects only
- Specified by:
getKey in class Node
setKey
void setKey(int pos)
- Description copied from class:
Node
- Used with CachedRow objects only
- Specified by:
setKey in class Node
getRow
Row getRow()
throws java.sql.SQLException
- Specified by:
getRow in class Node
findNode
private Node findNode(int pos,
int id)
throws java.sql.SQLException
getLeft
Node getLeft()
throws java.sql.SQLException
- Specified by:
getLeft in class Node
setLeft
void setLeft(Node n)
throws java.sql.SQLException
- Specified by:
setLeft in class Node
getRight
Node getRight()
throws java.sql.SQLException
- Specified by:
getRight in class Node
getRightPointer
Node getRightPointer()
throws java.sql.SQLException
- Used with PointerNode objects only
- Specified by:
getRightPointer in class Node
setRight
void setRight(Node n)
throws java.sql.SQLException
- Specified by:
setRight in class Node
getParent
Node getParent()
throws java.sql.SQLException
- Specified by:
getParent in class Node
isRoot
boolean isRoot()
- Specified by:
isRoot in class Node
setParent
void setParent(Node n)
throws java.sql.SQLException
- Specified by:
setParent in class Node
setBalance
void setBalance(int b)
throws java.sql.SQLException
- Specified by:
setBalance in class Node
from
boolean from()
throws java.sql.SQLException
- Description copied from class:
Node
- Method declaration
- Specified by:
from in class Node
getData
java.lang.Object[] getData()
throws java.sql.SQLException
- Description copied from class:
Node
- Returns the data held in the table Row for this Node
- Specified by:
getData in class Node
equals
boolean equals(Node n)
throws java.sql.SQLException
- Specified by:
equals in class Node
write
void write(DatabaseRowOutputInterface out)
throws java.io.IOException,
java.sql.SQLException
- Description copied from class:
Node
- Writes out the node in an implementation dependent way.
- Specified by:
write in class Node
newNode
static final Node newNode(Row r,
int id,
Table t)
newNode
static final Node newNode(Row r,
DatabaseRowInputInterface in,
int id,
Table t)
throws java.io.IOException,
java.sql.SQLException
getBalance
final int getBalance()
throws java.sql.SQLException