public abstract class GridH2IndexBase
extends org.h2.index.BaseIndex
| Modifier and Type | Class and Description |
|---|---|
protected class |
GridH2IndexBase.FilteringIterator
Iterator which filters by expiration time and predicate.
|
| Modifier and Type | Field and Description |
|---|---|
protected static ThreadLocal<IndexingQueryFilter> |
filters |
protected int |
keyCol |
protected int |
valCol |
| Modifier | Constructor and Description |
|---|---|
protected |
GridH2IndexBase(int keyCol,
int valCol) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(org.h2.engine.Session ses,
org.h2.result.Row row) |
void |
checkRename() |
int |
compareRows(org.h2.result.SearchRow rowData,
org.h2.result.SearchRow compare) |
protected Iterator<GridH2Row> |
filter(Iterator<GridH2Row> iter)
Filters rows from expired ones and using predicate.
|
long |
getDiskSpaceUsed() |
boolean |
needRebuild() |
abstract GridH2Row |
put(GridH2Row row)
Put row if absent.
|
GridH2IndexBase |
rebuild()
If the index supports rebuilding it has to creates its own copy.
|
void |
releaseSnapshot()
Releases snapshot for current thread.
|
abstract GridH2Row |
remove(org.h2.result.SearchRow row)
Remove row from index.
|
void |
remove(org.h2.engine.Session ses) |
void |
remove(org.h2.engine.Session ses,
org.h2.result.Row row) |
static void |
setFiltersForThread(IndexingQueryFilter fs)
Sets key filters for current thread.
|
Object |
takeSnapshot(Object s)
Takes or sets existing snapshot to be used in current thread.
|
void |
truncate(org.h2.engine.Session ses) |
canFindNext, canScan, checkIndexColumnTypes, commit, containsNullAndAllowMultipleNull, find, findNext, getColumnIndex, getColumns, getCostRangeIndex, getCreateSQL, getCreateSQLForCopy, getDropSQL, getDuplicateKeyException, getIndexColumns, getIndexType, getPlanSQL, getRow, getTable, getType, initBaseIndex, isHidden, isRowIdIndex, removeChildrenAndResources, setSortedInsertModegetChildren, getComment, getDatabase, getId, getModificationId, getName, initDbObjectBase, invalidate, isTemporary, rename, setComment, setModified, setObjectName, setTemporary, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitprotected static final ThreadLocal<IndexingQueryFilter> filters
protected final int keyCol
protected final int valCol
protected GridH2IndexBase(int keyCol,
int valCol)
keyCol - Key column.valCol - Value column.public static void setFiltersForThread(IndexingQueryFilter fs)
fs - Filters.public GridH2IndexBase rebuild() throws InterruptedException
InterruptedException - If interrupted.public abstract GridH2Row put(GridH2Row row)
row - Row.null.public abstract GridH2Row remove(org.h2.result.SearchRow row)
row - Row.public Object takeSnapshot(@Nullable Object s)
s - Optional existing snapshot to use.public void releaseSnapshot()
public int compareRows(org.h2.result.SearchRow rowData,
org.h2.result.SearchRow compare)
compareRows in interface org.h2.index.IndexcompareRows in class org.h2.index.BaseIndexprotected Iterator<GridH2Row> filter(Iterator<GridH2Row> iter)
iter - Iterator over rows.public long getDiskSpaceUsed()
public void checkRename()
checkRename in interface org.h2.engine.DbObjectcheckRename in class org.h2.engine.DbObjectBasepublic void add(org.h2.engine.Session ses,
org.h2.result.Row row)
public void remove(org.h2.engine.Session ses,
org.h2.result.Row row)
public void remove(org.h2.engine.Session ses)
public void truncate(org.h2.engine.Session ses)
public boolean needRebuild()
Follow @ApacheIgnite
Ignite Fabric : ver. 1.6.0 Release Date : May 18 2016