public interface ShortComparator
extends java.util.Comparator<java.lang.Short>
| Modifier and Type | Interface and Description |
|---|---|
static class |
ShortComparator.Reversed
A Type Specific Reversed Comparator to reduce boxing/unboxing
|
| Modifier and Type | Method and Description |
|---|---|
int |
compare(short o1,
short o2)
Type-Specific compare function to reduce (un)boxing
|
default int |
compare(java.lang.Short o1,
java.lang.Short o2)
Deprecated.
Please use the corresponding type-specific function instead.
|
static ShortComparator |
of(java.util.Comparator<java.lang.Short> c)
A Wrapper function to convert a Non-Type-Specific Comparator to a Type-Specific-Comparator
|
default ShortComparator |
reversed() |
int compare(short o1,
short o2)
o1 - the first object to be compared.o2 - the second object to be compared.Comparator.compare(Object, Object)@Deprecated
default int compare(java.lang.Short o1,
java.lang.Short o2)
This default implementation delegates to the corresponding type-specific function.
compare in interface java.util.Comparator<java.lang.Short>static ShortComparator of(java.util.Comparator<java.lang.Short> c)
c - comparator to convertjava.lang.NullPointerException - if the comparator is nulldefault ShortComparator reversed()
reversed in interface java.util.Comparator<java.lang.Short>