|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.norther.tammi.acorn.io.RecordAccessFile.RecordHeader
protected static class RecordAccessFile.RecordHeader
A header for records.
Constructor Summary | |
---|---|
protected |
RecordAccessFile.RecordHeader()
Constructs a new header. |
|
RecordAccessFile.RecordHeader(long ptr,
int cap)
Constructs a new header with pointer and capacity. |
Method Summary | |
---|---|
int |
getCapacity()
Gets the capacity. |
int |
getFreeSpace()
Gets the free space. |
int |
getIndex()
Gets the index. |
long |
getPointer()
Gets the pointer. |
int |
getSize()
Gets the size. |
void |
read(DataInput data)
Reads the header data. |
static RecordAccessFile.RecordHeader |
readHeader(DataInput data)
Reads the next record header. |
void |
setCapacity(int cap)
Sets the capacity. |
void |
setIndex(int ind)
Sets the index. |
void |
setPointer(long ptr)
Sets the pointer. |
void |
setSize(int s)
Sets the size. |
RecordAccessFile.RecordHeader |
split()
Splits the free space to a new record. |
void |
write(DataOutput data)
Writes the header data. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected RecordAccessFile.RecordHeader()
public RecordAccessFile.RecordHeader(long ptr, int cap)
ptr
- the pointer.cap
- the capacity.Method Detail |
---|
public static RecordAccessFile.RecordHeader readHeader(DataInput data) throws IOException
data
- the data input.
IOException
- on errors.public int getIndex()
public void setIndex(int ind)
ind
- the index.public long getPointer()
public void setPointer(long ptr)
ptr
- the pointer.public int getSize()
public void setSize(int s)
s
- the size.public int getCapacity()
public void setCapacity(int cap)
cap
- the capacity.public int getFreeSpace()
public void read(DataInput data) throws IOException
data
- the data input.
IOException
- on errors.public void write(DataOutput data) throws IOException
data
- the data output.
IOException
- on errors.public RecordAccessFile.RecordHeader split()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |