public final class IntComparator extends AbstractComparator
nativeHandle_owningHandle_| Constructor and Description |
|---|
IntComparator(ComparatorOptions copt) |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(java.nio.ByteBuffer a,
java.nio.ByteBuffer b)
Three-way key comparison.
|
java.lang.String |
name()
The name of the comparator.
|
findShortestSeparator, findShortSuccessor, initializeNative, usingDirectBuffersdisposeInternalclose, disOwnNativeHandle, isOwningHandlepublic IntComparator(ComparatorOptions copt)
public java.lang.String name()
AbstractComparatorA new name should be used whenever the comparator implementation changes in a way that will cause the relative ordering of any two keys to change.
Names starting with "rocksdb." are reserved and should not be used.
name in class AbstractComparatorpublic int compare(java.nio.ByteBuffer a,
java.nio.ByteBuffer b)
AbstractComparatorByteBuffers passed in, though
it would be unconventional to modify the "limit" or any of the
underlying bytes. As a callback, RocksJava will ensure that a
is a different instance from b.compare in class AbstractComparatora - buffer containing the first key in its "remaining" elementsb - buffer containing the second key in its "remaining" elements