Package com.strobel.core
Class Pair<TFirst,TSecond>
- java.lang.Object
-
- com.strobel.core.Pair<TFirst,TSecond>
-
-
Field Summary
Fields Modifier and Type Field Description private int
_cachedHashCode
private TFirst
_first
private TSecond
_second
private static int
FirstNullHash
private static int
SecondNullHash
private static int
UninitializedHashCode
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(Pair<TFirst,TSecond> o)
static <TFirst,TSecond>
Pair<TFirst,TSecond>create(TFirst first, TSecond second)
boolean
equals(Pair<? extends TFirst,? extends TSecond> other)
boolean
equals(java.lang.Object obj)
TFirst
getFirst()
TSecond
getSecond()
int
hashCode()
java.lang.String
toString()
-
-
-
Field Detail
-
UninitializedHashCode
private static final int UninitializedHashCode
- See Also:
- Constant Field Values
-
FirstNullHash
private static final int FirstNullHash
- See Also:
- Constant Field Values
-
SecondNullHash
private static final int SecondNullHash
- See Also:
- Constant Field Values
-
_first
private final TFirst _first
-
_second
private final TSecond _second
-
_cachedHashCode
private int _cachedHashCode
-
-
Method Detail
-
getFirst
public final TFirst getFirst()
-
getSecond
public final TSecond getSecond()
-
equals
public final boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public final int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
compareTo
public int compareTo(Pair<TFirst,TSecond> o)
- Specified by:
compareTo
in interfacejava.lang.Comparable<TFirst>
-
toString
public final java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
create
public static <TFirst,TSecond> Pair<TFirst,TSecond> create(TFirst first, TSecond second)
-
-