Class AsyncDisposable
Base class that simplifies the implementation of IAsyncDisposable and IDisposable interfaces.
Inherited Members
Namespace: TheXDS.MCART.Types.Base
Assembly: MCART.dll
Syntax
public abstract class AsyncDisposable : Disposable, IDisposableEx, IDisposable, IAsyncDisposable
Remarks
If the class to implement does not contain asynchronous disposal actions, use the Disposable class as the base class.
Methods
| Edit this page View SourceDisposeAsync()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources asynchronously.
Declaration
public ValueTask DisposeAsync()
Returns
Type | Description |
---|---|
ValueTask | A task that represents the asynchronous dispose operation. |
OnDisposeAsync()
Performs asynchronous cleanup operations on disposable managed objects for this instance.
Declaration
protected abstract ValueTask OnDisposeAsync()
Returns
Type | Description |
---|---|
ValueTask | A ValueTask that allows waiting for the asynchronous operation. |