Mono Class Library: System.IO.StreamWriter Overview | Members

System.IO.StreamWriter.AutoFlush Property

Gets or sets a bool value indicating whether the current System.IO.StreamWriter will flush its buffer to the underlying stream after every call to StreamWriter.Write(char). [Edit]

public virtual bool AutoFlush { set; get; }

Value

true to force System.IO.StreamWriter to flush its buffer; otherwise, false. [Edit]

Remarks

The System.IO.StreamWriter will do a limited amount of buffering, both internally and potentially in the encoder from the encoding you passed in. If StreamWriter.AutoFlush is set to false, the data will be flushed into the underlying stream only when the buffer is full, or when StreamWriter.Dispose(bool)(true) or StreamWriter.Close is called.

Setting StreamWriter.AutoFlush to true forces System.IO.StreamWriter to flush the buffered data out of the encoder and call StreamWriter.Flush on the stream every time StreamWriter.Write(char) is called.

Operation
As described above.

[Edit]

Requirements

Namespace: System.IO
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0