Class OPair<K extends Comparable,V>
java.lang.Object
com.orientechnologies.common.util.OPair<K,V>
- Type Parameters:
K- KeyV- Value
- All Implemented Interfaces:
Serializable,Comparable<OPair<K,,V>> Map.Entry<K,V>
public class OPair<K extends Comparable,V>
extends Object
implements Map.Entry<K,V>, Comparable<OPair<K,V>>, Serializable
Keeps a pair of values as Key/Value.
- Author:
- Luca Garulli (l.garulli--(at)--orientdb.com)
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintstatic <K extends Comparable<K>,V>
List<OPair<K,V>> convertFromMap(Map<K, V> iValues) static <K extends Comparable<K>,V>
Map<K,V> convertToMap(List<OPair<K, V>> iValues) booleangetKey()getValue()inthashCode()voidtoString()
-
Field Details
-
key
-
value
-
-
Constructor Details
-
OPair
public OPair() -
OPair
-
OPair
-
-
Method Details
-
init
-
getKey
- Specified by:
getKeyin interfaceMap.Entry<K extends Comparable,V>
-
getValue
- Specified by:
getValuein interfaceMap.Entry<K extends Comparable,V>
-
setValue
- Specified by:
setValuein interfaceMap.Entry<K extends Comparable,V>
-
toString
-
hashCode
public int hashCode() -
equals
-
compareTo
- Specified by:
compareToin interfaceComparable<K extends Comparable>
-
convertToMap
-
convertFromMap
-