Add Method
Adds an element with the provided key and value to the IDictionary(TKey, TValue).
Definition
Namespace: Avalonia.Collections
Assembly: Avalonia.Base (in Avalonia.Base.dll)
- C#
- VB
- F#
public void Add(
TKey key,
TValue value
)
Public Sub Add (
key As TKey,
value As TValue
)
abstract Add :
key : 'TKey *
value : 'TValue -> unit
override Add :
key : 'TKey *
value : 'TValue -> unit
Parameters
- TKey
- The object to use as the key of the element to add.
- TValue
- The object to use as the value of the element to add.
Implements
IDictionary(TKey, TValue).Add(TKey, TValue)Exceptions
ArgumentNullException | key is null. |
ArgumentException | An element with the same key already exists in the IDictionary(TKey, TValue). |
NotSupportedException | The IDictionary(TKey, TValue) is read-only. |
See Also
Reference
AvaloniaDictionary(TKey, TValue) Class
Avalonia.Collections Namespace