|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IHeapDataManager
data management on heap file
| Method Summary | |
|---|---|
void |
backup(long identifier,
int maxBackup)
|
void |
checkIntegrity()
check heap integrity |
void |
clearStandbyModification()
clear creation, modification, and deletion to do on the heap the heap remains unchanged |
java.util.Iterator<DataRecordIdentifier> |
dataRecordIterator()
|
void |
deleteDataRecord(DataRecordIdentifier dataRecordIdentifier)
delete an existing data record knowing its identifier |
void |
flush()
flush creation, modification, and deletion to the heap the heap is updated write is disabled after flush |
long |
freeSize()
|
java.lang.String |
getBackupFileName()
|
java.lang.String |
getChangeFileName()
|
java.util.Set<DataRecordIdentifier> |
getDataRecordIdentifierSet()
for test purpose |
DataRecordIdentifier |
getNewDataRecordIdentifier()
to get a new data identifier for data record creation when created #readHeapDataRecord(DataRecordIdentifier) can be
used for the data record identifier |
DataRecordIdentifier |
getNextFreeDataRecordIdentifier()
|
int |
getNumberOfDataRecord()
|
int |
getNumberOfFreeRecord()
|
java.lang.String |
getStorageFileName()
|
boolean |
haveDataRecord(DataRecordIdentifier dataRecordIdentifier)
to check if have data record for a data record identifier |
long |
heapSize()
|
boolean |
isDataLost()
|
byte[] |
readDataRecord(DataRecordIdentifier dataRecordIdentifier)
read data for a data record |
void |
setNextFreeDataRecordIdentifier(DataRecordIdentifier dataRecordIdentifier)
|
void |
setWriteEnable(boolean writeEnable)
|
void |
startService(boolean removeFiles)
start heap data manager service. |
void |
stopService()
stop heap data manager service, do not flush in file any modification. |
long |
usedSize()
|
void |
writeDataRecord(DataRecordIdentifier dataRecordIdentifier,
byte[] data)
write data record |
| Method Detail |
|---|
void startService(boolean removeFiles)
throws HeapException
removeFiles - true if remove files before open common initialization at
construction
HeapException - read/write error, file restored from stable backup, file
management is not opened, no file in stable state
void stopService()
throws HeapException
HeapException
void setWriteEnable(boolean writeEnable)
throws HeapException
HeapException
DataRecordIdentifier getNextFreeDataRecordIdentifier()
throws HeapException
HeapException
void setNextFreeDataRecordIdentifier(DataRecordIdentifier dataRecordIdentifier)
throws HeapException
HeapException
DataRecordIdentifier getNewDataRecordIdentifier()
throws HeapException
#readHeapDataRecord(DataRecordIdentifier) can be
used for the data record identifier
HeapException
byte[] readDataRecord(DataRecordIdentifier dataRecordIdentifier)
throws HeapException
dataRecordIdentifier - data record to read identifier
HeapException
void writeDataRecord(DataRecordIdentifier dataRecordIdentifier,
byte[] data)
throws HeapException
dataRecordIdentifier - data record to write identifierdata - the data to write
HeapException
void deleteDataRecord(DataRecordIdentifier dataRecordIdentifier)
throws HeapException
dataRecordIdentifier - data record to delete identifier
HeapException
void flush()
throws HeapException
HeapException
void clearStandbyModification()
throws HeapException
HeapException
int getNumberOfDataRecord()
throws HeapException
HeapException
int getNumberOfFreeRecord()
throws HeapException
HeapException
long heapSize()
throws HeapException
HeapException
long freeSize()
throws HeapException
HeapException
long usedSize()
throws HeapException
HeapExceptionboolean isDataLost()
void checkIntegrity()
throws HeapException
HeapException - heap intgrity error
boolean haveDataRecord(DataRecordIdentifier dataRecordIdentifier)
throws HeapException
nodeIdentifier - the data record identifier
HeapException
@Fortest
java.util.Set<DataRecordIdentifier> getDataRecordIdentifierSet()
throws HeapException
HeapException
void backup(long identifier,
int maxBackup)
throws HeapException
HeapException
java.lang.String getStorageFileName()
throws HeapException
HeapException
java.lang.String getBackupFileName()
throws HeapException
HeapException
java.lang.String getChangeFileName()
throws HeapException
HeapExceptionjava.util.Iterator<DataRecordIdentifier> dataRecordIterator()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||