KeyValue<K,V>public final class DefaultMapEntry<K,V> extends AbstractMapEntry<K,V>
Map.Entry that prevents
the Map.Entry contract from being broken.| Constructor | Description |
|---|---|
DefaultMapEntry(java.util.Map.Entry<? extends K,? extends V> entry) |
Constructs a new entry from the specified
Map.Entry. |
DefaultMapEntry(K key,
V value) |
Constructs a new entry with the specified key and given value.
|
DefaultMapEntry(KeyValue<? extends K,? extends V> pair) |
Constructs a new entry from the specified
KeyValue. |
getKey, getValue, setKey, toStringequals, hashCode, setValuepublic DefaultMapEntry(K key, V value)
key - the key for the entry, may be nullvalue - the value for the entry, may be nullpublic DefaultMapEntry(KeyValue<? extends K,? extends V> pair)
KeyValue.pair - the pair to copy, must not be nulljava.lang.NullPointerException - if the entry is nullCopyright © 2001-2019 - Apache Software Foundation