Top "Iasyncenumerable" questions

IAsyncEnumerable<T> exposes an IAsyncEnumerator<T> enumerator that provides asynchronous iteration over values of type T

Is it possible to "await yield return DoSomethingAsync()"

Are regular iterator blocks (i.e. "yield return") incompatible with "async" and "await"? This gives a good idea of what …

c# async-await c#-5.0 iasyncenumerable
Convert IAsyncEnumerable to List

So in C#8 we got the addition of the IAsyncEnumerable interface. If we have a normal IEnumerable we can make …

c# linq ienumerable c#-8.0 iasyncenumerable
Converting IQueryable to implement IAsyncEnumerable

I have a query in a method: private readonly IEntityReader<Customer> _reader; public async Task<IEnumerable<…

c# unit-testing entity-framework-core moq iasyncenumerable
How do you mock an IAsyncEnumerable?

I want to unit test a method that calls another method of a service returning an IAsyncEnumerable<T>. …

c# unit-testing asp.net-core iasyncenumerable
IAsyncEnumerable not working in C# 8.0 preview

I was playing around with C# 8.0 preview and can't get IAsyncEnumerable to work. I tried the following public static async …

c# c#-8.0 iasyncenumerable
Linq methods for IAsyncEnumerable

When working with an IEnumerable<T> there are the build-in extension methods from the System.Linq namespace such …

c# c#-8.0 iasyncenumerable
Difference between "ToListAsync()" and "AsAsyncEnumerable().ToList()"

Function need to return Task<List<Record>> Following both options are returning Task<List<…

c# async-await entity-framework-core tolist iasyncenumerable
How to use C#8 IAsyncEnumerable<T> to async-enumerate tasks run in parallel

If possible I want to create an async-enumerator for tasks launched in parallel. So first to complete is first element …

c# asynchronous async-await task-parallel-library iasyncenumerable