Dasync.Collections.IAsyncEnumerableExtensions
Extension methods for IAsyncEnumerable<T> interface
namespace Dasync.Collections
{
public static class IAsyncEnumerableExtensions
{
public static Task<TSource> SingleAsync<TSource>(this IAsyncEnumerable<TSource> source, CancellationToken token = default(CancellationToken));
public static Task<TSource> SingleAsync<TSource>(this IAsyncEnumerable<TSource> source, string noneExceptionMessage, string manyExceptionMessage, CancellationToken token = default(CancellationToken));
public static Task<TSource> SingleAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate, CancellationToken token = default(CancellationToken));
public static async Task<TSource> SingleAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate, string noneExceptionMessage, string manyExceptionMessage, CancellationToken token = default(CancellationToken));
public static Task<TSource> SingleOrDefaultAsync<TSource>(this IAsyncEnumerable<TSource> source, CancellationToken token = default(CancellationToken));
public static async Task<TSource> SingleOrDefaultAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate, CancellationToken token = default(CancellationToken));
public static Task<TSource> FirstAsync<TSource>(this IAsyncEnumerable<TSource> source, CancellationToken token = default(CancellationToken));
public static Task<TSource> FirstAsync<TSource>(this IAsyncEnumerable<TSource> source, string exceptionMessage, CancellationToken token = default(CancellationToken));
public static Task<TSource> FirstAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate, CancellationToken token = default(CancellationToken));
public static async Task<TSource> FirstAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate, string exceptionMessage, CancellationToken token = default(CancellationToken));
public static Task<TSource> FirstOrDefaultAsync<TSource>(this IAsyncEnumerable<TSource> source, CancellationToken token = default(CancellationToken));
public static async Task<TSource> FirstOrDefaultAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate, CancellationToken token = default(CancellationToken));
public static IAsyncEnumerable<TResult> Select<TSource, TResult>(this IAsyncEnumerable<TSource> source, Func<TSource, TResult> selector);
public static IAsyncEnumerable<TResult> Select<TSource, TResult>(this IAsyncEnumerable<TSource> source, Func<TSource, long, TResult> selector);
public static IAsyncEnumerable<TResult> SelectMany<TSource, TResult>(this IAsyncEnumerable<TSource> source, Func<TSource, IAsyncEnumerable<TResult>> selector);
public static IAsyncEnumerable<TResult> SelectMany<TSource, TItem, TResult>(this IAsyncEnumerable<TSource> source, Func<TSource, IAsyncEnumerable<TItem>> collectionSelector, Func<TSource, TItem, TResult> resultSelector);
public static IAsyncEnumerable<TResult> SelectMany<TSource, TResult>(this IAsyncEnumerable<TSource> source, Func<TSource, IEnumerable<TResult>> selector);
public static IAsyncEnumerable<TResult> SelectMany<TSource, TItem, TResult>(this IAsyncEnumerable<TSource> source, Func<TSource, IEnumerable<TItem>> collectionSelector, Func<TSource, TItem, TResult> resultSelector);
public static IAsyncEnumerable<TSource> Take<TSource>(this IAsyncEnumerable<TSource> source, int count);
public static IAsyncEnumerable<TSource> TakeWhile<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate);
public static async Task<List<T>> ToListAsync<T>(this IAsyncEnumerable<T> source, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<T[]> ToArrayAsync<T>(this IAsyncEnumerable<T> source, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<Dictionary<TKey, TSource>> ToDictionaryAsync<TSource, TKey>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<Dictionary<TKey, TSource>> ToDictionaryAsync<TSource, TKey>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, IEqualityComparer<TKey> comparer, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<Dictionary<TKey, TElement>> ToDictionaryAsync<TSource, TKey, TElement>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, Func<TSource, TElement> elementSelector, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<Dictionary<TKey, TElement>> ToDictionaryAsync<TSource, TKey, TElement>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, Func<TSource, TElement> elementSelector, IEqualityComparer<TKey> comparer, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<ILookup<TKey, TSource>> ToLookupAsync<TSource, TKey>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<ILookup<TKey, TSource>> ToLookupAsync<TSource, TKey>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, IEqualityComparer<TKey> comparer, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<ILookup<TKey, TElement>> ToLookupAsync<TSource, TKey, TElement>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, Func<TSource, TElement> elementSelector, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<ILookup<TKey, TElement>> ToLookupAsync<TSource, TKey, TElement>(this IAsyncEnumerable<TSource> source, Func<TSource, TKey> keySelector, Func<TSource, TElement> elementSelector, IEqualityComparer<TKey> comparer, CancellationToken cancellationToken = default(CancellationToken));
public static IAsyncEnumerable<TSource> Skip<TSource>(this IAsyncEnumerable<TSource> source, int count);
public static IAsyncEnumerable<TSource> SkipWhile<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate);
public static IAsyncEnumerable<TSource> Where<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, bool> predicate);
public static IAsyncEnumerable<TSource> Where<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, long, bool> predicate);
public static IAsyncEnumerable<TResult> Cast<TResult>(this IAsyncEnumerable source);
public static IAsyncEnumerable<TResult> OfType<TResult>(this IAsyncEnumerable source);
public static IAsyncEnumerable<TSource> DefaultIfEmpty<TSource>(this IAsyncEnumerable<TSource> source);
public static IAsyncEnumerable<TSource> DefaultIfEmpty<TSource>(this IAsyncEnumerable<TSource> source, TSource defaultValue);
public static IAsyncEnumerable<List<TSource>> Batch<TSource>(this IAsyncEnumerable<TSource> source, int batchSize);
public static IAsyncEnumerable<TStandardCollection> Batch<TSource, TStandardCollection>(this IAsyncEnumerable<TSource> source, int batchSize);
public static IAsyncEnumerable<List<TSource>> Batch<TSource>(this IAsyncEnumerable<TSource> source, long maxBatchWeight, Func<TSource, long> weightSelector);
public static IAsyncEnumerable<TStandardCollection> Batch<TSource, TStandardCollection>(this IAsyncEnumerable<TSource> source, long maxBatchWeight, Func<TSource, long> weightSelector);
public static IAsyncEnumerable<List<TSource>> Batch<TSource>(this IAsyncEnumerable<TSource> source, int maxItemsInBatch, long maxBatchWeight, Func<TSource, long> weightSelector);
public static IAsyncEnumerable<TStandardCollection> Batch<TSource, TStandardCollection>(this IAsyncEnumerable<TSource> source, int maxItemsInBatch, long maxBatchWeight, Func<TSource, long> weightSelector);
public static IAsyncEnumerable<TBatch> Batch<TSource, TBatch>(this IAsyncEnumerable<TSource> source, int? maxItemsInBatch, long maxBatchWeight, Func<TSource, long> weightSelector, Func<int?, TBatch> createBatch, Action<TBatch, TSource> addItem);
public static IAsyncEnumerable<T> UnionAll<T>(this IAsyncEnumerable<T> first, IAsyncEnumerable<T> second);
public static IAsyncEnumerable<T> UnionAll<T>(this IEnumerable<IAsyncEnumerable<T>> collections);
public static IAsyncEnumerable<TSource> Append<TSource>(this IAsyncEnumerable<TSource> source, TSource element);
public static IAsyncEnumerable<TSource> Prepend<TSource>(this IAsyncEnumerable<TSource> source, TSource element);
public static IAsyncEnumerable<TSource> Concat<TSource>(this IAsyncEnumerable<TSource> first, IAsyncEnumerable<TSource> second);
public static IAsyncEnumerable<TSource> Distinct<TSource>(this IAsyncEnumerable<TSource> source);
public static IAsyncEnumerable<TSource> Distinct<TSource>(this IAsyncEnumerable<TSource> source, IEqualityComparer<TSource> comparer);
public static async Task<TSource> AggregateAsync<TSource>(this IAsyncEnumerable<TSource> source, Func<TSource, TSource, TSource> func, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<TAccumulate> AggregateAsync<TSource, TAccumulate>(this IAsyncEnumerable<TSource> source, TAccumulate seed, Func<TAccumulate, TSource, TAccumulate> func, CancellationToken cancellationToken = default(CancellationToken));
public static async Task<TResult> AggregateAsync<TSource, TAccumulate, TResult>(this IAsyncEnumerable<TSource> source, TAccumulate seed, Func<TAccumulate, TSource, TAccumulate> func, Func<TAccumulate, TResult> resultSelector, CancellationToken cancellationToken = default(CancellationToken));
}
}