public class CountingOutputStream extends FilterOutputStream
out| Constructor and Description | 
|---|
| CountingOutputStream(OutputStream out) | 
| Modifier and Type | Method and Description | 
|---|---|
| protected void | count(long written)Increments the counter of already written bytes. | 
| long | getBytesWritten()Returns the current number of bytes written to this stream. | 
| void | write(byte[] b) | 
| void | write(byte[] b,
     int off,
     int len) | 
| void | write(int b) | 
close, flushpublic CountingOutputStream(OutputStream out)
public void write(int b) throws IOException
write in class FilterOutputStreamIOExceptionpublic void write(byte[] b) throws IOException
write in class FilterOutputStreamIOExceptionpublic void write(byte[] b, int off, int len) throws IOException
write in class FilterOutputStreamIOExceptionprotected void count(long written)
written - the number of bytes writtenpublic long getBytesWritten()
Copyright © 2018 The Apache Software Foundation. All rights reserved.