ImmutableDictionary<TKey,TValue>.IImmutableDictionary<TKey,TValue>.Add(TKey, TValue) 方法

定义

 virtual System::Collections::Immutable::IImmutableDictionary<TKey, TValue> ^ System.Collections.Immutable.IImmutableDictionary<TKey,TValue>.Add(TKey key, TValue value) = System::Collections::Immutable::IImmutableDictionary<TKey, TValue>::Add;
System.Collections.Immutable.IImmutableDictionary<TKey,TValue> IImmutableDictionary<TKey,TValue>.Add (TKey key, TValue value);
abstract member System.Collections.Immutable.IImmutableDictionary<TKey,TValue>.Add : 'Key * 'Value -> System.Collections.Immutable.IImmutableDictionary<'Key, 'Value>
override this.System.Collections.Immutable.IImmutableDictionary<TKey,TValue>.Add : 'Key * 'Value -> System.Collections.Immutable.IImmutableDictionary<'Key, 'Value>
Function Add (key As TKey, value As TValue) As IImmutableDictionary(Of TKey, TValue) Implements IImmutableDictionary(Of TKey, TValue).Add

参数

key
TKey

要添加的项的键。Key of the entry to be added.

value
TValue

要添加的项的值。Value of the entry to be added.

返回

IImmutableDictionary<TKey,TValue>

一个新的不可变字典,其中包含其他键/值对。A new immutable dictionary that contains the additional key/value pair.

实现

适用于