CountingOutputStream

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

Constructors

this
deprecated this(OutputStream stream, ulong write_limit)
Undocumented in source.
this
this(InterfaceProxy!OutputStream stream, ulong write_limit, bool dummy)

private

Members

Aliases

write
alias write = OutputStream.write
Undocumented in source.

Functions

finalize
void finalize()
Undocumented in source. Be warned that the author may not have intended to support it.
flush
void flush()
Undocumented in source. Be warned that the author may not have intended to support it.
increment
void increment(ulong bytes)

Manually increments the write counter without actually writing data.

write
size_t write(ubyte[] bytes, IOMode mode)
Undocumented in source. Be warned that the author may not have intended to support it.

Properties

bytesWritten
ulong bytesWritten [@property getter]

Returns the total number of bytes written.

writeLimit
ulong writeLimit [@property getter]
ulong writeLimit [@property setter]

The maximum number of bytes to write

Inherited Members

From OutputStream

write
size_t write(ubyte[] bytes, IOMode mode)
void write(ubyte[] bytes)
void write(char[] bytes)

Writes an array of bytes to the stream.

flush
void flush()

Flushes the stream and makes sure that all data is being written to the output device.

finalize
void finalize()

Flushes and finalizes the stream.

write
deprecated void write(InputStream stream, ulong nbytes)

Pipes an InputStream directly into this OutputStream.

Meta