Effective C#: Implement the Standard Dispose Pattern
Learn how to write your own resource-management code when you create types that contain resources other than memory, particularly for disposing of nonmemory resources.