org.freehep.util.io
Class CountedByteOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
org.freehep.util.io.CountedByteOutputStream
- All Implemented Interfaces:
- Closeable, Flushable
public class CountedByteOutputStream
- extends FilterOutputStream
The CountedByteOutputStream counts the number of bytes written.
- Version:
- $Id: src/main/java/org/freehep/util/io/CountedByteOutputStream.java
96b41b903496 2005/11/21 19:50:18 duns $
- Author:
- Mark Donszelmann
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CountedByteOutputStream
public CountedByteOutputStream(OutputStream out)
- Creates a Counted Bytes output stream from the given stream.
- Parameters:
out - stream to write to
write
public void write(int b)
throws IOException
- Overrides:
write in class FilterOutputStream
- Throws:
IOException
write
public void write(byte[] b)
throws IOException
- Overrides:
write in class FilterOutputStream
- Throws:
IOException
write
public void write(byte[] b,
int offset,
int len)
throws IOException
- Overrides:
write in class FilterOutputStream
- Throws:
IOException
getCount
public int getCount()
- Returns:
- number of bytes written.
Copyright © 2012. All Rights Reserved.