Class CountingOutputStream

java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
de.tomatengames.util.io.CountingOutputStream
All Implemented Interfaces:
Closeable, Flushable, AutoCloseable

public class CountingOutputStream extends FilterOutputStream
A FilterOutputStream that counts the amount of bytes written to it. The data is passed to an underlying OutputStream.

Note that this class does not check the parameters passed to the write(...) methods, but the underlying stream may do so.

Closing this stream closes the underlying stream.

Since:
1.2