AsyncEnumerable.OrderByDescending Metod

Definition

Överlagringar

OrderByDescending<TSource,TKey>(IAsyncEnumerable<TSource>, Func<TSource,CancellationToken,ValueTask<TKey>>, IComparer<TKey>)

Källa:
OrderBy.cs
Källa:
OrderBy.cs
Källa:
OrderBy.cs

Sorterar elementen i en sekvens i fallande ordning.

public static System.Linq.IOrderedAsyncEnumerable<TSource> OrderByDescending<TSource,TKey>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, Func<TSource,System.Threading.CancellationToken,System.Threading.Tasks.ValueTask<TKey>> keySelector, System.Collections.Generic.IComparer<TKey>? comparer = default);
static member OrderByDescending : System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, System.Threading.CancellationToken, System.Threading.Tasks.ValueTask<'Key>> * System.Collections.Generic.IComparer<'Key> -> System.Linq.IOrderedAsyncEnumerable<'Source>
<Extension()>
Public Function OrderByDescending(Of TSource, TKey) (source As IAsyncEnumerable(Of TSource), keySelector As Func(Of TSource, CancellationToken, ValueTask(Of TKey)), Optional comparer As IComparer(Of TKey) = Nothing) As IOrderedAsyncEnumerable(Of TSource)

Typparametrar

TSource

Typen av element sourcei .

TKey

Typ av nyckel som returneras av keySelector.

Parametrar

source
IAsyncEnumerable<TSource>

En sekvens med värden i ordning.

keySelector
Func<TSource,CancellationToken,ValueTask<TKey>>

En funktion för att extrahera en nyckel från ett element.

comparer
IComparer<TKey>

En IComparer<T> för att jämföra nycklar.

Returer

En IAsyncEnumerable<T> vars element sorteras i fallande ordning enligt en nyckel.

Undantag

keySelector är null.

Gäller för

OrderByDescending<TSource,TKey>(IAsyncEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

Källa:
OrderBy.cs
Källa:
OrderBy.cs
Källa:
OrderBy.cs

Sorterar elementen i en sekvens i fallande ordning.

public static System.Linq.IOrderedAsyncEnumerable<TSource> OrderByDescending<TSource,TKey>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, Func<TSource,TKey> keySelector, System.Collections.Generic.IComparer<TKey>? comparer = default);
static member OrderByDescending : System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, 'Key> * System.Collections.Generic.IComparer<'Key> -> System.Linq.IOrderedAsyncEnumerable<'Source>
<Extension()>
Public Function OrderByDescending(Of TSource, TKey) (source As IAsyncEnumerable(Of TSource), keySelector As Func(Of TSource, TKey), Optional comparer As IComparer(Of TKey) = Nothing) As IOrderedAsyncEnumerable(Of TSource)

Typparametrar

TSource

Typen av element sourcei .

TKey

Typ av nyckel som returneras av keySelector.

Parametrar

source
IAsyncEnumerable<TSource>

En sekvens med värden i ordning.

keySelector
Func<TSource,TKey>

En funktion för att extrahera en nyckel från ett element.

comparer
IComparer<TKey>

En IComparer<T> för att jämföra nycklar.

Returer

En IAsyncEnumerable<T> vars element sorteras i fallande ordning enligt en nyckel.

Undantag

keySelector är null.

Gäller för