|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.OutputStream
net.noderunner.http.ChunkedOutputStream
public class ChunkedOutputStream
An OutputStream
wrapper that supports the chunked transfer encoding.
ChunkedInputStream
Constructor Summary | |
---|---|
ChunkedOutputStream(OutputStream stream)
Constructs an output stream wrapping the given stream. |
Method Summary | |
---|---|
void |
close()
Closes this output stream, calling doneOutput once before closing. |
void |
doneOutput()
This method differs from close as it merely writes the
final chunk and does not close the underlying output stream. |
void |
flush()
Flushes this output stream. |
String |
toString()
|
void |
write(byte[] b)
Writes the specified byte array. |
void |
write(byte[] b,
int off,
int len)
Writes the specified byte array. |
void |
write(int b)
Writes the specified byte to the output stream. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ChunkedOutputStream(OutputStream stream)
stream
- wrapped output stream. Must be non-null.Method Detail |
---|
public void write(int b) throws IOException
write
in class OutputStream
b
- The byte to be written
IOException
- if an input/output error occurspublic void write(byte[] b) throws IOException
write
in class OutputStream
IOException
public void write(byte[] b, int off, int len) throws IOException
write
in class OutputStream
IOException
public void flush() throws IOException
flush
in interface Flushable
flush
in class OutputStream
IOException
public void doneOutput() throws IOException
close
as it merely writes the
final chunk and does not close the underlying output stream.
This has no effect if this method was called already.
IOException
public void close() throws IOException
doneOutput
once before closing.
close
in interface Closeable
close
in class OutputStream
IOException
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |