public interface IHeapElementManager
Modifier and Type | Method and Description |
---|---|
void |
appendHeapFileRecord(IFileStorable heapRecord)
append an heap file record that will be to write in file
|
String |
backup(long identifier,
int maxBackup) |
void |
clear()
clear heap content
service must be started and transaction opened |
void |
clearReadCache() |
void |
closeTransaction()
close the heap file transaction management committing the modifications
to the file before
|
void |
closeTransactionDiscardChange()
close the heap file transaction management without commit modification in
file
|
void |
delete(long positionInFile) |
IDataRecordKeyManager |
getDataRecordKeyManager() |
IFileForStorable |
getFileForStorable() |
long |
getFileSize() |
IFileStorable |
getHeapHeader() |
IHeapRecordFactory |
getHeapRecordFactory() |
int |
getNumberOfHeaprecordInMemory() |
boolean |
isCrashSafeMode() |
boolean |
isDataLost()
the returned value is set by
wasBadFileStableState() |
boolean |
isServiceStarted() |
boolean |
isTransactionOpened() |
void |
openTransaction()
open the heap file transaction management
|
IFileStorable |
readHeapFileDataRecord(long positionInFile)
read heap record in file
|
void |
removeFiles()
removes files containing heap data
transaction must be closed and service stopped |
void |
setDataRecordKeyManager(IDataRecordKeyManager dataRecordKeyManager) |
void |
setHeapHeader(IFileStorable heapHeader)
set heap header
|
void |
setHeapRecordFactory(IHeapRecordFactory heapRecordFactory) |
void |
startService()
start heap record management service
|
void |
stopService()
stop heap record management service
|
boolean |
wasBadFileStableState()
check file stable state, restore if possible
service must not be started must be called before heap file access |
void setHeapHeader(IFileStorable heapHeader) throws HeapException
heapHeader
- HeapException
boolean isCrashSafeMode()
IFileForStorable getFileForStorable()
boolean wasBadFileStableState() throws HeapException
HeapException
- no file in stable state, no files in stable stateboolean isDataLost()
wasBadFileStableState()
wasBadFileStableState()
void removeFiles() throws HeapException
HeapException
void startService() throws HeapException
HeapException
- file access error
file data corruptedvoid stopService() throws HeapException
HeapException
boolean isServiceStarted()
void openTransaction() throws HeapException
HeapException
void closeTransaction() throws HeapException
HeapException
void closeTransactionDiscardChange() throws HeapException
HeapException
boolean isTransactionOpened()
void clear() throws HeapException
HeapException
IFileStorable getHeapHeader() throws HeapException
HeapException
IFileStorable readHeapFileDataRecord(long positionInFile) throws HeapException
positionInFile
- heap record position in fileHeapException
void appendHeapFileRecord(IFileStorable heapRecord) throws HeapException
heapRecord
- the heap file record to appendHeapException
void delete(long positionInFile) throws HeapException
positionInFile
- HeapException
long getFileSize() throws HeapException
HeapException
int getNumberOfHeaprecordInMemory()
void setHeapRecordFactory(IHeapRecordFactory heapRecordFactory)
IHeapRecordFactory getHeapRecordFactory()
void setDataRecordKeyManager(IDataRecordKeyManager dataRecordKeyManager)
IDataRecordKeyManager getDataRecordKeyManager()
String backup(long identifier, int maxBackup) throws HeapException
HeapException
void clearReadCache()
Copyright © 2007-2012 Luc Peuvrier. All Rights Reserved.