public interface ShortBytePair extends Pair<java.lang.Short,java.lang.Byte>
Pair
; provides some additional methods that use polymorphism to avoid (un)boxing.Modifier and Type | Method and Description |
---|---|
default java.lang.Short |
first()
Deprecated.
Please use the corresponding type-specific method instead.
|
default ShortBytePair |
first(short l)
Sets the left element of this pair (optional operation).
|
default ShortBytePair |
first(java.lang.Short l)
Deprecated.
Please use the corresponding type-specific method instead.
|
default short |
firstShort()
Returns the left element of this pair.
|
default java.lang.Short |
key()
Deprecated.
Please use the corresponding type-specific method instead.
|
default ShortBytePair |
key(short l)
Sets the left element of this pair (optional operation).
|
default ShortBytePair |
key(java.lang.Short l)
Deprecated.
|
default short |
keyShort()
Returns the left element of this pair.
|
default java.lang.Short |
left()
Deprecated.
Please use the corresponding type-specific method instead.
|
default ShortBytePair |
left(short l)
Sets the left element of this pair (optional operation).
|
default ShortBytePair |
left(java.lang.Short l)
Deprecated.
Please use the corresponding type-specific method instead.
|
short |
leftShort()
Returns the left element of this pair.
|
static java.util.Comparator<ShortBytePair> |
lexComparator()
Returns a lexicographical comparator for pairs.
|
static ShortBytePair |
of(short left,
byte right)
Returns a new type-specific immutable
Pair with given left and right value. |
default java.lang.Byte |
right()
Deprecated.
Please use the corresponding type-specific method instead.
|
default ShortBytePair |
right(byte r)
Sets the right element of this pair (optional operation).
|
default ShortBytePair |
right(java.lang.Byte l)
Deprecated.
Please use the corresponding type-specific method instead.
|
byte |
rightByte()
Returns the right element of this pair.
|
default java.lang.Byte |
second()
Deprecated.
Please use the corresponding type-specific method instead.
|
default ShortBytePair |
second(byte r)
Sets the right element of this pair (optional operation).
|
default ShortBytePair |
second(java.lang.Byte l)
Deprecated.
Please use the corresponding type-specific method instead.
|
default byte |
secondByte()
Returns the right element of this pair.
|
default java.lang.Byte |
value()
Deprecated.
Please use the corresponding type-specific method instead.
|
default ShortBytePair |
value(byte r)
Sets the right element of this pair (optional operation).
|
default ShortBytePair |
value(java.lang.Byte l)
Deprecated.
Please use the corresponding type-specific method instead.
|
default byte |
valueByte()
Returns the right element of this pair.
|
short leftShort()
@Deprecated default java.lang.Short left()
default ShortBytePair left(short l)
l
- a new value for the left element.UnsupportedOperationException
.@Deprecated default ShortBytePair left(java.lang.Short l)
default short firstShort()
left()
.@Deprecated default java.lang.Short first()
default ShortBytePair first(short l)
l
- a new value for the left element.Pair.left(Object)
.@Deprecated default ShortBytePair first(java.lang.Short l)
default short keyShort()
left()
.@Deprecated default java.lang.Short key()
default ShortBytePair key(short l)
l
- a new value for the left element.Pair.left(Object)
.@Deprecated default ShortBytePair key(java.lang.Short l)
Pair
byte rightByte()
@Deprecated default java.lang.Byte right()
default ShortBytePair right(byte r)
r
- a new value for the right element.UnsupportedOperationException
.@Deprecated default ShortBytePair right(java.lang.Byte l)
default byte secondByte()
right()
.@Deprecated default java.lang.Byte second()
default ShortBytePair second(byte r)
r
- a new value for the right element.Pair.right(Object)
.@Deprecated default ShortBytePair second(java.lang.Byte l)
default byte valueByte()
right()
.@Deprecated default java.lang.Byte value()
default ShortBytePair value(byte r)
r
- a new value for the right element.Pair.right(Object)
.@Deprecated default ShortBytePair value(java.lang.Byte l)
static ShortBytePair of(short left, byte right)
Pair
with given left and right value.static java.util.Comparator<ShortBytePair> lexComparator()
The comparator returned by this method implements lexicographical order. It compares first the left elements: if the result of the comparison is nonzero, it returns said result. Otherwise, this comparator returns the result of the comparison of the right elements.
lexComparator
in interface Pair<java.lang.Short,java.lang.Byte>