org.apache.ignite.internal.processors.cache.tree

## Class CacheDataTree

- java.lang.Object
- - org.apache.ignite.internal.processors.cache.persistence.DataStructure
  - - org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree<CacheSearchRow,CacheDataRow>
    - - org.apache.ignite.internal.processors.cache.tree.CacheDataTree

All Implemented Interfaces:
  PageLockListener, IgniteTree<CacheSearchRow,CacheDataRow>

    public class CacheDataTree
    extends BPlusTree<CacheSearchRow,CacheDataRow>

### Nested Class Summary

### Nested classes/interfaces inherited from class org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree

`BPlusTree.DestroyBag, BPlusTree.TreeRowClosure<L,T extends L>`

### Nested classes/interfaces inherited from interface org.apache.ignite.internal.util.IgniteTree

`IgniteTree.InvokeClosure<T>, IgniteTree.OperationType`

### Field Summary

### Fields inherited from class org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree

`metaPageId`

### Fields inherited from class org.apache.ignite.internal.processors.cache.persistence.DataStructure

`grpId, pageMem, reuseList, rnd, wal`

### Constructor Summary

Constructors
Constructor and Description
`CacheDataTree(CacheGroupContext grp, String name, ReuseList reuseList, CacheDataRowStore rowStore, long metaPageId, boolean initNew)`

### Method Summary

All Methods Instance Methods Concrete Methods
`protected int` `compare(BPlusIO<CacheSearchRow> iox, long pageAddr, int idx, CacheSearchRow row)`
`protected CacheDataRow` `getRow(BPlusIO<CacheSearchRow> io, long pageAddr, int idx, Object flags)` Get data row.

### Methods inherited from class org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree

`compare, destroy, destroy, find, find, findFirst, findLast, findOne, findOne, getFirstPageIds, getLockRetries, getName, getRow, initTree, initTree, interruptAll, invoke, latestInnerIO, latestLeafIO, printTree, put, putx, remove, removex, rootLevel, setIos, size, size, toString, treeName, validateTree`

### Methods inherited from class org.apache.ignite.internal.processors.cache.persistence.DataStructure

`acquirePage, allocatePage, allocatePage, allocatePageNoReuse, groupId, init, needWalDeltaRecord, onBeforeReadLock, onBeforeWriteLock, onReadLock, onReadUnlock, onWriteLock, onWriteUnlock, pageSize, randomInt, read, read, readLock, readUnlock, recyclePage, releasePage, tryWriteLock, write, write, write, write, writeLock, writeUnlock, writeUnlock`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### CacheDataTree

    public CacheDataTree(CacheGroupContext grp,
                         String name,
                         ReuseList reuseList,
                         CacheDataRowStore rowStore,
                         long metaPageId,
                         boolean initNew)
                  throws IgniteCheckedException

Parameters:
  `grp` - Ccahe group.
  `name` - Tree name.
  `reuseList` - Reuse list.
  `rowStore` - Row store.
  `metaPageId` - Meta page ID.
  `initNew` - Initialize new index.
Throws:
  `IgniteCheckedException` - If failed.

### Method Detail

#### compare

    protected int compare(BPlusIO<CacheSearchRow> iox,
                          long pageAddr,
                          int idx,
                          CacheSearchRow row)
                   throws IgniteCheckedException

Specified by:
  `compare` in class `BPlusTree<CacheSearchRow,CacheDataRow>`
Parameters:
  `iox` - IO.
  `pageAddr` - Page address.
  `idx` - Index of row in the given buffer.
  `row` - Lookup row.
Returns:
  Comparison result as in `Comparator.compare(Object, Object)`.
Throws:
  `IgniteCheckedException` - If failed.

#### getRow

    protected CacheDataRow getRow(BPlusIO<CacheSearchRow> io,
                                  long pageAddr,
                                  int idx,
                                  Object flags)
                           throws IgniteCheckedException

Get data row. Can be called on inner page only if `BPlusTree.canGetRowFromInner` is `true`.

Specified by:
  `getRow` in class `BPlusTree<CacheSearchRow,CacheDataRow>`
Parameters:
  `io` - IO.
  `pageAddr` - Page address.
  `idx` - Index.
  `flags` - Implementation specific argument, `null` always means that we need to return full detached data row.
Returns:
  Data row.
Throws:
  `IgniteCheckedException` - If failed.

2018 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 2.6.0
Release Date | : July 10 2018