ConcurrentIndexedDictionaryTKey, TValueAdd Method
Adds a key-value pair to the dictionary, and returns the index at which it was added.
Namespace: SnapDB.CollectionsAssembly: SnapDB (in SnapDB.dll) Version: 1.0.102.0 -- Release Build+29075351d0e5aa4dea46a5c520805222f672dc2e
public int Add(
TKey key,
TValue value
)
Public Function Add (
key As TKey,
value As TValue
) As Integer
public:
int Add(
TKey key,
TValue value
)
function Add(key, value);
- key TKey
- The key to add to the dictionary.
- value TValue
- The value associated with the key.
Int32The index at which the key-value pair was added in the dictionary.
| DuplicateNameException | Thrown if the specified key already exists in the dictionary. |