c# - Do you need to call Flush() on a Stream if you are using the “using” statement? -
i not sure whether need call stream.flush()
if write this:
using (file stream...) using (cryptostream...) using (binarywriter...) { // }
is automatically flushed? when using
statement flush stream , when doesn’t (if can happen)?
as leave using block’s scope, stream closed , disposed. close() calls flush(), should not need call manually.
Comments
Post a Comment