| Modifier and Type | Field and Description |
|---|---|
protected static Logger |
LOG |
static int |
seekcount |
static long |
totalReadBytes |
static int |
totalReads |
static long |
totalWriteBytes |
static int |
totalWrites |
| Constructor and Description |
|---|
RandomAccessDataFile(java.io.File file) |
RandomAccessDataFile(java.io.File file,
PagePool pool) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
dispose() |
void |
flushSomePages(int maxPagesToFlush) |
void |
force()
Flushes dirty pages to underlying buffers
|
void |
get(long addr,
byte[] bytes,
int off,
int len) |
byte |
getByte(long addr) |
java.io.File |
getFile() |
int |
getInt(long addr) |
long |
getLong(long addr) |
java.lang.String |
getUTF(long addr) |
int |
hashCode() |
boolean |
isDirty() |
boolean |
isDisposed() |
long |
length() |
long |
physicalLength() |
void |
put(long addr,
byte[] bytes,
int off,
int len) |
void |
putByte(long addr,
byte b) |
void |
putInt(long addr,
int value) |
void |
putLong(long addr,
long value) |
void |
putUTF(long addr,
java.lang.String value) |
void |
sync()
Flushes dirty pages to buffers and saves them to disk
|
java.lang.String |
toString() |
protected static final Logger LOG
public static int totalReads
public static long totalReadBytes
public static int seekcount
public static int totalWrites
public static long totalWriteBytes
public RandomAccessDataFile(java.io.File file)
throws java.io.IOException
java.io.IOExceptionpublic RandomAccessDataFile(java.io.File file,
PagePool pool)
throws java.io.IOException
java.io.IOExceptionpublic java.io.File getFile()
public void put(long addr,
byte[] bytes,
int off,
int len)
public void get(long addr,
byte[] bytes,
int off,
int len)
public void putInt(long addr,
int value)
public int getInt(long addr)
public void putLong(long addr,
long value)
public void putByte(long addr,
byte b)
public byte getByte(long addr)
public long getLong(long addr)
public java.lang.String getUTF(long addr)
public void putUTF(long addr,
java.lang.String value)
public long length()
public long physicalLength()
public void dispose()
public void close()
close in interface java.io.Closeableclose in interface java.lang.AutoCloseablepublic void force()
public void sync()
public void flushSomePages(int maxPagesToFlush)
public boolean isDisposed()
public int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object