Module com.github.akurilov.commons
Package com.github.akurilov.commons.io
Class ByteCountOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- com.github.akurilov.commons.io.ByteCountOutputStream
-
- All Implemented Interfaces:
java.io.Closeable,java.io.Flushable,java.lang.AutoCloseable
public class ByteCountOutputStream extends java.io.OutputStream
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.concurrent.atomic.LongAdderbyteCount
-
Constructor Summary
Constructors Constructor Description ByteCountOutputStream()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longbyteCount()voidwrite(byte[] buff)voidwrite(byte[] buff, int off, int len)voidwrite(int b)
-
-
-
Method Detail
-
byteCount
public final long byteCount()
-
write
public void write(int b) throws java.io.IOException- Specified by:
writein classjava.io.OutputStream- Throws:
java.io.IOException
-
write
public void write(byte[] buff, int off, int len) throws java.io.IOException- Overrides:
writein classjava.io.OutputStream- Throws:
java.io.IOException
-
write
public void write(byte[] buff) throws java.io.IOException- Overrides:
writein classjava.io.OutputStream- Throws:
java.io.IOException
-
-