@InterfaceAudience.Public @InterfaceStability.Evolving public interface CellComparator extends Comparator<Cell>, Serializable
| Modifier and Type | Method and Description | 
|---|---|
int | 
compare(Cell leftCell,
       Cell rightCell)
Lexographically compares two cells. 
 | 
int | 
compare(Cell leftCell,
       Cell rightCell,
       boolean ignoreSequenceid)
Compare cells. 
 | 
int | 
compareFamilies(Cell leftCell,
               Cell rightCell)
Lexicographically compares the families of the two cells 
 | 
int | 
compareQualifiers(Cell leftCell,
                 Cell rightCell)
Lexicographically compares the qualifiers of the two cells 
 | 
default int | 
compareRows(byte[] leftRow,
           byte[] rightRow)
Compares two row bytes 
 | 
default int | 
compareRows(ByteBuffer row,
           Cell cell)
Lexicographically compare two rows 
 | 
int | 
compareRows(Cell cell,
           byte[] bytes,
           int offset,
           int length)
Compares the row part of the cell with a simple plain byte[] like the stopRow in Scan. 
 | 
int | 
compareRows(Cell leftCell,
           Cell rightCell)
Lexographically compares the rows of two cells. 
 | 
int | 
compareTimestamps(Cell leftCell,
                 Cell rightCell)
Compares cell's timestamps in DESCENDING order. 
 | 
int | 
compareTimestamps(long leftCellts,
                 long rightCellts)
Compares cell's timestamps in DESCENDING order. 
 | 
int | 
compareWithoutRow(Cell leftCell,
                 Cell rightCell)
Lexicographically compares the two cells excluding the row part. 
 | 
static CellComparator | 
getInstance()
A comparator for ordering cells in user-space tables. 
 | 
Comparator<Cell> | 
getSimpleComparator()
Return a dumbed-down, fast comparator for hbase2 base-type, the  
ByteBufferKeyValue. | 
comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongstatic CellComparator getInstance()
CAUTION: This comparator may provide inaccurate ordering for cells from system tables, and should not be relied upon in that case.
int compare(Cell leftCell, Cell rightCell)
compare in interface Comparator<Cell>leftCell - the left hand side cellrightCell - the right hand side cellint compare(Cell leftCell, Cell rightCell, boolean ignoreSequenceid)
ignoreSequenceid - True if we are to compare the key portion only and ignore the
                         sequenceid. Set to false to compare key and consider sequenceid.int compareRows(Cell leftCell, Cell rightCell)
leftCell - the left hand side cellrightCell - the right hand side cellint compareRows(Cell cell, byte[] bytes, int offset, int length)
cell - the cellbytes - the byte[] representing the row to be compared withoffset - the offset of the byte[]length - the length of the byte[]default int compareRows(byte[] leftRow, byte[] rightRow)
leftRow - the byte array of the left rowrightRow - the byte array of the right rowdefault int compareRows(ByteBuffer row, Cell cell)
row - ByteBuffer that wraps a row; will read from current position and will reading all
            remaining; will not disturb the ByteBuffer internal state.int compareWithoutRow(Cell leftCell, Cell rightCell)
leftCell - the left hand side cellrightCell - the right hand side cellint compareFamilies(Cell leftCell, Cell rightCell)
leftCell - the left hand side cellrightCell - the right hand side cellint compareQualifiers(Cell leftCell, Cell rightCell)
leftCell - the left hand side cellrightCell - the right hand side cellint compareTimestamps(Cell leftCell, Cell rightCell)
leftCell - the left hand side cellrightCell - the right hand side cellint compareTimestamps(long leftCellts, long rightCellts)
leftCellts - the left cell's timestamprightCellts - the right cell's timestampComparator<Cell> getSimpleComparator()
ByteBufferKeyValue.
 Create an instance when you make a new memstore, when you know only BBKVs will be passed. Do
 not pollute with types other than BBKV if can be helped; the Comparator will slow.Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.