Projects each element of a vector to a vector
and flattens the resulting vectors into one vector,
and applies a selector function to each element of the flattened vector.
Namespace:
Extreme.DataAnalysis.Linq
Assembly:
Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.1
public static IEnumerable<TResult> SelectMany<T, TCollection, TResult>(
this Vector<T> vector,
Func<T, IEnumerable<TCollection>> collectionSelector,
Func<T, TCollection, TResult> resultSelector
)
<ExtensionAttribute>
Public Shared Function SelectMany(Of T, TCollection, TResult) (
vector As Vector(Of T),
collectionSelector As Func(Of T, IEnumerable(Of TCollection)),
resultSelector As Func(Of T, TCollection, TResult)
) As IEnumerable(Of TResult)
public:
[ExtensionAttribute]
generic<typename T, typename TCollection, typename TResult>
static IEnumerable<TResult>^ SelectMany(
Vector<T>^ vector,
Func<T, IEnumerable<TCollection>^>^ collectionSelector,
Func<T, TCollection, TResult>^ resultSelector
)
[<ExtensionAttribute>]
static member SelectMany :
vector : Vector<'T> *
collectionSelector : Func<'T, IEnumerable<'TCollection>> *
resultSelector : Func<'T, 'TCollection, 'TResult> -> IEnumerable<'TResult>
Parameters
- vector
- Type: Extreme.MathematicsVectorT
A vector to project. - collectionSelector
- Type: SystemFuncT, IEnumerableTCollection
A function to apply to each element of the input. - resultSelector
- Type: SystemFuncT, TCollection, TResult
A function to apply to each element
of the intermediate vector.
Type Parameters
- T
- The type of the elements of the vector.
- TCollection
- The type of the intermediate elements.
- TResult
- The type of the result.
Return Value
Type:
IEnumerableTResultA vector whose elements are the result of invoking the one-to-many function
collectionSelector on each element of
vector,
and then applying
resultSelector to each element
of the intermediate result.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
VectorT. 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).
Reference