Click or drag to resize

OrderedDictionaryTKey, TValue(IEnumerableKeyValuePairTKey, TValue, IEqualityComparerTKey) Constructor

Initializes a new instance of the OrderedDictionaryTKey, TValue class that contains elements copied from the specified [!:IEnumerable<KeyValuePair<TKey, TValue>>] and uses the specified IEqualityComparerT.

Namespace: GSF.Collections
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.245-beta+94213ae9d4d0aa7a2c48e5398b12d267b99f868a
Syntax
public OrderedDictionary(
	IEnumerable<KeyValuePair<TKey, TValue>> collection,
	IEqualityComparer<TKey> comparer
)
View Source

Parameters

collection  IEnumerableKeyValuePairTKey, TValue
The [!:IEnumerable<KeyValuePair<TKey, TValue>>] whose elements are copied to the new OrderedDictionaryTKey, TValue.
comparer  IEqualityComparerTKey
The IEqualityComparerT implementation to use when comparing keys, or null to use the default EqualityComparerT for the type of the key.
Exceptions
ExceptionCondition
ArgumentNullExceptioncollection is null.
ArgumentExceptioncollection contains one or more duplicate keys.
See Also