IDisposable.Dispose Method

ServerManager.IDisposable.Dispose Method ()

IIS 7.0
 

Releases the unmanaged resources used by the ServerManager.

Namespace:   Microsoft.Web.Administration
Assembly:  Microsoft.Web.Administration (in Microsoft.Web.Administration.dll)

void IDisposable.Dispose()

Use this method to close or release unmanaged resources held by an instance of the class that implements this interface.

Call M:Microsoft.Web.Administration.ServerManager.System.IDisposable.Dispose when you are finished using the ServerManager. The M:Microsoft.Web.Administration.ServerManager.System.IDisposable.Dispose method leaves the ServerManager in an unusable state. After calling M:Microsoft.Web.Administration.ServerManager.System.IDisposable.Dispose, you must release all references to the ServerManager so the garbage collector can reclaim the memory that the ServerManager was occupying. For more information, see Cleaning Up Unmanaged Resources and Implementing a Dispose Method.

System_CAPS_noteNote

Always call M:Microsoft.Web.Administration.ServerManager.System.IDisposable.Dispose before you release your last reference to the ServerManager. Otherwise, the resources it is using will not be freed until the garbage collector calls the ServerManager object's Finalize method.

Return to top
Show:
© 2016 Microsoft