public class ComparablePair<F extends java.lang.Comparable<F>,S> extends Pair<F,S> implements java.lang.Comparable<ComparablePair<F,?>>
Constructor and Description |
---|
ComparablePair(F key,
S value)
Constructor with key and value
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(ComparablePair<F,?> o) |
boolean |
equals(java.lang.Object obj)
Returns
true if obj is also a Pair and contains two
objects equal to the two objects of this Pair. |
int |
hashCode()
Builds a new hash code out of the two objects' hash codes.
|
java.lang.String |
toString() |
public java.lang.String toString()
public int compareTo(ComparablePair<F,?> o)
compareTo
in interface java.lang.Comparable<ComparablePair<F extends java.lang.Comparable<F>,?>>
public boolean equals(java.lang.Object obj)
Pair
true
if obj
is also a Pair and contains two
objects equal to the two objects of this Pair. null
references are
considered as equal, too.@enterprise 9.0.33982 Copyright © 2001-2023 Groiss Informatics GmbH. All Rights Reserved.