|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xerial.db.storage.DiskFile
public class DiskFile
The DiskFile wraps read/write accesses to files
| Constructor Summary | |
|---|---|
DiskFile(String filePath)
|
|
DiskFile(String filePath,
String mode)
|
|
| Method Summary | |
|---|---|
void |
close()
Closes the file. |
void |
read(byte[] buffer,
int offset,
int byteSize)
Reads data from the file, and writes the read data to the specified buffer |
void |
seek(long filePos)
Sets the file pointer offset, measured from the beginning of the file, at which the next read/write request occurs. |
void |
write(byte[] buffer,
int offset,
int byteSize)
Writes the given data into the file |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DiskFile(String filePath)
throws FileNotFoundException
FileNotFoundException
public DiskFile(String filePath,
String mode)
throws FileNotFoundException
FileNotFoundException| Method Detail |
|---|
public void read(byte[] buffer,
int offset,
int byteSize)
throws DBException
DBFile
read in interface DBFilebuffer - the buffer into which the data is readoffset - the start offset in the buffer at which the data is writtenbyteSize - the bytes to read
DBException
public void seek(long filePos)
throws DBException
DBFile
seek in interface DBFileDBException
public void write(byte[] buffer,
int offset,
int byteSize)
throws DBException
DBFile
write in interface DBFilebuffer - the dataoffset - the start offset in the databyteSize - the bytes to write
DBException
public void close()
throws DBException
DBFile
close in interface DBFileDBException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
