Implement a Dispose method

Implementing the Dispose method is primarily for releasing unmanaged resources. When working with instance members that are IDisposable implementations, it’s common to cascade Dispose calls. Dispose() and Dispose(bool) The IDisposable interface requires the implementation of a single parameterless method, Dispose. Also, any non-sealed class should have an additional Dispose(bool) overload method to be implemented: A public non-virtual (NonInheritable in Visual Basic) IDisposable.Dispose implementation that has no parameters. A protected virtual (Overridable in Visual Basic) Dispose method …

Design a site like this with WordPress.com
Get started