org.apache.accumulo.core.file.blockfile.impl
public static class CachableBlockFile.BlockRead extends DataInputStream implements ABlockReader
in
Constructor and Description |
---|
CachableBlockFile.BlockRead(InputStream in,
long size) |
Modifier and Type | Method and Description |
---|---|
<T> T |
getIndex(Class<T> clazz) |
int |
getPosition()
Get the file position.
|
long |
getRawSize()
Size is the size of the bytearray that was read form the cache
|
DataInputStream |
getStream()
It is intended that the caller of this method will close the stream we also only intend that this be called once per BlockRead.
|
boolean |
isIndexable()
An indexable block supports seeking, getting a position, and associating an arbitrary index with the block
|
void |
seek(int position) |
read, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, readUTF, skipBytes
available, close, mark, markSupported, read, reset, skip
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close
readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, skipBytes
public CachableBlockFile.BlockRead(InputStream in, long size)
public long getRawSize()
getRawSize
in interface ABlockReader
public DataInputStream getStream() throws IOException
getStream
in interface ABlockReader
IOException
public boolean isIndexable()
ABlockReader
isIndexable
in interface ABlockReader
public void seek(int position)
seek
in interface ABlockReader
public int getPosition()
ABlockReader
getPosition
in interface ABlockReader
public <T> T getIndex(Class<T> clazz)
getIndex
in interface ABlockReader
Copyright © 2011-2015 The Apache Software Foundation. All Rights Reserved.