public interface IStorageModule<ConfigType extends StorageConfig> extends IModule<ConfigType>
Modifier and Type | Method and Description |
---|---|
void |
backup(OutputStream os)
Backups storage to specified output stream
|
void |
commit()
Commits all changes generated by transactional methods since the last commit event
|
boolean |
isAutoCommit()
Retrieves auto-commit state
|
void |
restore(InputStream is)
Restores storage from backup obtained from specified input stream
|
void |
rollback()
Cancels all changes generated by transactional methods since the last commit event
|
void |
setAutoCommit(boolean autoCommit)
Changes the storage behavior on record insertion, update or deletion
|
void |
sync(IStorageModule<?> storage)
Synchronizes storage with another storage of the same type (potentially remote)
|
cleanup, getConfiguration, getLocalID, getName, init, isEnabled, loadState, registerListener, saveState, start, stop, unregisterListener, updateConfig
void backup(OutputStream os) throws IOException
os
- IOException
void restore(InputStream is) throws IOException
is
- IOException
void setAutoCommit(boolean autoCommit)
autoCommit
- true to commit changes automatically when a transactional method is called,
false if the commit() method should be called manually to persist changes to storage.boolean isAutoCommit()
void commit()
void rollback()
void sync(IStorageModule<?> storage) throws StorageException
storage
- StorageException
Copyright © 2015 Sensia Software LLC. All rights reserved.