public class DirectBufferInputStream extends InputStream
InputStream
that wraps a DirectBuffer
.Constructor and Description |
---|
DirectBufferInputStream()
Default constructor.
|
DirectBufferInputStream(DirectBuffer buffer)
Wrap given
DirectBuffer . |
DirectBufferInputStream(DirectBuffer buffer,
int offset,
int length)
Wrap given
DirectBuffer . |
Modifier and Type | Method and Description |
---|---|
int |
available() |
DirectBuffer |
buffer()
The underlying buffer being wrapped.
|
void |
close() |
int |
length()
The length of the underlying buffer to use
|
boolean |
markSupported() |
int |
offset()
The offset within the underlying buffer at which to start.
|
int |
read() |
int |
read(byte[] dstBytes,
int dstOffset,
int length) |
long |
skip(long n) |
void |
wrap(DirectBuffer buffer)
Wrap given
DirectBuffer . |
void |
wrap(DirectBuffer buffer,
int offset,
int length)
Wrap given
DirectBuffer . |
mark, read, reset
public DirectBufferInputStream()
public DirectBufferInputStream(DirectBuffer buffer)
DirectBuffer
.buffer
- to wrap.public DirectBufferInputStream(DirectBuffer buffer, int offset, int length)
DirectBuffer
.buffer
- to wrap.offset
- into the buffer.length
- in bytes.public void wrap(DirectBuffer buffer)
DirectBuffer
.buffer
- to wrap.public void wrap(DirectBuffer buffer, int offset, int length)
DirectBuffer
.buffer
- to wrap.offset
- into the buffer.length
- in bytes.public int offset()
public int length()
public DirectBuffer buffer()
public boolean markSupported()
markSupported
in class InputStream
public int available()
available
in class InputStream
public long skip(long n)
skip
in class InputStream
public int read()
read
in class InputStream
public int read(byte[] dstBytes, int dstOffset, int length)
read
in class InputStream
public void close()
close
in interface Closeable
close
in interface AutoCloseable
close
in class InputStream
Copyright © 2014-2021 Real Logic Limited. All Rights Reserved.