public final class DataByteArrayChannel extends Object implements DataBuffer
| Constructor and Description |
|---|
DataByteArrayChannel(byte[] byteArray,
long offset,
long length) |
| Modifier and Type | Method and Description |
|---|---|
long |
getLength()
Returns the length of the data.
|
Object |
getNettyOutput()
Returns an object for writing to a netty channel.
|
ByteBuffer |
getReadOnlyByteBuffer()
Returns a
ByteBuffer for read-only access to the data. |
void |
release()
Release the underlying buffer of this DataBuffer if no longer needed.
|
public DataByteArrayChannel(byte[] byteArray,
long offset,
long length)
byteArray - The array representing the data.offset - The offset into the byteArray.length - The length of the data.public Object getNettyOutput()
DataBuffergetNettyOutput in interface DataBufferpublic long getLength()
DataBuffergetLength in interface DataBufferpublic ByteBuffer getReadOnlyByteBuffer()
DataBufferByteBuffer for read-only access to the data.getReadOnlyByteBuffer in interface DataBufferpublic void release()
DataBufferrelease in interface DataBufferCopyright © 2015. All Rights Reserved.