public interface IDataAccessSession extends IDataAccessSessionCommon
Modifier and Type | Method and Description |
---|---|
void |
addListener(IFilePersistenceCloseActionListener listener)
add a close action execution end listener
|
EnumFilePersistenceCloseAction |
close(EnumFilePersistenceCloseAction action)
close data access session with a save action
possible save actions EnumFilePersistenceCloseAction.SAVE ask for save modification, can be canceled by not save action by other data access session close. |
EnumFilePersistenceCloseAction |
closeAndWait(EnumFilePersistenceCloseAction action)
as
close(EnumFilePersistenceCloseAction) , but wait for effective
execution of action |
void |
openSynchronized()
open this data access session, synchronized with other session: will wait
for other session closed ( blocking )
|
void |
removeListener(IFilePersistenceCloseActionListener listener)
remove a close action execution end listener
|
getClassIdentifier, getMutex, getObject, getObject, getObjects, isClosed, isOpened, objectKeySet, open, removeAllObject, removeObject, setEnumState, setObject, storedEnum, storedImmutableEnum, storedImmutableEnum, storedMutableEnum, storedMutableEnum
void addListener(IFilePersistenceCloseActionListener listener)
listener
- close action execution end listenervoid removeListener(IFilePersistenceCloseActionListener listener)
listener
- close action execution end listenervoid openSynchronized() throws FilePersistenceException, FilePersistenceClassNotFoundException, FilePersistenceInvalidClassException, FilePersistenceDataCorruptedException, FilePersistenceNotSerializableException
FilePersistenceException
- failed read root object, session close pending can not reopenFilePersistenceInvalidClassException
- something is wrong with a class used by serializationFilePersistenceDataCorruptedException
- data is inconsistent.FilePersistenceClassNotFoundException
- Class of a serialized object cannot be found.FilePersistenceNotSerializableException
- Some object to be serialized does not follow joafip
persistence rules or does not implement the
java.io.Serializable interface.EnumFilePersistenceCloseAction close(EnumFilePersistenceCloseAction action) throws FilePersistenceException, FilePersistenceInvalidClassException, FilePersistenceNotSerializableException, FilePersistenceClassNotFoundException, FilePersistenceDataCorruptedException, FilePersistenceTooBigForSerializationException
EnumFilePersistenceCloseAction.SAVE
EnumFilePersistenceCloseAction.DO_NOT_SAVE
action
- close actionFilePersistenceException
- session not registered as opened session, no file in stable
state, file state restored to stable, file persistence is not
openedFilePersistenceNotSerializableException
- Some object to be serialized does not follow joafip
persistence rules or does not implement the
java.io.Serializable interface.FilePersistenceInvalidClassException
- something is wrong with a class used by serializationFilePersistenceClassNotFoundException
- Class of a serialized object cannot be found.FilePersistenceDataCorruptedException
- data is inconsistentFilePersistenceTooBigForSerializationException
EnumFilePersistenceCloseAction closeAndWait(EnumFilePersistenceCloseAction action) throws FilePersistenceException, FilePersistenceInvalidClassException, FilePersistenceNotSerializableException, FilePersistenceClassNotFoundException, FilePersistenceDataCorruptedException, FilePersistenceTooBigForSerializationException
close(EnumFilePersistenceCloseAction)
, but wait for effective
execution of actionaction
- close actionFilePersistenceException
- session not registered as opened session, no file in stable
state, file state restored to stable, file persistence is not
opened, close wait interruptedFilePersistenceNotSerializableException
- Some object to be serialized does not follow joafip
persistence rules or does not implement the
java.io.Serializable interface.FilePersistenceInvalidClassException
- something is wrong with a class used by serializationFilePersistenceClassNotFoundException
- Class of a serialized object cannot be found.FilePersistenceDataCorruptedException
- data is inconsistentFilePersistenceTooBigForSerializationException
Copyright © 2007-2012 Luc Peuvrier. All Rights Reserved.