AsyncEx is a library designed to assist with programming when using the async
and await
keywords.
Most people just need AsyncLock, but AsyncEx also includes AsyncManualResetEvent, AsyncAutoResetEvent, AsyncConditionVariable, AsyncMonitor, AsyncSemaphore, AsyncCountdownEvent, and AsyncReaderWriterLock.
AsyncProducerConsumerQueue is an async
-ready producer/consumer queue that works on all platforms.
AsyncCollection is an async
-compatible wrapper around IProducerConsumerCollection
, in the same way that BlockingCollection is a blocking wrapper around IProducerConsumerCollection
.
The AsyncLazy class provides support for asynchronous lazy initialization.
The AsyncContext class and the related AsyncContextThread
class provide contexts for asynchronous operations for situations where such a context is lacking (i.e., Console applications and Win32 services).
The ApmAsyncFactory classes interoperate between Task-based Asynchronous Programming (async
) and the Asynchronous Programming Model (IAsyncResult
).
You can use OrderByCompletion to order tasks by when they complete.
TaskConstants provides static constant Task<TResult>
values.
TaskCompletionSourceExtensions has several extension methods for TaskCompletionSource<T>
, including propagating results from a completed Task
.
TaskFactoryExtensions adds Run
overloads to task factories.
ExceptionHelpers.PrepareForRethrow will preserve the stack trace when rethrowing any exception.