|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.io.OutputStream
ariba.util.io.StatsOutputStream
public class StatsOutputStream
StatsOutputStream is an OutputStream that keeps track of the number of bytes that have been written.
OutputStream| Field Summary | |
|---|---|
long |
count
Number of bytes written. |
| Constructor Summary | |
|---|---|
StatsOutputStream(OutputStream base)
Creates a StatsOutputStream. |
|
| Method Summary | |
|---|---|
void |
close()
Closes the stream. |
void |
flush()
Flushes the stream. |
void |
write(byte[] b)
Writes an array of bytes. |
void |
write(byte[] b,
int off,
int len)
Writes a sub array of bytes. |
void |
write(int b)
Writes a byte. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public long count
| Constructor Detail |
|---|
public StatsOutputStream(OutputStream base)
base - the OutputStream| Method Detail |
|---|
public void write(int b)
throws IOException
write in class OutputStreamb - the byte
IOException - If an I/O error has occurred.
public void write(byte[] b)
throws IOException
write in class OutputStreamb - the data to be written
IOException - If an I/O error has occurred.
public void write(byte[] b,
int off,
int len)
throws IOException
write in class OutputStreamb - the data to be writtenoff - the start offset in the datalen - the number of bytes that are written
IOException - If an I/O error has occurred.
public void flush()
throws IOException
flush in interface Flushableflush in class OutputStreamIOException - If an I/O error has occurred.
public void close()
throws IOException
close in interface Closeableclose in class OutputStreamIOException - If an I/O error has occurred.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||