Package org.opendaylight.yangtools.util
Interface ModifiableMapPhase<K,V>
- Type Parameters:
K
- the type of keys maintained by this mapV
- the type of mapped values
- All Known Implementing Classes:
MutableOffsetMap
A
Map
which can be modified and supports efficient conversion to an unmodifiable map. This interface is the
logical counterpart to UnmodifiableMapPhase
, but it does not require implementations of
toUnmodifiableMap()
to return an implementation of that interface. The reason for that empty and singleton
mappings are efficiently represented as ImmutableMap
, which does not implement UnmodifiableMapPhase
.-
Nested Class Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturn an isolated unmodifiable version of this map.Methods inherited from interface java.util.Map
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
-
Method Details
-
toUnmodifiableMap
Return an isolated unmodifiable version of this map. Returned object must not allow removal, addition or changing of mappings. Its mappings must match the mappings currently present in this map, but must not be affected by any subsequent changes to this map.- Returns:
- An unmodifiable version of this map.
-