|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.emory.mathcs.backport.java.util.AbstractMap.SimpleImmutableEntry
An Entry maintaining an immutable key and value, This class does not support method setValue. This class may be convenient in methods that return thread-safe snapshots of key-value mappings.
Constructor Summary | |
AbstractMap.SimpleImmutableEntry(java.util.Map.Entry entry)
Creates an entry representing the same mapping as the specified entry. |
|
AbstractMap.SimpleImmutableEntry(java.lang.Object key,
java.lang.Object value)
Creates an entry representing a mapping from the specified key to the specified value. |
Method Summary | |
boolean |
equals(java.lang.Object o)
|
java.lang.Object |
getKey()
Returns the key corresponding to this entry. |
java.lang.Object |
getValue()
Returns the value corresponding to this entry. |
int |
hashCode()
|
java.lang.Object |
setValue(java.lang.Object value)
Replaces the value corresponding to this entry with the specified value (optional operation). |
java.lang.String |
toString()
Returns a String representation of this map entry. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public AbstractMap.SimpleImmutableEntry(java.lang.Object key, java.lang.Object value)
key
- the key represented by this entryvalue
- the value represented by this entrypublic AbstractMap.SimpleImmutableEntry(java.util.Map.Entry entry)
entry
- the entry to copyMethod Detail |
public java.lang.Object getKey()
getKey
in interface java.util.Map.Entry
public java.lang.Object getValue()
getValue
in interface java.util.Map.Entry
public java.lang.Object setValue(java.lang.Object value)
setValue
in interface java.util.Map.Entry
value
- new value to be stored in this entry
java.lang.UnsupportedOperationException
- alwayspublic boolean equals(java.lang.Object o)
equals
in interface java.util.Map.Entry
public int hashCode()
hashCode
in interface java.util.Map.Entry
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |