org.siebengeisslein.indexedlist
Class IntKeys

java.lang.Object
  extended by org.siebengeisslein.client.Persistent
      extended by org.siebengeisslein.indexedlist.IntKeys
All Implemented Interfaces:
Instrumented, BTreeNodeKeys<java.lang.Integer>

public class IntKeys
extends Persistent
implements BTreeNodeKeys<java.lang.Integer>


Constructor Summary
IntKeys(int nodeSize)
           
 
Method Summary
 int findIndex(java.lang.Integer key)
           
 int findIndex(java.lang.Integer key, java.util.Comparator<java.lang.Integer> c)
          This code is duplicated in all BTreeNodeKeys implementations for performance reasons (replacing keys[pos] with get(pos) would result in an additional readLock() call on the keys).
 java.lang.Integer get(int i)
           
 java.lang.Integer getLastKey()
           
 int getMaxSize()
           
 int insert(java.lang.Integer key)
           
 void remove(int index)
           
 void set(int index, java.lang.Integer key)
           
 int size()
           
 BTreeNodeKeys split(int splitIndex)
           
 
Methods inherited from class org.siebengeisslein.client.Persistent
abort, clearUserLocals, clone, commit, disposeTransient, getGroup, getRef, getTransientValue, hashCode, initTransient, isWriteTransaction, joinWriteTransaction, readLock, setGroup, setTransientValue, toPersistent, toRef, writeExternal, writeLock
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IntKeys

public IntKeys(int nodeSize)
Method Detail

get

public java.lang.Integer get(int i)
Specified by:
get in interface BTreeNodeKeys<java.lang.Integer>

getMaxSize

public int getMaxSize()
Specified by:
getMaxSize in interface BTreeNodeKeys<java.lang.Integer>

size

public int size()
Specified by:
size in interface BTreeNodeKeys<java.lang.Integer>

insert

public int insert(java.lang.Integer key)
Specified by:
insert in interface BTreeNodeKeys<java.lang.Integer>

set

public void set(int index,
                java.lang.Integer key)
Specified by:
set in interface BTreeNodeKeys<java.lang.Integer>

findIndex

public int findIndex(java.lang.Integer key)
Specified by:
findIndex in interface BTreeNodeKeys<java.lang.Integer>

getLastKey

public java.lang.Integer getLastKey()
Specified by:
getLastKey in interface BTreeNodeKeys<java.lang.Integer>

split

public BTreeNodeKeys split(int splitIndex)
Specified by:
split in interface BTreeNodeKeys<java.lang.Integer>

remove

public void remove(int index)
Specified by:
remove in interface BTreeNodeKeys<java.lang.Integer>

findIndex

public int findIndex(java.lang.Integer key,
                     java.util.Comparator<java.lang.Integer> c)
This code is duplicated in all BTreeNodeKeys implementations for performance reasons (replacing keys[pos] with get(pos) would result in an additional readLock() call on the keys).

Specified by:
findIndex in interface BTreeNodeKeys<java.lang.Integer>