Class DefaultValueHashMap<K,V>

java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<K,V>
ch.tocco.nice2.toolbox.api.collection.DefaultValueHashMap<K,V>
All Implemented Interfaces:
Serializable, Cloneable, Map<K,V>

public class DefaultValueHashMap<K,V> extends HashMap<K,V>
A hash map that will populate itself with a value obtained from the given supplier. This is intended when the value type is a container kind of value which is populated in a loop. The first access to this map will create the container and associate it with the given key.
See Also: