Class SharedSingletonMap<K,V>

java.lang.Object
org.opendaylight.yangtools.util.SharedSingletonMap<K,V>
Type Parameters:
K - the type of keys maintained by this map
V - the type of mapped values
All Implemented Interfaces:
Serializable, Map<K,V>, Immutable, UnmodifiableMapPhase<K,V>

public abstract sealed class SharedSingletonMap<K,V> extends Object implements Serializable, UnmodifiableMapPhase<K,V>
Implementation of the Map interface which stores a single mapping. The key set is shared among all instances which contain the same key. This implementation does not support null keys or values.

In case the set of keys is statically known, you can use SharedSingletonMapTemplate to efficiently create SharedSingletonMap instances.

See Also: