AsyncEnumerable.Select Method (System.Linq) (original) (raw)

Definition

Namespace:

System.Linq

Assembly:

System.Linq.AsyncEnumerable.dll

Package:

System.Linq.AsyncEnumerable v10.0.0-preview.4.25258.110

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Overloads

Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,Int32,CancellationToken,ValueTask>) Projects each element of a sequence into a new form by incorporating the element's index.
Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,Int32,TResult>) Projects each element of a sequence into a new form by incorporating the element's index.
Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,CancellationToken,ValueTask>) Projects each element of a sequence into a new form.
Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,TResult>) Projects each element of a sequence into a new form.

Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,Int32,CancellationToken,ValueTask>)

Source:

Select.cs

Projects each element of a sequence into a new form by incorporating the element's index.

public:
generic <typename TSource, typename TResult>
[System::Runtime::CompilerServices::Extension]
 static System::Collections::Generic::IAsyncEnumerable<TResult> ^ Select(System::Collections::Generic::IAsyncEnumerable<TSource> ^ source, Func<TSource, int, System::Threading::CancellationToken, System::Threading::Tasks::ValueTask<TResult>> ^ selector);
public static System.Collections.Generic.IAsyncEnumerable<TResult> Select<TSource,TResult>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, Func<TSource,int,System.Threading.CancellationToken,System.Threading.Tasks.ValueTask<TResult>> selector);
static member Select : System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, int, System.Threading.CancellationToken, System.Threading.Tasks.ValueTask<'Result>> -> System.Collections.Generic.IAsyncEnumerable<'Result>
<Extension()>
Public Function Select(Of TSource, TResult) (source As IAsyncEnumerable(Of TSource), selector As Func(Of TSource, Integer, CancellationToken, ValueTask(Of TResult))) As IAsyncEnumerable(Of TResult)

Type Parameters

TSource

The type of the elements of source.

TResult

The type of the value returned by selector.

Parameters

source

IAsyncEnumerable

A sequence of values to invoke a transform function on.

selector

Func<TSource,Int32,CancellationToken,ValueTask>

A transform function to apply to each element; the second parameter of the function represents the index of the source element.

Returns

An IAsyncEnumerable whose elements are the result of invoking the transform function on each element of source.

Exceptions

Applies to

Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,Int32,TResult>)

Source:

Select.cs

Projects each element of a sequence into a new form by incorporating the element's index.

public:
generic <typename TSource, typename TResult>
[System::Runtime::CompilerServices::Extension]
 static System::Collections::Generic::IAsyncEnumerable<TResult> ^ Select(System::Collections::Generic::IAsyncEnumerable<TSource> ^ source, Func<TSource, int, TResult> ^ selector);
public static System.Collections.Generic.IAsyncEnumerable<TResult> Select<TSource,TResult>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, Func<TSource,int,TResult> selector);
static member Select : System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, int, 'Result> -> System.Collections.Generic.IAsyncEnumerable<'Result>
<Extension()>
Public Function Select(Of TSource, TResult) (source As IAsyncEnumerable(Of TSource), selector As Func(Of TSource, Integer, TResult)) As IAsyncEnumerable(Of TResult)

Type Parameters

TSource

The type of the elements of source.

TResult

The type of the value returned by selector.

Parameters

source

IAsyncEnumerable

A sequence of values to invoke a transform function on.

selector

Func<TSource,Int32,TResult>

A transform function to apply to each element; the second parameter of the function represents the index of the source element.

Returns

An IAsyncEnumerable whose elements are the result of invoking the transform function on each element of source.

Exceptions

Applies to

Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,CancellationToken,ValueTask>)

Source:

Select.cs

Projects each element of a sequence into a new form.

public:
generic <typename TSource, typename TResult>
[System::Runtime::CompilerServices::Extension]
 static System::Collections::Generic::IAsyncEnumerable<TResult> ^ Select(System::Collections::Generic::IAsyncEnumerable<TSource> ^ source, Func<TSource, System::Threading::CancellationToken, System::Threading::Tasks::ValueTask<TResult>> ^ selector);
public static System.Collections.Generic.IAsyncEnumerable<TResult> Select<TSource,TResult>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, Func<TSource,System.Threading.CancellationToken,System.Threading.Tasks.ValueTask<TResult>> selector);
static member Select : System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, System.Threading.CancellationToken, System.Threading.Tasks.ValueTask<'Result>> -> System.Collections.Generic.IAsyncEnumerable<'Result>
<Extension()>
Public Function Select(Of TSource, TResult) (source As IAsyncEnumerable(Of TSource), selector As Func(Of TSource, CancellationToken, ValueTask(Of TResult))) As IAsyncEnumerable(Of TResult)

Type Parameters

TSource

The type of the elements of source.

TResult

The type of the value returned by selector.

Parameters

source

IAsyncEnumerable

A sequence of values to invoke a transform function on.

Returns

An IAsyncEnumerable whose elements are the result of invoking the transform function on each element of source.

Exceptions

Applies to

Select<TSource,TResult>(IAsyncEnumerable, Func<TSource,TResult>)

Source:

Select.cs

Projects each element of a sequence into a new form.

public:
generic <typename TSource, typename TResult>
[System::Runtime::CompilerServices::Extension]
 static System::Collections::Generic::IAsyncEnumerable<TResult> ^ Select(System::Collections::Generic::IAsyncEnumerable<TSource> ^ source, Func<TSource, TResult> ^ selector);
public static System.Collections.Generic.IAsyncEnumerable<TResult> Select<TSource,TResult>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, Func<TSource,TResult> selector);
static member Select : System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, 'Result> -> System.Collections.Generic.IAsyncEnumerable<'Result>
<Extension()>
Public Function Select(Of TSource, TResult) (source As IAsyncEnumerable(Of TSource), selector As Func(Of TSource, TResult)) As IAsyncEnumerable(Of TResult)

Type Parameters

TSource

The type of the elements of source.

TResult

The type of the value returned by selector.

Parameters

source

IAsyncEnumerable

A sequence of values to invoke a transform function on.

selector

Func<TSource,TResult>

A transform function to apply to each element.

Returns

An IAsyncEnumerable whose elements are the result of invoking the transform function on each element of source.

Exceptions

Applies to