Csharp, Dotnet, Programming, Coding, Software Development.
unmanaged resources public void Dispose() { Dispose(true); GC.SuppressFinalize(this); } protected virtual void Dispose(bool disposing) { if (!_isDisposed) { if (disposing) { // Release managed resources } // Release unmanaged resources _isDisposed = true; } } ~ResourceHolder() { Dispose(false); } }