ImmutableSortedDictionary<TKey,TValue>.AddRange(IEnumerable<KeyValuePair<TKey,TValue>>) 方法

定义

将指定的键/值对添加到不可变排序字典。Adds the specific key/value pairs to the immutable sorted dictionary.

public:
 System::Collections::Immutable::ImmutableSortedDictionary<TKey, TValue> ^ AddRange(System::Collections::Generic::IEnumerable<System::Collections::Generic::KeyValuePair<TKey, TValue>> ^ items);
public System.Collections.Immutable.ImmutableSortedDictionary<TKey,TValue> AddRange (System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TKey,TValue>> items);
member this.AddRange : seq<System.Collections.Generic.KeyValuePair<'Key, 'Value>> -> System.Collections.Immutable.ImmutableSortedDictionary<'Key, 'Value>
Public Function AddRange (items As IEnumerable(Of KeyValuePair(Of TKey, TValue))) As ImmutableSortedDictionary(Of TKey, TValue)

参数

items
IEnumerable<KeyValuePair<TKey,TValue>>

要添加的键/值对。The key/value pairs to add.

返回

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

异常

字典中已存在其中一个给定的键,但具有不同的值。One of the given keys already exists in the dictionary but has a different value.

适用于