public class ByteRowKeyComparator extends Object implements Comparator<byte[]>
RowKey.key instances.
Comparison logic in this class is very similar to FrameComparisonWidget, but is different because it works
on byte[] instead of Frames.| Modifier and Type | Method and Description |
|---|---|
int |
compare(byte[] keyArray1,
byte[] keyArray2) |
static int[] |
computeAscDescRunLengths(List<SortColumn> sortColumns)
Given a list of sort columns, compute an array of the number of ascending fields in a run, followed by number of
descending fields in a run, followed by ascending, etc.
|
static int |
computeFirstFieldPosition(int fieldCount)
Compute the offset into each key where the first field starts.
|
static ByteRowKeyComparator |
create(List<SortColumn> keyColumns) |
boolean |
equals(Object o) |
int |
hashCode() |
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcomparing, comparing, comparingDouble, comparingInt, comparingLong, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongpublic static ByteRowKeyComparator create(List<SortColumn> keyColumns)
public static int computeFirstFieldPosition(int fieldCount)
FrameComparisonWidgetImpl can use it.public static int[] computeAscDescRunLengths(List<SortColumn> sortColumns)
FrameComparisonWidgetImpl can use it.public int compare(byte[] keyArray1,
byte[] keyArray2)
compare in interface Comparator<byte[]>public boolean equals(Object o)
equals in interface Comparator<byte[]>equals in class ObjectCopyright © 2011–2022 The Apache Software Foundation. All rights reserved.