A collection of key/value pairs, from which you retrieve a value using its associated key.
There is a finite number of keys in the map, and each key has exactly one value associated with it.
Maps, and their keys and values, can be iterated. The order of iteration is defined by the individual type of map. Examples:
It is generally not allowed to modify the map (add or remove keys) while an operation is being performed on the map, for example in functions called during a forEach or putIfAbsent call. Modifying the map while iterating the keys or values may also break the iteration.
It is generally not allowed to modify the equality of keys (and thus not their hashcode) while they are in the map. Some specialized subtypes may be more permissive, in which case they should document this behavior.
other
. [...]
iterable
. [...]
keys
to values
. [...]
other
. [...]
other
. [...]
other
to this map. [...]
newEntries
to this map. [...]
RK
keys and RV
instances,
if necessary. [...]
key
. [...]
value
. [...]
f
to each key/value pair of the map. [...]
f
function.
key
, or add a new value if it isn't there. [...]
key
and its associated value, if present, from the map. [...]
predicate
.
key
. [...]
key
or null if key
is not in the map. [...]
key
with the given value
. [...]