|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.io.OutputStream
java.io.FilterOutputStream
public class FilterOutputStream
FilteredOutputStream is a class which takes an output stream and filters the output in some way. The filtered view may be a buffered output or one which compresses data before actually writing the bytes. FilterOutputStreams are meant for byte streams.
FilterInputStream| Field Summary | |
|---|---|
protected OutputStream |
out
The target OutputStream for this filter. |
| Constructor Summary | |
|---|---|
FilterOutputStream(OutputStream out)
Constructs a new FilterOutputStream on the OutputStream out. |
|
| Method Summary | |
|---|---|
void |
close()
Close this FilterOutputStream. |
void |
flush()
Flush this FilterOutputStream to ensure all pending data is sent out to the target OutputStream. |
void |
write(byte[] buffer)
Writes the entire contents of the byte array buffer to
this FilterOutputStream. |
void |
write(byte[] buffer,
int offset,
int count)
Writes count bytes from the byte array
buffer starting at offset to this
FilterOutputStream. |
void |
write(int oneByte)
Writes the specified byte oneByte to this
FilterOutputStream. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected OutputStream out
| Constructor Detail |
|---|
public FilterOutputStream(OutputStream out)
out.
All writes are now filtered through this stream.
out - the target OutputStream to filter writes on.| Method Detail |
|---|
public void close()
throws IOException
close in interface Closeableclose in class OutputStreamIOException - If an error occurs attempting to close this stream.
public void flush()
throws IOException
flush in interface Flushableflush in class OutputStreamIOException - If an error occurs attempting to flush this
FilterOutputStream.
public void write(byte[] buffer)
throws IOException
buffer to
this FilterOutputStream. This implementation writes the
buffer to the target stream.
write in class OutputStreambuffer - the buffer to be written
IOException - If an error occurs attempting to write to this
FilterOutputStream.
public void write(byte[] buffer,
int offset,
int count)
throws IOException
count bytes from the byte array
buffer starting at offset to this
FilterOutputStream. This implementation writes the buffer
to the target OutputStream.
write in class OutputStreambuffer - the buffer to be writtenoffset - offset in buffer to get bytescount - number of bytes in buffer to write
IOException - If an error occurs attempting to write to this
FilterOutputStream.
IndexOutOfBoundsException - If offset or count are outside of bounds.
public void write(int oneByte)
throws IOException
oneByte to this
FilterOutputStream. Only the low order byte of oneByte is
written. This implementation writes the byte to the target OutputStream.
write in class OutputStreamoneByte - the byte to be written
IOException - If an error occurs attempting to write to this
FilterOutputStream.
|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||