public abstract class FSDataInputStream extends DataInputStream
| Constructor and Description |
|---|
FSDataInputStream(InputStream in) |
| Modifier and Type | Method and Description |
|---|---|
abstract long |
getPos()
Get the current position in the input stream.
|
abstract int |
read(long position,
byte[] buffer,
int offset,
int length)
Read bytes from the given position in the stream to the given buffer.
|
void |
readFully(long position,
byte[] buffer)
|
abstract void |
readFully(long position,
byte[] buffer,
int offset,
int length)
Read bytes from the given position in the stream to the given buffer.
|
abstract void |
seek(long desired)
Seek to the given offset.
|
read, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, readUTF, skipBytesavailable, close, mark, markSupported, read, reset, skippublic FSDataInputStream(InputStream in) throws IOException
IOExceptionpublic abstract void seek(long desired)
throws IOException
desired - offset to seek toIOExceptionpublic abstract long getPos()
throws IOException
IOExceptionpublic abstract int read(long position,
byte[] buffer,
int offset,
int length)
throws IOException
position - position in the input stream to seekbuffer - buffer into which data is readoffset - offset into the buffer in which data is writtenlength - maximum number of bytes to read-1
if there is no more data because the end of the stream has been
reachedIOExceptionpublic abstract void readFully(long position,
byte[] buffer,
int offset,
int length)
throws IOException
length bytes have been read.position - position in the input stream to seekbuffer - buffer into which data is readoffset - offset into the buffer in which data is writtenlength - the number of bytes to readEOFException - If the end of stream is reached while reading.
If an exception is thrown an undetermined number
of bytes in the buffer may have been written.IOExceptionpublic void readFully(long position,
byte[] buffer)
throws IOException
IOExceptionCopyright © 2021 Alibaba Cloud Computing. All rights reserved.