|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.hadoop.hbase.io.hfile.bucket.FileIOEngine
@InterfaceAudience.Private public class FileIOEngine
IO engine that stores data to a file on the local file system.
| Constructor Summary | |
|---|---|
FileIOEngine(String filePath,
long fileSize)
|
|
| Method Summary | |
|---|---|
boolean |
isPersistent()
File IO engine is always able to support persistent storage for the cache |
void |
read(ByteBuffer dstBuffer,
long offset)
Transfers data from file to the given byte buffer |
void |
shutdown()
Close the file |
void |
sync()
Sync the data to file after writing |
void |
write(ByteBuffer srcBuffer,
long offset)
Transfers data from the given byte buffer to file |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FileIOEngine(String filePath,
long fileSize)
throws IOException
IOException| Method Detail |
|---|
public boolean isPersistent()
isPersistent in interface IOEngine
public void read(ByteBuffer dstBuffer,
long offset)
throws IOException
read in interface IOEnginedstBuffer - the given byte buffer into which bytes are to be writtenoffset - The offset in the file where the first byte to be read
IOException
public void write(ByteBuffer srcBuffer,
long offset)
throws IOException
write in interface IOEnginesrcBuffer - the given byte buffer from which bytes are to be readoffset - The offset in the file where the first byte to be written
IOException
public void sync()
throws IOException
sync in interface IOEngineIOExceptionpublic void shutdown()
shutdown in interface IOEngine
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||