26import java.nio.ByteBuffer;
120 int read(
byte out[],
final int offset,
final int length);
153 int peek(
byte out[],
final int offset,
final int length,
final long peek_offset);
Abstract byte input stream object.
int peek(byte out[], final int offset, final int length, final long peek_offset)
Read from the source but do not modify the internal offset.
long content_size()
Returns the content_size if known.
boolean available(long n)
Return whether n bytes are available in the input stream, if has_content_size() or using an asynchron...
int read(byte out[], final int offset, final int length)
Read from the source.
int read(ByteBuffer out)
Read from the source.
long discard_next(long N)
Discard the next N bytes of the data.
void close()
Close the stream if supported by the underlying mechanism and dispose the native instance.
boolean has_content_size()
Returns true if implementation is aware of content_size(), otherwise false.
boolean is_open()
Checks if the stream has an associated file.
String id()
return the id of this data source
void closeStream()
Close the stream if supported by the underlying mechanism.
long tellg()
Returns the input position indicator, similar to std::basic_istream.
Supporting std::basic_ios's iostate functionality for all ByteInStream implementations.