Click or drag to resize

BcfReadOnlyArrayListExtensionsToDictionaryTSource, TKey Method (BcfReadOnlyArrayListTSource, FuncTSource, TKey, IEqualityComparerTKey)

Creates a dictionary based on the contents of this array.

Namespace:  System.Linq
Assembly:  CalculationWorks.BusinessModel (in CalculationWorks.BusinessModel.dll) Version: 4.2.0
Syntax
public static Dictionary<TKey, TSource> ToDictionary<TSource, TKey>(
	this BcfReadOnlyArrayList<TSource> source,
	Func<TSource, TKey> keySelector,
	IEqualityComparer<TKey> comparer
)

Parameters

source
Type: CalculationWorks.BusinessModelBcfReadOnlyArrayListTSource
The source.
keySelector
Type: SystemFuncTSource, TKey
The key selector.
comparer
Type: System.Collections.GenericIEqualityComparerTKey
The comparer to initialize the dictionary with.

Type Parameters

TSource
The type of the elements of source.
TKey
The type of the key.

Return Value

Type: DictionaryTKey, TSource
The newly initialized dictionary.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type BcfReadOnlyArrayListTSource. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also