Class SqlJetBtreeIndexTable
java.lang.Object
org.tmatesoft.sqljet.core.internal.table.SqlJetBtreeTable
org.tmatesoft.sqljet.core.internal.table.SqlJetBtreeIndexTable
- All Implemented Interfaces:
ISqlJetBtreeIndexTable,ISqlJetBtreeTable
-
Nested Class Summary
Nested classes/interfaces inherited from class org.tmatesoft.sqljet.core.internal.table.SqlJetBtreeTable
SqlJetBtreeTable.State -
Field Summary
Fields inherited from class org.tmatesoft.sqljet.core.internal.table.SqlJetBtreeTable
btree, index, rootPage, write -
Constructor Summary
ConstructorsConstructorDescriptionSqlJetBtreeIndexTable(ISqlJetBtree btree, String indexName, boolean write) Open index by nameSqlJetBtreeIndexTable(ISqlJetBtree btree, String indexName, List<String> columns, boolean write) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidbooleanCheck current record against key.intcompareKey(Object[] key) intcompareKeys(Object[] firstKey, Object[] lastKey) booleanDelete entry which matches to key and point to given rowId.longvoidWrites key into the index.longLookup index entry by key values.longlookupLastNear(Object[] key) longlookupNear(boolean next, Object[] key) voidreindex(ISqlJetSchema schema) Methods inherited from class org.tmatesoft.sqljet.core.internal.table.SqlJetBtreeTable
checkField, clear, clearRecordCache, close, delete, eof, first, getBlob, getCursor, getEncoding, getFieldsCount, getFieldType, getFloat, getInteger, getKeyInfo, getKeySize, getRecord, getString, getValue, getValueMem, getValues, getValueUncached, hasMoved, insert, isNull, last, lock, lockTable, moveTo, newRowId, newRowId, next, popState, previous, pushState, unlockMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.tmatesoft.sqljet.core.internal.table.ISqlJetBtreeTable
clear, close, delete, eof, first, getBlob, getEncoding, getFieldsCount, getFieldType, getFloat, getInteger, getKeySize, getRecord, getString, getValue, getValues, hasMoved, insert, isNull, last, lock, lockTable, moveTo, newRowId, newRowId, next, popState, previous, pushState, unlock
-
Constructor Details
-
SqlJetBtreeIndexTable
public SqlJetBtreeIndexTable(ISqlJetBtree btree, String indexName, boolean write) throws SqlJetException Open index by name- Throws:
SqlJetException
-
SqlJetBtreeIndexTable
public SqlJetBtreeIndexTable(ISqlJetBtree btree, String indexName, List<String> columns, boolean write) throws SqlJetException - Throws:
SqlJetException
-
-
Method Details
-
getIndexDef
- Returns:
- the indexDef
-
lookup
Description copied from interface:ISqlJetBtreeIndexTableLookup index entry by key values. If 'next' is true then just check next entry in index.- Specified by:
lookupin interfaceISqlJetBtreeIndexTable- Parameters:
next- just check next index entryvalues- the key values- Returns:
- Throws:
SqlJetException
-
compareKeys
- Specified by:
compareKeysin interfaceISqlJetBtreeIndexTable- Parameters:
firstKey-lastKey-- Returns:
- Throws:
SqlJetException
-
checkKey
Description copied from interface:ISqlJetBtreeIndexTableCheck current record against key.- Specified by:
checkKeyin interfaceISqlJetBtreeIndexTable- Parameters:
key-- Returns:
- Throws:
SqlJetException
-
adjustKeyInfo
- Overrides:
adjustKeyInfoin classSqlJetBtreeTable- Parameters:
key-- Throws:
SqlJetException
-
insert
Description copied from interface:ISqlJetBtreeIndexTableWrites key into the index. Data for the entry is nil. Append flag that provides a hint to the b-tree layer that this insert is likely to be an append.- Specified by:
insertin interfaceISqlJetBtreeIndexTable- Parameters:
rowId-append-key-- Throws:
SqlJetException
-
delete
Description copied from interface:ISqlJetBtreeIndexTableDelete entry which matches to key and point to given rowId.- Specified by:
deletein interfaceISqlJetBtreeIndexTable- Parameters:
rowId-key-- Returns:
- true if there was deleted entry which matches to key.
- Throws:
SqlJetException
-
getKeyRowId
- Specified by:
getKeyRowIdin interfaceISqlJetBtreeIndexTable- Throws:
SqlJetException
-
reindex
- Throws:
SqlJetException
-
compareKey
- Specified by:
compareKeyin interfaceISqlJetBtreeIndexTable- Parameters:
key-- Returns:
- Throws:
SqlJetException
-
lookupNear
- Specified by:
lookupNearin interfaceISqlJetBtreeIndexTable- Parameters:
key-- Returns:
- Throws:
SqlJetException
-
lookupLastNear
- Specified by:
lookupLastNearin interfaceISqlJetBtreeIndexTable- Parameters:
key-- Returns:
- Throws:
SqlJetException
-