public static class Text.Comparator extends WritableComparator
WritableComparator 自然顺序实现(升序).| Constructor and Description |
|---|
Comparator() |
Comparator(Class<? extends WritableComparable> keyClass) |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(byte[] b1,
int s1,
int l1,
byte[] b2,
int s2,
int l2)
基于二进制内容的 Text 对象比较函数.
|
compare, compare, compareBytes, define, get, getKeyClass, hashBytes, newKey, readDouble, readFloat, readInt, readLong, readUnsignedShort, readVInt, readVLongequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcomparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongpublic Comparator()
public Comparator(Class<? extends WritableComparable> keyClass)
public int compare(byte[] b1,
int s1,
int l1,
byte[] b2,
int s2,
int l2)
compare in interface RawComparatorcompare in class WritableComparatorb1 - 对象1二进制内容所在的byte数组s1 - 对象1二进制内容在b1的起始位置l1 - 对象1二进制内容长度b2 - 对象2二进制内容所在的byte数组s2 - 对象2二进制内容在b2的起始位置l2 - 对象2二进制内容长度Copyright © 2021 Alibaba Cloud Computing. All rights reserved.