Interface IDictionary<K, V>
A dictionary with keys of type K and values of type V. Equivalent to a finite partial map from K to V.
Inherited Members
Assembly: DistributedLucene.Net.dll
Syntax
public interface IDictionary<K, V> : ICollectionValue<KeyValuePair<K, V>>, Collections.Generic.IEnumerable<KeyValuePair<K, V>>, IShowable, IFormattable
Type Parameters
Name | Description |
---|---|
K | |
V |
Properties
Name | Description |
---|---|
ContainsSpeed | The value is symbolic indicating the type of asymptotic complexity in terms of the size of this collection (worst-case or amortized as relevant). See C5.Speed for the set of symbols. |
EqualityComparer | The key equalityComparer. |
Func | |
IsReadOnly | |
Item[K] | Indexer for dictionary. |
Keys | |
Values |
Methods
Name | Description |
---|---|
Add(K, V) | Add a new (key, value) pair (a mapping) to the dictionary. |
AddAll<U, W>(Collections.Generic.IEnumerable<KeyValuePair<U, W>>) | Add the entries from a collection of C5.KeyValuePair`2 pairs to this dictionary. |
Check() | Check the integrity of the internal data structures of this dictionary. Only available in DEBUG builds??? |
Clear() | Remove all entries from the dictionary |
Contains(K) | Check if there is an entry with a specified key |
ContainsAll<H>(Collections.Generic.IEnumerable<H>) | Check whether this collection contains all the values in another collection. If this collection has bag semantics ( )
the check is made with respect to multiplicities, else multiplicities
are not taken into account.
|
Find(ref K, out V) | Check if there is an entry with a specified key and report the corresponding value if found. This can be seen as a safe form of "val = this[key]". |
FindOrAdd(K, ref V) | Look for a specific key in the dictionary. If found, report the corresponding value, else add an entry with the key and the supplied value. |
Remove(K) | Remove an entry with a given key from the dictionary |
Remove(K, out V) | Remove an entry with a given key from the dictionary and report its value. |
Update(K, V) | Look for a specific key in the dictionary and if found replace the value with a new one. This can be seen as a non-adding version of "this[key] = val". |
Update(K, V, out V) | Look for a specific key in the dictionary and if found replace the value with a new one. This can be seen as a non-adding version of "this[key] = val" reporting the old value. |
UpdateOrAdd(K, V) | Update value in dictionary corresponding to key if found, else add new entry. More general than "this[key] = val;" by reporting if key was found. |
UpdateOrAdd(K, V, out V) | Update value in dictionary corresponding to key if found, else add new entry. More general than "this[key] = val;" by reporting if key was found. |