LookupExtensionsToReadOnlyLookupTSource, TKey, TElement(IEnumerableTSource, FuncTSource, TKey, FuncTSource, TElement) Method

Definition

Namespace: Jodosoft.Collections
Assembly: Jodosoft.Collections (in Jodosoft.Collections.dll) Version: 2.0
public static IReadOnlyLookup<TKey, TElement> ToReadOnlyLookup<TSource, TKey, TElement>(
	this IEnumerable<TSource> source,
	Func<TSource, TKey> keySelector,
	Func<TSource, TElement> elementSelector
)

Parameters

source  IEnumerableTSource
 
keySelector  FuncTSource, TKey
 
elementSelector  FuncTSource, TElement
 

Type Parameters

TSource
TKey
TElement

Return Value

IReadOnlyLookupTKey, TElement

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IEnumerableTSource. 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