public interface IDataAccessSessionCommon
Modifier and Type | Method and Description |
---|---|
int |
getClassIdentifier(Class<?> clazz) |
JoafipMutex |
getMutex() |
Object |
getObject(long dataRecordIdentifier) |
Object |
getObject(String key)
get a persistent object by its key
|
Collection<Object> |
getObjects() |
boolean |
isClosed() |
boolean |
isOpened() |
Set<String> |
objectKeySet() |
void |
open()
open this data access session, not synchronized with other session
|
void |
removeAllObject()
remove all persistent object
|
Object |
removeObject(String key)
remove a persistent object associated to a key
|
void |
setEnumState(Enum<?> enumObject)
Deprecated.
|
Object |
setObject(String key,
Object object)
add a persistent object associated to a key
|
void |
storedEnum(Class<? extends Enum<?>> enumClass)
Deprecated.
|
void |
storedImmutableEnum(Class<? extends Enum<?>> enumClass) |
void |
storedImmutableEnum(Class<? extends Enum<?>>[] enumClasses) |
void |
storedMutableEnum(Class<? extends Enum<?>> enumClass) |
void |
storedMutableEnum(Class<? extends Enum<?>>[] enumClasses) |
@Deprecated void storedEnum(Class<? extends Enum<?>> enumClass) throws FilePersistenceException
enumClass
- the enum classFilePersistenceException
void storedImmutableEnum(Class<? extends Enum<?>> enumClass) throws FilePersistenceException
FilePersistenceException
void storedImmutableEnum(Class<? extends Enum<?>>[] enumClasses) throws FilePersistenceException
FilePersistenceException
void storedMutableEnum(Class<? extends Enum<?>> enumClass) throws FilePersistenceException
FilePersistenceException
void storedMutableEnum(Class<? extends Enum<?>>[] enumClasses) throws FilePersistenceException
FilePersistenceException
void open() 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.boolean isOpened() throws FilePersistenceException
FilePersistenceException
boolean isClosed() throws FilePersistenceException
FilePersistenceException
Object getObject(String key) throws FilePersistenceException
key
- the persistent object keyFilePersistenceException
- this data access session not openedObject getObject(long dataRecordIdentifier) throws FilePersistenceException, FilePersistenceClassNotFoundException, FilePersistenceInvalidClassException, FilePersistenceDataCorruptedException, FilePersistenceNotSerializableException
Object setObject(String key, Object object) throws FilePersistenceException
key
- the object access keyobject
- the persistent objectFilePersistenceException
- this data access session not openedObject removeObject(String key) throws FilePersistenceException
key
- the object access keyFilePersistenceException
- this data access session not openedvoid removeAllObject() throws FilePersistenceException
FilePersistenceException
@Deprecated void setEnumState(Enum<?> enumObject) throws FilePersistenceException
enumObject
- the enum for which state must be setFilePersistenceException
Set<String> objectKeySet() throws FilePersistenceException
FilePersistenceException
- this data access session not openedCollection<Object> getObjects() throws FilePersistenceException
FilePersistenceException
int getClassIdentifier(Class<?> clazz) throws FilePersistenceException, FilePersistenceClassNotFoundException
clazz
- FilePersistenceException
FilePersistenceClassNotFoundException
JoafipMutex getMutex()
Copyright © 2007-2012 Luc Peuvrier. All Rights Reserved.