Udostępnij za pośrednictwem


OnDisposeActionDisposable(Action) Constructor

Definition

Initializes a new instance of an IDisposable object that invokes onDispose on disposal.

public:
 OnDisposeActionDisposable(Action ^ onDispose);
public OnDisposeActionDisposable (Action onDispose);
new Microsoft.VisualStudio.Utilities.OnDisposeActionDisposable : Action -> Microsoft.VisualStudio.Utilities.OnDisposeActionDisposable
Public Sub New (onDispose As Action)

Parameters

onDispose
Action

Action to run on dipose

Exceptions

Thrown if onDispose is null.

Remarks

Catching any exceptions thrown by onDispose is left to the caller.

Applies to