|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.hbase.codec.prefixtree.decode.PrefixTreeCell
org.apache.hadoop.hbase.codec.prefixtree.decode.PrefixTreeArrayScanner
@InterfaceAudience.Private public class PrefixTreeArrayScanner
Extends PtCell and manipulates its protected fields. Could alternatively contain a PtCell and call get/set methods. This is an "Array" scanner to distinguish from a future "ByteBuffer" scanner. This implementation requires that the bytes be in a normal java byte[] for performance. The alternative ByteBuffer implementation would allow for accessing data in an off-heap ByteBuffer without copying the whole buffer on-heap.
Field Summary | |
---|---|
protected boolean |
afterLast
|
protected boolean |
beforeFirst
|
protected PrefixTreeBlockMeta |
blockMeta
fields |
protected int |
currentCellIndex
|
protected RowNodeReader |
currentRowNode
|
protected ColumnReader |
familyReader
|
protected MvccVersionDecoder |
mvccVersionDecoder
|
protected boolean |
nubCellsRemain
|
protected ColumnReader |
qualifierReader
|
protected RowNodeReader[] |
rowNodes
|
protected int |
rowNodeStackIndex
|
protected ColumnReader |
tagsReader
|
protected TimestampDecoder |
timestampDecoder
|
Fields inherited from class org.apache.hadoop.hbase.codec.prefixtree.decode.PrefixTreeCell |
---|
absoluteValueOffset, block, DEFAULT_TYPE, familyBuffer, familyLength, familyOffset, includeMvccVersion, mvccVersion, qualifierBuffer, qualifierLength, qualifierOffset, rowBuffer, rowLength, tagsBuffer, tagsLength, tagsOffset, timestamp, type, TYPES, valueLength |
Constructor Summary | |
---|---|
PrefixTreeArrayScanner(PrefixTreeBlockMeta blockMeta,
int rowTreeDepth,
int rowBufferLength,
int qualifierBufferLength,
int tagsBufferLength)
construct |
Method Summary | |
---|---|
boolean |
advance()
|
protected void |
appendCurrentTokenToRowBuffer()
helper methods |
protected void |
appendToRowBuffer(byte b)
|
boolean |
areBuffersBigEnough()
Call when first accessing a block. |
Cell |
current()
CellScanner |
protected void |
discardCurrentRowNode(boolean forwards)
|
boolean |
equals(Object obj)
Object methods |
protected void |
followCurrentFan()
|
protected void |
followFan(int fanIndex)
|
protected void |
followFirstFan()
|
protected void |
followLastFan()
|
protected void |
followNextFan()
|
protected void |
followPreviousFan()
|
PrefixTreeBlockMeta |
getBlockMeta()
|
int |
getMaxRowTreeStackNodes()
|
int |
getQualifierBufferLength()
|
int |
getRowBufferLength()
|
int |
getTagBufferLength()
|
byte[] |
getTreeBytes()
getters |
int |
hashCode()
|
protected boolean |
hasOccurrences()
|
protected void |
initFirstNode()
|
void |
initOnBlock(PrefixTreeBlockMeta blockMeta,
byte[] block,
boolean includeMvccVersion)
|
boolean |
isAfterLast()
|
boolean |
isBeforeFirst()
|
protected boolean |
isBranch()
|
protected boolean |
isFirstCellInRow()
|
protected boolean |
isLastCellInRow()
|
protected boolean |
isLeaf()
|
protected boolean |
isNub()
|
protected boolean |
isOutOfBounds()
|
protected void |
markAfterLast()
|
protected void |
markBeforeFirst()
|
boolean |
nextRow()
|
protected boolean |
nextRowInternal()
This method is safe to call when the scanner is not on a fully valid row node, as in the case of a row token miss in the Searcher |
protected void |
popFromRowBuffer(RowNodeReader rowNodeBeingPopped)
|
protected void |
populateFamily()
|
protected void |
populateFirstNonRowFields()
|
protected void |
populateLastNonRowFields()
|
protected void |
populateMvccVersion()
|
protected void |
populateNonRowFields(int cellIndex)
|
protected int |
populateNonRowFieldsAndCompareTo(int cellNum,
Cell key)
fill in family/qualifier/ts/type/value |
protected void |
populatePreviousNonRowFields()
|
protected void |
populateQualifier()
|
protected void |
populateTag()
|
protected void |
populateTimestamp()
|
protected void |
populateType()
|
protected void |
populateValueOffsets()
|
boolean |
positionAtFirstCell()
advance |
protected void |
reInitFirstNode()
secondary traversal methods |
void |
releaseBlockReference()
Call this before putting the scanner back into a pool so it doesn't hold the last used block in memory. |
void |
resetToBeforeFirstEntry()
|
String |
toString()
Override PrefixTreeCell.toString() with a check to see if the current cell is valid. |
Methods inherited from class org.apache.hadoop.hbase.codec.prefixtree.decode.PrefixTreeCell |
---|
compareTo, getFamily, getFamilyArray, getFamilyLength, getFamilyOffset, getKeyValueString, getMvccVersion, getQualifier, getQualifierArray, getQualifierLength, getQualifierOffset, getRow, getRowArray, getRowLength, getRowOffset, getTagsArray, getTagsLength, getTagsLengthUnsigned, getTagsOffset, getTimestamp, getTypeByte, getValue, getValueArray, getValueLength, getValueOffset |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected PrefixTreeBlockMeta blockMeta
protected boolean beforeFirst
protected boolean afterLast
protected RowNodeReader[] rowNodes
protected int rowNodeStackIndex
protected RowNodeReader currentRowNode
protected ColumnReader familyReader
protected ColumnReader qualifierReader
protected ColumnReader tagsReader
protected TimestampDecoder timestampDecoder
protected MvccVersionDecoder mvccVersionDecoder
protected boolean nubCellsRemain
protected int currentCellIndex
Constructor Detail |
---|
public PrefixTreeArrayScanner(PrefixTreeBlockMeta blockMeta, int rowTreeDepth, int rowBufferLength, int qualifierBufferLength, int tagsBufferLength)
Method Detail |
---|
public boolean areBuffersBigEnough()
public void initOnBlock(PrefixTreeBlockMeta blockMeta, byte[] block, boolean includeMvccVersion)
public void resetToBeforeFirstEntry()
public void releaseBlockReference()
public Cell current()
current
in interface CellScanner
public boolean equals(Object obj)
equals
in class PrefixTreeCell
public int hashCode()
hashCode
in class PrefixTreeCell
public String toString()
toString
in class PrefixTreeCell
public boolean positionAtFirstCell()
public boolean advance()
advance
in interface CellScanner
public boolean nextRow()
protected boolean nextRowInternal()
protected void reInitFirstNode()
protected void initFirstNode()
protected void followFirstFan()
protected void followPreviousFan()
protected void followCurrentFan()
protected void followNextFan()
protected void followLastFan()
protected void followFan(int fanIndex)
protected void discardCurrentRowNode(boolean forwards)
forwards
- which marker to set if we overflowprotected void markBeforeFirst()
protected void markAfterLast()
protected void appendCurrentTokenToRowBuffer()
protected void appendToRowBuffer(byte b)
protected void popFromRowBuffer(RowNodeReader rowNodeBeingPopped)
protected boolean hasOccurrences()
protected boolean isBranch()
protected boolean isNub()
protected boolean isLeaf()
public boolean isBeforeFirst()
public boolean isAfterLast()
protected boolean isOutOfBounds()
protected boolean isFirstCellInRow()
protected boolean isLastCellInRow()
protected int populateNonRowFieldsAndCompareTo(int cellNum, Cell key)
protected void populateFirstNonRowFields()
protected void populatePreviousNonRowFields()
protected void populateLastNonRowFields()
protected void populateNonRowFields(int cellIndex)
protected void populateFamily()
protected void populateQualifier()
protected void populateTag()
protected void populateTimestamp()
protected void populateMvccVersion()
protected void populateType()
protected void populateValueOffsets()
public byte[] getTreeBytes()
public PrefixTreeBlockMeta getBlockMeta()
public int getMaxRowTreeStackNodes()
public int getRowBufferLength()
public int getQualifierBufferLength()
public int getTagBufferLength()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |