com.sibvisions.util.io
Class ByteCountOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
com.sibvisions.util.io.ByteCountOutputStream
- All Implemented Interfaces:
- Closeable, Flushable
public class ByteCountOutputStream
- extends FilterOutputStream
The ByteCountOutputStream is an OutputStream wrapper which counts written bytes.
|
Method Summary |
long |
getWrittenBytes()
Gets the number of already written bytes. |
void |
write(int pByte)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ByteCountOutputStream
public ByteCountOutputStream(OutputStream pStream)
- Creates a new instance of
ByteCountOutputStream.
- Parameters:
pStream - the wrapped stream
write
public void write(int pByte)
throws IOException
-
- Overrides:
write in class FilterOutputStream
- Throws:
IOException
getWrittenBytes
public long getWrittenBytes()
- Gets the number of already written bytes.
- Returns:
- the number of bytes
Copyright © 2009 SIB Visions GmbH. All Rights Reserved.