Package org.scictrl.csshell.epics.server
Class PersistencyStore
java.lang.Object
org.scictrl.csshell.epics.server.PersistencyStore
- All Implemented Interfaces:
Runnable
Stores and restores state of Record or PersistentValueProcessor, which are registered.
- Author:
- igor@scictrl.com
-
Constructor Summary
ConstructorsConstructorDescriptionMake instance of store, that operates as a dummy.PersistencyStore(File f, Database database) Constructor for PersistencyStore. -
Method Summary
Modifier and TypeMethodDescriptionbooleanderegister.booleanderegister(Record rec) deregister.voidflush()flush.voidRegisters provided processor with store/restore service.voidregisterValue(Record rec) Registers provided record to have value stored.voidrun()voidsaveAll()saveAll.
-
Constructor Details
-
PersistencyStore
public PersistencyStore() throws org.apache.commons.configuration.ConfigurationExceptionMake instance of store, that operates as a dummy.- Throws:
org.apache.commons.configuration.ConfigurationException- configuration error
-
PersistencyStore
public PersistencyStore(File f, Database database) throws org.apache.commons.configuration.ConfigurationException Constructor for PersistencyStore.
-
-
Method Details
-
flush
public void flush()flush.
-
run
public void run() -
registerProcessor
Registers provided processor with store/restore service. First restores any previously stored status to the processor, as defined byPersistentValueProcessor.restore(org.apache.commons.configuration.Configuration). Then processor is monitored for changes and any change triggers store functionality, as defined byPersistentValueProcessor.store(org.apache.commons.configuration.Configuration).- Parameters:
proc- the processor to be stored
-
registerValue
Registers provided record to have value stored. Provided record is monitored for changes and any change triggers store functionality.- Parameters:
rec- aRecordobject
-
deregister
deregister.
- Parameters:
rec- aRecordobject- Returns:
- a boolean
-
deregister
deregister.
- Parameters:
proc- aPersistentValueProcessorobject- Returns:
- a boolean
-
saveAll
public void saveAll()saveAll.
-