|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectru.biosoft.util.FileBuffer
ru.biosoft.util.FastFileBuffer
Optimized by speed implementation of FileBuffer interface.
| Field Summary | |
protected static org.apache.log4j.Category |
cat
|
| Constructor Summary | |
FastFileBuffer(java.io.File file)
Constructs the RandomAccessBuffer object. |
|
FastFileBuffer(java.io.File file,
int sz)
Constructs the RandomAccessBuffer object . |
|
FastFileBuffer(java.io.RandomAccessFile rndFile)
Constructs the RandomAccessBuffer object . |
|
FastFileBuffer(java.io.RandomAccessFile rndFile,
int sz)
Constructs the RandomAccessBuffer object . |
|
| Method Summary | |
void |
close()
Closes the buffer. |
protected void |
finalize()
Stores all buffers and closes random access file |
byte |
read(int pos)
Reads one byte from requested position. |
void |
write(int pos,
byte bt)
Writes one byte to the requested position in the buffer. |
| Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected static org.apache.log4j.Category cat
| Constructor Detail |
public FastFileBuffer(java.io.RandomAccessFile rndFile,
int sz)
throws java.io.IOException
rndFile - random access filesz - Size of one buffer.
java.io.IOException - any I/O errors
public FastFileBuffer(java.io.RandomAccessFile rndFile)
throws java.io.IOException
sz
rndFile - random access file
java.io.IOException - any I/O errors
public FastFileBuffer(java.io.File file,
int sz)
throws java.io.IOException
file - random access filesz - Size of one buffer.
java.io.IOException - any I/O errors
public FastFileBuffer(java.io.File file)
throws java.io.IOException
file - random access file
java.io.IOException - any I/O errors| Method Detail |
public byte read(int pos)
throws java.io.IOException
read in class FileBufferpos - position of requested byte
java.io.IOException - any I/O errors
public void write(int pos,
byte bt)
throws java.io.IOException
write in class FileBufferpos - position of requested bytebt - stored byte
java.io.IOException - any I/O errors
public void close()
throws java.io.IOException
close in class FileBufferjava.io.IOException - if an I/O error occurs.
protected void finalize()
throws java.lang.Throwable
java.lang.Throwable - any errors
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||