Thursday, December 27, 2007

Why do we need to call CG.SupressFinalize?

public static void SuppressFinalize(object obj);

This method removes obj from the set of objects that require finalization.
Objects that implement the IDisposable interface can call this method from the IDisposable.Dispose method to prevent the garbage collector from calling Object.Finalize on an object that does not require it.

No comments: