Closeable, Flushable, AutoCloseablepublic class FinishableWrapperOutputStream extends FinishableOutputStream
| Modifier and Type | Field | Description |
|---|---|---|
protected OutputStream |
out |
The
OutputStream that has been
wrapped into a FinishableWrapperOutputStream. |
| Constructor | Description |
|---|---|
FinishableWrapperOutputStream(OutputStream out) |
Creates a new output stream which support finishing.
|
| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
Calls
out.close(). |
void |
flush() |
Calls
out.flush(). |
void |
write(byte[] buf) |
Calls
out.write(buf). |
void |
write(byte[] buf,
int off,
int len) |
Calls
out.write(buf, off, len). |
void |
write(int b) |
Calls
out.write(b). |
finishprotected OutputStream out
OutputStream that has been
wrapped into a FinishableWrapperOutputStream.public FinishableWrapperOutputStream(OutputStream out)
finish() method will do nothing.public void write(int b)
throws IOException
out.write(b).write in class OutputStreamIOExceptionpublic void write(byte[] buf)
throws IOException
out.write(buf).write in class OutputStreamIOExceptionpublic void write(byte[] buf,
int off,
int len)
throws IOException
out.write(buf, off, len).write in class OutputStreamIOExceptionpublic void flush()
throws IOException
out.flush().flush in interface Flushableflush in class OutputStreamIOExceptionpublic void close()
throws IOException
out.close().close in interface AutoCloseableclose in interface Closeableclose in class OutputStreamIOException