You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

29 lines
686 B

using System;
namespace Microsoft.Win32.Security
{
/// <summary>
/// Abstract base class for any disposable object.
/// Handle the finalizer and the call the Gc.SuppressFinalize.
/// Derived classes must implement "Dispose(bool disposing)".
/// </summary>
public abstract class DisposableObject : IDisposable
{
#region IDisposable Members
public void Dispose()
{
Dispose(true);
GC.SuppressFinalize(this);
}
#endregion
~DisposableObject()
{
Dispose(false);
}
protected abstract void Dispose(bool disposing);
}
}