Implements a {@link MultiValuedMap}, using a {@link HashMap} to provide datastorage. This is the standard implementation of a MultiValuedMap
A MultiValuedMap
is a Map with slightly different semantics. Putting a value into the map will add the value to a Collection at that key. Getting a value will return a Collection, holding all the values put to that key
In addition, this implementation allows the type of collection used for the values to be controlled. By default, an ArrayList
is used, however a Class extends Collection>
to instantiate the value collection may be specified.
Note that MultiValuedHashMap is not synchronized and is not thread-safe. If you wish to use this map from multiple threads concurrently, you must use appropriate synchronization. This class may throw exceptions when accessed by concurrent threads without synchronization.
@since 4.1
@version $Id$