vibe.d beta banner
get vibe.d
0.8.0

Asynchronous I/O that doesn’t get in your way, written in D

Struct DictionaryList

Behaves similar to VALUE[string] but the insertion order is not changed and multiple values per key are supported.

struct DictionaryList(VALUE, bool case_sensitive = true, ulong NUM_STATIC_FIELDS = 32, bool USE_HASHSUM = false) ;

This kind of map is used for MIME headers (e.g. for HTTP, see vibe.inet.message.InetHeaderMap), or for form data (vibe.inet.webform.FormFields). Note that the map can contain fields with the same key multiple times if addField is used for insertion. Insertion order is preserved.

Note that despite case not being relevant for matching keyse, iterating over the map will yield the original case of the key that was put in.

Insertion and lookup has O(n) complexity.

Fields

Fields

NameTypeDescription
m_extendedFieldsDictionaryList.Field[]
m_fieldCountsize_t
m_fieldsDictionaryList.Field[NUM_STATIC_FIELDS]

Properties

Properties

NameTypeDescription
length[get]size_tThe number of fields present in the map.

Methods

Methods

NameDescription
addFieldAdds a new field to the map.
addField
byKeyIterates over all fields, including duplicates.
byKeyValue
byKeyValue
byValue
fromRepresentationSupports serialization using vibe.data.serialization.
getReturns the first field that matches the given key.
getAllReturns all values matching the given key.
getIndex
matches
opBinaryRightReturns a pointer to the first field that matches the given key.
opIndexReturns the first value matching the given key.
opIndexAssignAdds or replaces the given field with a new value.
removeRemoves the first field that matches the given key.
removeAllRemoves all fields that matches the given key.
toRepresentationSupports serialization using vibe.data.serialization.

Inner structs

Inner structs

NameDescription
Field
FieldTuple

Aliases

Aliases

NameDescription
KeyValue
ValueType
Authors

Sönke Ludwig

Copyright

© 2012-2014 RejectedSoftware e.K.

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.