Struct DisposableAction
Disposable type that runs a specified action on dispose
Namespace: Llvm.NET.Interop
Assembly: Llvm.NET.dll
Syntax
public struct DisposableAction : IDisposable, IEquatable<DisposableAction>
Remarks
This is used in RAII pattern style code instead of try/finally. It is most valuable when the scope extends beyond a single function where a try/finally simply won't work.
Constructors
DisposableAction(Action) | Initializes a new instance of the DisposableAction struct. |
Properties
Nop | Gets a Default disposable action that does nothing |
Methods
Dispose() | Runs the action provided in the constructor (DisposableAction(Action) |
Equals(DisposableAction) | |
Equals(Object) | |
GetHashCode() |
Operators
Equality(DisposableAction, DisposableAction) | Compares two actions for equality |
Inequality(DisposableAction, DisposableAction) | Compares two actions for inequality |