MultiMap

A multi valued Map.

@param !V the entry type for multimap values

Constructors

this
this()
Undocumented in source.
this
this(Map!(string, List!(V)) map)
Undocumented in source.
this
this(MultiMap!V map)
Undocumented in source.

Members

Aliases

put
alias put = HashMap!(string, List!(V)).put
Undocumented in source.

Functions

add
void add(string name, V value)

Add value to multi valued entry. If the entry is single valued, it is converted to the first value of a multi valued entry.

addValues
void addValues(string name, List!(V) values)

Add values to multi valued entry. If the entry is single valued, it is converted to the first value of a multi valued entry.

addValues
void addValues(string name, V[] values)

Add values to multi valued entry. If the entry is single valued, it is converted to the first value of a multi valued entry.

containsSimpleValue
bool containsSimpleValue(V value)

Test for a specific single value in the map. <p> NOTE: This is a SLOW operation, and is actively discouraged.

getString
string getString(string name)

Get value as string. Single valued items are converted to a string with the toString() Object method. Multi valued entries are converted to a comma separated List. No quoting of commas within values is performed.

getValue
V getValue(string name, int i)

Get a value from a multiple value. If the value is not a multivalue, then index 0 retrieves the value or null.

getValues
List!(V) getValues(string name)

Get multiple values. Single valued entries are converted to singleton lists.

put
List!(V) put(string name, V value)

Put multi valued entry.

putAllValues
void putAllValues(Map!(string, V) input)

Shorthand version of putAll

putValues
List!(V) putValues(string name, List!(V) values)

Put multi valued entry.

putValues
List!(V) putValues(string name, V[] values)

Put multi valued entry.

removeValue
bool removeValue(string name, V value)

Remove value.

toString
string toString()
Undocumented in source. Be warned that the author may not have intended to support it.

Meta