org.tmatesoft.sqljet.core.internal.table
Interface ISqlJetBtreeDataTable

All Superinterfaces:
ISqlJetBtreeTable
All Known Implementing Classes:
SqlJetBtreeDataTable

public interface ISqlJetBtreeDataTable
extends ISqlJetBtreeTable


Method Summary
 boolean checkIndex(java.lang.String indexName, java.lang.Object[] key)
          Check the current record is equal to key using definition of index.
 void delete()
          Delete curent record.
 void delete(long rowId)
          Delete record by row's ID.
 ISqlJetTableDef getDefinition()
          Get table's schema definition.
 ISqlJetBtreeIndexTable getIndex(java.lang.String indexName)
           
 java.util.Map<java.lang.String,ISqlJetIndexDef> getIndexDefinitions()
          Get definitions of table's indexes.
 java.util.Map<java.lang.String,ISqlJetBtreeIndexTable> getIndexesTables()
          Get indexes which are related with table.
 java.lang.String getPrimaryKeyIndex()
          Get name of index which has been auto-created for primary key.
 long getRowId()
          Get current rowID.
 boolean goToRow(long rowId)
          Go to record with given rowID.
 long insert(SqlJetConflictAction onConflict, java.util.Map<java.lang.String,java.lang.Object> values)
          Insert record by values by names of fields.
 long insert(SqlJetConflictAction onConflict, java.lang.Object... values)
          Write an new entry into the table.
 long insertWithRowId(SqlJetConflictAction onConflict, long rowId, java.lang.Object[] values)
           
 boolean isIndexExists(java.lang.String indexName)
           
 boolean locate(java.lang.String indexName, boolean next, java.lang.Object... key)
          Locate record which using index by key.
 void update(SqlJetConflictAction onConflict, long rowId, java.util.Map<java.lang.String,java.lang.Object> values)
           
 void update(SqlJetConflictAction onConflict, long rowId, java.lang.Object... values)
          Update an entry in the table by rowId.
 void update(SqlJetConflictAction onConflict, java.util.Map<java.lang.String,java.lang.Object> values)
           
 void updateCurrent(SqlJetConflictAction onConflict, java.lang.Object... values)
          Update the current entry in the table.
 long updateCurrentWithRowId(SqlJetConflictAction onConflict, long newRowId, java.lang.Object... values)
          Update the rowId and values in current entry in the table.
 long updateWithRowId(SqlJetConflictAction onConflict, long rowId, long newRowId, java.lang.Object... values)
          Update the rowId and values an entry in the table by rowId.
 
Methods inherited from interface org.tmatesoft.sqljet.core.internal.table.ISqlJetBtreeTable
clear, close, 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
 

Method Detail

getDefinition

ISqlJetTableDef getDefinition()
Get table's schema definition.

Returns:

getIndexDefinitions

java.util.Map<java.lang.String,ISqlJetIndexDef> getIndexDefinitions()
Get definitions of table's indexes.

Returns:

getIndexesTables

java.util.Map<java.lang.String,ISqlJetBtreeIndexTable> getIndexesTables()
Get indexes which are related with table.

Returns:

goToRow

boolean goToRow(long rowId)
                throws SqlJetException
Go to record with given rowID. Return boolean to indicate success.

Parameters:
rowId -
Returns:
Throws:
SqlJetException

getRowId

long getRowId()
              throws SqlJetException
Get current rowID.

Returns:
Throws:
SqlJetException

insert

long insert(SqlJetConflictAction onConflict,
            java.lang.Object... values)
            throws SqlJetException
Write an new entry into the table.

Parameters:
values -
Throws:
SqlJetException

update

void update(SqlJetConflictAction onConflict,
            long rowId,
            java.lang.Object... values)
            throws SqlJetException
Update an entry in the table by rowId.

Parameters:
rowId -
values -
Throws:
SqlJetException

updateCurrent

void updateCurrent(SqlJetConflictAction onConflict,
                   java.lang.Object... values)
                   throws SqlJetException
Update the current entry in the table.

Parameters:
values -
Throws:
SqlJetException

updateWithRowId

long updateWithRowId(SqlJetConflictAction onConflict,
                     long rowId,
                     long newRowId,
                     java.lang.Object... values)
                     throws SqlJetException
Update the rowId and values an entry in the table by rowId.

Parameters:
rowId -
values -
Throws:
SqlJetException

updateCurrentWithRowId

long updateCurrentWithRowId(SqlJetConflictAction onConflict,
                            long newRowId,
                            java.lang.Object... values)
                            throws SqlJetException
Update the rowId and values in current entry in the table.

Parameters:
values -
Throws:
SqlJetException

delete

void delete(long rowId)
            throws SqlJetException
Delete record by row's ID.

Parameters:
rowId -
Throws:
SqlJetException

delete

void delete()
            throws SqlJetException
Delete curent record.

Specified by:
delete in interface ISqlJetBtreeTable
Throws:
SqlJetException

checkIndex

boolean checkIndex(java.lang.String indexName,
                   java.lang.Object[] key)
                   throws SqlJetException
Check the current record is equal to key using definition of index.

Parameters:
indexName -
key -
Returns:
Throws:
SqlJetException

getPrimaryKeyIndex

java.lang.String getPrimaryKeyIndex()
Get name of index which has been auto-created for primary key.

Returns:
the primaryKeyIndex

locate

boolean locate(java.lang.String indexName,
               boolean next,
               java.lang.Object... key)
               throws SqlJetException
Locate record which using index by key. Key is values for fields which are defined in index. If record is found then returns true. If next is true then locate record by next entry in index for key.

Parameters:
indexName -
next -
key -
Returns:
Throws:
SqlJetException

insert

long insert(SqlJetConflictAction onConflict,
            java.util.Map<java.lang.String,java.lang.Object> values)
            throws SqlJetException
Insert record by values by names of fields.

Parameters:
values -
Returns:
Throws:
SqlJetException

update

void update(SqlJetConflictAction onConflict,
            long rowId,
            java.util.Map<java.lang.String,java.lang.Object> values)
            throws SqlJetException
Parameters:
rowId -
values -
Throws:
SqlJetException

update

void update(SqlJetConflictAction onConflict,
            java.util.Map<java.lang.String,java.lang.Object> values)
            throws SqlJetException
Parameters:
values -
Throws:
SqlJetException

isIndexExists

boolean isIndexExists(java.lang.String indexName)
Parameters:
indexName -
Returns:

insertWithRowId

long insertWithRowId(SqlJetConflictAction onConflict,
                     long rowId,
                     java.lang.Object[] values)
                     throws SqlJetException
Parameters:
rowId -
values -
Returns:
Throws:
SqlJetException

getIndex

ISqlJetBtreeIndexTable getIndex(java.lang.String indexName)
Parameters:
indexName -
Returns: