vibe.d beta banner
get vibe.d
0.9.0

Asynchronous I/O that doesn’t get in your way, written in D

Class CountingOutputStream

Wraps an existing output stream, counting the bytes that are written.

class CountingOutputStream
  : OutputStream ;

Constructors

NameDescription
this (stream, write_limit)

Properties

NameTypeDescription
bytesWritten[get] ulongReturns the total number of bytes written.
writeLimit[get, set] ulongThe maximum number of bytes to write

Methods

NameDescription
finalize () Flushes and finalizes the stream.
flush () Flushes the stream and makes sure that all data is being written to the output device.
increment (bytes) Manually increments the write counter without actually writing data.
write (bytes, mode) Writes an array of bytes to the stream.
write (bytes) Writes an array of bytes to the stream.

Aliases

NameDescription
write
Authors

Sönke Ludwig

Copyright

© 2012 Sönke Ludwig

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.