public class ByteBuffer extends Buffer
Constructor and Description |
---|
ByteBuffer()
Creates an instance of a Buffer.
|
ByteBuffer(byte[] bytes,
int offset,
boolean forRead)
Creates an instance of a Buffer.
|
Modifier and Type | Method and Description |
---|---|
byte[] |
getBytes()
Gets the buffer.
|
java.io.InputStream |
getInputStream()
Gets an InputStream to read buffer information.
|
java.io.OutputStream |
getOutputStream()
Gets an OutputStream to write buffer information.
|
long |
getSize()
Gets the buffer size.
|
void |
setBytes(byte[] bytes)
Sets the buffer.
|
getOffset, isReadBuffer, setOffset, setReadFlag, toString
public ByteBuffer(byte[] bytes, int offset, boolean forRead)
public ByteBuffer()
public byte[] getBytes()
public void setBytes(byte[] bytes)
bytes
- The new buffer.public long getSize()
public java.io.InputStream getInputStream() throws java.io.IOException
getInputStream
in class Buffer
java.io.IOException
public java.io.OutputStream getOutputStream() throws java.io.IOException
getOutputStream
in class Buffer
java.io.IOException