Releases the unmanaged resources used by the System.IO.StreamWriter and optionally releases the managed resources.
When the disposing parameter is true, this method releases all resources held by any managed objects that this System.IO.StreamWriter references. This method invokes the Dispose method of each referenced object.