public abstract class AbstractByteComparator extends java.lang.Object implements ByteComparator
To create a type-specific comparator you need both a method comparing primitive types and a method comparing objects. However, if you have the first one you can just inherit from this class and get for free the second one.
Comparator
Modifier and Type | Method and Description |
---|---|
abstract int |
compare(byte k1,
byte k2)
Compares the given primitive types.
|
int |
compare(java.lang.Byte ok1,
java.lang.Byte ok2) |
public int compare(java.lang.Byte ok1, java.lang.Byte ok2)
compare
in interface java.util.Comparator<java.lang.Byte>
public abstract int compare(byte k1, byte k2)
ByteComparator
compare
in interface ByteComparator
Comparator