org.axiondb.engine.indexes
Class IntArrayIndex

java.lang.Object
  extended by org.axiondb.event.BaseTableModificationListener
      extended by org.axiondb.engine.indexes.BaseIndex
          extended by org.axiondb.engine.indexes.BaseArrayIndex
              extended by org.axiondb.engine.indexes.IntArrayIndex
All Implemented Interfaces:
TableModificationListener, Index

public class IntArrayIndex
extends BaseArrayIndex

An array indexover integer keys.

Version:
$Revision: 1.4 $ $Date: 2005/03/12 02:10:41 $

Field Summary
 
Fields inherited from interface org.axiondb.Index
ARRAY, BTREE, DEFAULT, TTREE
 
Constructor Summary
IntArrayIndex(java.lang.String name, Column column, boolean unique)
           
IntArrayIndex(java.lang.String name, Column column, boolean unique, org.apache.commons.collections.primitives.IntList keys, org.apache.commons.collections.primitives.IntList values)
           
 
Method Summary
protected  int find(int seeking, boolean required)
           
protected  int find(java.lang.Object value, boolean required)
           
 IndexLoader getIndexLoader()
           
 java.util.List getKeyList()
           
protected  java.util.List getKeyList(int minIndex, int maxIndex)
           
protected  int insertKey(int seeking)
           
protected  int insertKey(java.lang.Object value)
           
protected  int removeKey(int seeking)
           
protected  int removeKey(java.lang.Object value)
           
protected  void removeKeyAt(int index)
           
 void truncate()
           
 
Methods inherited from class org.axiondb.engine.indexes.BaseArrayIndex
changeRowId, getInorderRowIterator, getRowIterator, getType, getValueList, rowDeleted, rowInserted, rowUpdated, save, saveAfterTruncate, supportsFunction
 
Methods inherited from class org.axiondb.engine.indexes.BaseIndex
getComparator, getDataType, getIndexedColumn, getName, isUnique
 
Methods inherited from class org.axiondb.event.BaseTableModificationListener
columnAdded, constraintAdded, constraintRemoved
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.axiondb.Index
getIndexedColumn, getName, isUnique
 
Methods inherited from interface org.axiondb.event.TableModificationListener
columnAdded, constraintAdded, constraintRemoved
 

Constructor Detail

IntArrayIndex

public IntArrayIndex(java.lang.String name,
                     Column column,
                     boolean unique)

IntArrayIndex

public IntArrayIndex(java.lang.String name,
                     Column column,
                     boolean unique,
                     org.apache.commons.collections.primitives.IntList keys,
                     org.apache.commons.collections.primitives.IntList values)
Method Detail

getIndexLoader

public IndexLoader getIndexLoader()
Specified by:
getIndexLoader in interface Index
Specified by:
getIndexLoader in class BaseArrayIndex

getKeyList

public java.util.List getKeyList()
Specified by:
getKeyList in class BaseArrayIndex

truncate

public void truncate()
              throws AxionException
Specified by:
truncate in interface Index
Overrides:
truncate in class BaseArrayIndex
Throws:
AxionException

find

protected int find(int seeking,
                   boolean required)

find

protected int find(java.lang.Object value,
                   boolean required)
Specified by:
find in class BaseArrayIndex

getKeyList

protected java.util.List getKeyList(int minIndex,
                                    int maxIndex)
Specified by:
getKeyList in class BaseArrayIndex

insertKey

protected int insertKey(int seeking)
                 throws AxionException
Throws:
AxionException

insertKey

protected int insertKey(java.lang.Object value)
                 throws AxionException
Specified by:
insertKey in class BaseArrayIndex
Throws:
AxionException

removeKey

protected int removeKey(int seeking)
                 throws AxionException
Throws:
AxionException

removeKey

protected int removeKey(java.lang.Object value)
                 throws AxionException
Specified by:
removeKey in class BaseArrayIndex
Throws:
AxionException

removeKeyAt

protected void removeKeyAt(int index)
                    throws AxionException
Specified by:
removeKeyAt in class BaseArrayIndex
Throws:
AxionException