public class PosterOutputStream
extends java.io.ByteArrayOutputStream
Constructor and Description |
---|
PosterOutputStream()
Creates a new output stream for POST user data
|
Modifier and Type | Method and Description |
---|---|
void |
close()
After close() has been called, it is no longer possible to write to this stream.
|
void |
reset()
Resets the
count field of this output stream to zero, so that all currently accumulated output in
the ouput stream is discarded. |
void |
write(byte[] b,
int off,
int len)
Writes
len bytes from the specified byte array starting at offset off to this output
stream. |
void |
write(int b)
Writes the specified byte to this output stream.
|
public PosterOutputStream()
public void write(int b)
write
in class java.io.ByteArrayOutputStream
b
- the byte to be written.public void write(byte[] b, int off, int len)
len
bytes from the specified byte array starting at offset off
to this output
stream.write
in class java.io.ByteArrayOutputStream
b
- the data.off
- the start offset in the data.len
- the number of bytes to write.public void reset()
count
field of this output stream to zero, so that all currently accumulated output in
the ouput stream is discarded. The output stream can be used again, reusing the already allocated buffer space.
If the output stream has been closed, then this method has no effect.reset
in class java.io.ByteArrayOutputStream
ByteArrayInputStream.count
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.ByteArrayOutputStream
java.io.IOException