Class CountingOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
org.apache.commons.compress.utils.CountingOutputStream
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
Deprecated.
Stream that tracks the number of bytes read.
- Since:
- 1.3
- This class is not thread-safe
-
Field Summary
Fields inherited from class java.io.FilterOutputStream
out
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
count
(long written) Deprecated.Increments the counter of already written bytes.long
Deprecated.Returns the current number of bytes written to this stream.void
write
(byte[] b) Deprecated.void
write
(byte[] b, int off, int len) Deprecated.void
write
(int b) Deprecated.Methods inherited from class java.io.FilterOutputStream
close, flush
-
Constructor Details
-
CountingOutputStream
Deprecated.
-
-
Method Details
-
count
Deprecated.Increments the counter of already written bytes. Doesn't increment if the EOF has been hit (written == -1)- Parameters:
written
- the number of bytes written
-
getBytesWritten
Deprecated.Returns the current number of bytes written to this stream.- Returns:
- the number of written bytes
-
write
Deprecated.- Overrides:
write
in classFilterOutputStream
- Throws:
IOException
-
write
Deprecated.- Overrides:
write
in classFilterOutputStream
- Throws:
IOException
-
write
Deprecated.- Overrides:
write
in classFilterOutputStream
- Throws:
IOException
-
CountingOutputStream
.