Create AsyncExtensions.cs

pull/1/head
unknown 4 years ago
parent b69ee03bbf
commit 6e8d6bfac6

@ -0,0 +1,20 @@
using System.Collections.Generic;
using System.Threading.Tasks;
namespace ZeroLevel.Services
{
public static class AsyncExtensions
{
/*public static async IAsyncEnumerable<T> ParallelEnumerateAsync<T>(this IEnumerable<Task<T>> tasks)
{
var remaining = new List<Task<T>>(tasks);
while (remaining.Count != 0)
{
var task = await Task.WhenAny(remaining);
remaining.Remove(task);
yield return (await task);
}
}*/
}
}
Loading…
Cancel
Save

Powered by TurnKey Linux.