Class Disposable
- Namespace
- Cuemon
- Assembly
- Cuemon.Core.dll
Provides a mechanism for releasing both managed and unmanaged resources with focus on the former.
public abstract class Disposable : IDisposable
- Inheritance
-
Disposable
- Implements
- Derived
Properties
Disposed
Gets a value indicating whether this Disposable object is disposed.
public bool Disposed { get; }
Property Value
- Boolean
true
if this Disposable object is disposed; otherwise,false
.
Methods
Dispose()
Releases all resources used by the Disposable object.
public void Dispose()
Dispose(Boolean)
Releases the unmanaged resources used by the Disposable object and optionally releases the managed resources.
protected void Dispose(bool disposing)
Parameters
disposing
Booleantrue
to release both managed and unmanaged resources;false
to release only unmanaged resources.
OnDisposeManagedResources()
Called when this object is being disposed by either Dispose() or Dispose(Boolean) having disposing
set to true
and Disposed is false
.
protected abstract void OnDisposeManagedResources()
OnDisposeUnmanagedResources()
Called when this object is being disposed by either Dispose() or Dispose(Boolean) and Disposed is false
.
protected virtual void OnDisposeUnmanagedResources()