Easy Pattern to implement IDisposable

Here is my C# implementation for an easy way to implement the IDisposable pattern in your classes. Just override DisposeManaged() and/or DisposeNative() when needed. The embedded code shown below is pulled directly from my GitHub gist here.If any formatting is ‘off’ or links don’t work, contact the WordPress.com complaint department.