net.ranides.assira.collection.map
Class Pair<K,V>

java.lang.Object
  extended by net.ranides.assira.collection.map.Pair<K,V>
All Implemented Interfaces:
Serializable, Map.Entry<K,V>

public class Pair<K,V>
extends Object
implements Map.Entry<K,V>, Serializable

Author:
ranides
See Also:
Serialized Form

Constructor Summary
Pair(K key, V value)
           
 
Method Summary
 boolean equals(Object object)
           
 K getKey()
           
 V getValue()
           
 int hashCode()
           
static
<SK,SV> Pair<SK,SV>
make(SK key, SV value)
           
 V setValue(V value)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Pair

public Pair(K key,
            V value)
Method Detail

make

public static <SK,SV> Pair<SK,SV> make(SK key,
                                       SV value)

getKey

public K getKey()
Specified by:
getKey in interface Map.Entry<K,V>

getValue

public V getValue()
Specified by:
getValue in interface Map.Entry<K,V>

setValue

public V setValue(V value)
Specified by:
setValue in interface Map.Entry<K,V>

hashCode

public int hashCode()
Specified by:
hashCode in interface Map.Entry<K,V>
Overrides:
hashCode in class Object

equals

public boolean equals(Object object)
Specified by:
equals in interface Map.Entry<K,V>
Overrides:
equals in class Object

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2013. All Rights Reserved.