Closeable, AutoCloseablepublic class ByteArraySeekableStream extends SeekableStream
mark| Constructor | Description |
|---|---|
ByteArraySeekableStream(byte[] bytes) |
| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
|
boolean |
eof() |
|
String |
getSource() |
|
long |
length() |
|
long |
position() |
|
int |
read() |
|
int |
read(byte[] b,
int off,
int len) |
|
void |
seek(long position) |
Seeks the stream to the provided position.
|
read, readAllBytes, readNBytes, skip, transferToclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitavailable, mark, markSupported, readFully, resetpublic long length()
length in class SeekableStreampublic long position()
throws IOException
position in class SeekableStreamIOExceptionpublic void seek(long position)
throws IOException
SeekableStreamseek in class SeekableStreamIOExceptionpublic int read()
throws IOException
read in class InputStreamIOExceptionpublic int read(byte[] b,
int off,
int len)
throws IOException
read in class SeekableStreamIOExceptionpublic void close()
throws IOException
close in interface AutoCloseableclose in interface Closeableclose in class SeekableStreamIOExceptionpublic boolean eof()
throws IOException
eof in class SeekableStreamtrue if the stream is already consumed; false otherwise.IOExceptionpublic String getSource()
getSource in class SeekableStream