A SetMultiMap that uses an internal Map based on the provided constructor.
In case no input constructor is provided, the default Map implementation will be used.
It is required that the value type of this map is not Set or any extension of Set, otherwise the set and add functions wil break.
set
add
Will be used to instantiate the internal Map.
Optional
Entries to add to the map.
Readonly
the number of elements in the Map.
Adds the given key/value binding to the Map.
Returns a Readonly Map representation of this Map.
true if an element in the Map existed and has been removed, or false if the element does not exist.
Deletes the given key/value binding from the Map.
Iterates over all distinct keys in this Map.
Iterates over all key/value bindings in this Map.
Iterates over all distinct keys in this Map, together with a Set of their values.
Loops over all key/value bindings.
Returns all values stored for the given key. Returns undefined if there are no values for this key.
undefined
boolean indicating whether an element with the specified key exists or not.
Returns true if this key/value binding exists in the Map.
Returns an iterable of keys in the map
Adds a new element with a specified key and value to the Map. If an element with the same key already exists, the element will be updated.
Iterates over all distinct keys and returns their Set of values.
Iterates over all values in this Map.
A SetMultiMap that uses an internal Map based on the provided constructor.
In case no input constructor is provided, the default Map implementation will be used.
It is required that the value type of this map is not Set or any extension of Set, otherwise the
set
andadd
functions wil break.