Interface ABlockReader
-
- All Superinterfaces:
DataInput
- All Known Implementing Classes:
CachableBlockFile.BlockRead
,CachableBlockFile.CachedBlockRead
public interface ABlockReader extends DataInput
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
close()
byte[]
getBuffer()
<T> T
getIndex(Class<T> clazz)
int
getPosition()
Get the file position.DataInputStream
getStream()
boolean
isIndexable()
An indexable block supports seeking, getting a position, and associating an arbitrary index with the blockvoid
seek(int position)
-
Methods inherited from interface java.io.DataInput
readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, skipBytes
-
-
-
-
Method Detail
-
getStream
DataInputStream getStream() throws IOException
- Throws:
IOException
-
close
void close() throws IOException
- Throws:
IOException
-
isIndexable
boolean isIndexable()
An indexable block supports seeking, getting a position, and associating an arbitrary index with the block- Returns:
- true, if the block is indexable; otherwise false.
-
seek
void seek(int position)
-
getPosition
int getPosition()
Get the file position.- Returns:
- the file position.
-
getIndex
<T> T getIndex(Class<T> clazz)
-
getBuffer
byte[] getBuffer()
-
-