public class ByteBuffer
extends java.io.OutputStream
ByteArrayOutputStream
re-implementation.
This version allows one to read while writing is in progress.
Constructor and Description |
---|
ByteBuffer() |
Modifier and Type | Method and Description |
---|---|
long |
length() |
java.io.InputStream |
newInputStream()
Creates an
InputStream that reads from the underlying buffer. |
java.lang.String |
toString() |
void |
write(byte[] b,
int off,
int len) |
void |
write(int b) |
void |
writeTo(java.io.OutputStream os)
Writes the contents of this buffer to another OutputStream.
|
public void write(byte[] b, int off, int len) throws java.io.IOException
write
in class java.io.OutputStream
java.io.IOException
public void write(int b) throws java.io.IOException
write
in class java.io.OutputStream
java.io.IOException
public long length()
public java.lang.String toString()
toString
in class java.lang.Object
public void writeTo(java.io.OutputStream os) throws java.io.IOException
java.io.IOException
public java.io.InputStream newInputStream()
InputStream
that reads from the underlying buffer.Copyright © 2013. All Rights Reserved.