Class AsyncHandlersExtensions
- Namespace
- Executables.Handling
- Assembly
- executables.dll
Extension methods for asynchronous handlers.
public static class AsyncHandlersExtensions
- Inheritance
-
AsyncHandlersExtensions
- Inherited Members
Methods
DisposeOnUnhandledException<T1, T2>(AsyncHandler<T1, T2>)
Disposes the handler automatically when an unhandled exception escapes execution.
[Pure]
public static AsyncHandler<T1, T2> DisposeOnUnhandledException<T1, T2>(this AsyncHandler<T1, T2> handler)
Parameters
handlerAsyncHandler<T1, T2>Source handler.
Returns
- AsyncHandler<T1, T2>
Auto-disposing handler wrapper.
Type Parameters
T1T2
OnDispose<T1, T2>(AsyncHandler<T1, T2>, Action)
Adds disposal callback behavior to a handler.
[Pure]
public static AsyncHandler<T1, T2> OnDispose<T1, T2>(this AsyncHandler<T1, T2> handler, Action dispose)
Parameters
handlerAsyncHandler<T1, T2>Source handler.
disposeActionCallback invoked during disposal.
Returns
- AsyncHandler<T1, T2>
Handler with disposal callback behavior.
Type Parameters
T1T2
Exceptions
- ArgumentNullException
disposeis null.