|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface DataStorage
DataModelManager is the data type manager which can store Data and DataModel. It is just a container which has no idea of it's content. It manages a collection of DataAccessors which can extract data from it.
| Method Summary | ||
|---|---|---|
boolean |
addDataPacketListener(DataPacketId packetId,
DataPacketListener listener)
Adds a listener on a data packet with given Id. |
|
boolean |
addDataStorageListener(DataStorageListener listener)
Adds a listener on this data storage. |
|
Set<DataPacketId> |
getDataListSafe(Class<?> objectClass)
Gets the list of ids for the objects of the given type. |
|
Set<DataPacketId> |
getDataListUnsafe(Class<?> objectClass)
Gets the list of ids for the objects of the given type. |
|
|
getDataSafe(DataPacketId packetId)
Gets the data object corresponding to the given unique id. |
|
|
getDataSafe(String objectName)
Gets the data object corresponding to the given name. |
|
|
getDataUnsafe(DataPacketId packetId)
Gets the data object corresponding to the given unique id. |
|
|
getDataUnsafe(String objectName)
Gets the data object corresponding to the given name. |
|
int |
getNbData()
Get the total number of stored data (safe+unsafe). |
|
String |
getPacketInformation(DataPacketId packetId)
Gets the information of the packet with the given id. |
|
Boolean |
isReadLocked(DataPacketId packetId)
Checks if the data packet with the given id is read locked. |
|
Boolean |
isWriteLocked(DataPacketId packetId)
Checks if the data packet with the given id is write locked. |
|
boolean |
removeDataPacketListener(DataPacketId packetId,
DataPacketListener listener)
Removes a listener from a data packet with given Id. |
|
boolean |
removeDataStorageListener(DataStorageListener listener)
Removes a listener from this data storage. |
|
boolean |
setDataSafe(Serializable serializableObject,
DataPacketId packetId)
Sets the object with the given unique id in the data storage. |
|
DataPacketId |
setDataSafe(String name,
Serializable serializableObject)
Sets the object with the given name in the data storage. |
|
|
setDataUnsafe(String name,
ObjectType object)
Sets the object with the given name in the data storage. |
|
| Method Detail |
|---|
int getNbData()
<ObjectType> DataPacketId setDataUnsafe(String name,
ObjectType object)
throws DataIOException
ObjectType - the type of the object to setname - the object nameobject - the object to set
DataIOException - if the data writting failed
DataPacketId setDataSafe(String name,
Serializable serializableObject)
throws DataIOException,
DataConcurrencyException
name - the object nameserializableObject - the object to set
DataIOException - if the data writting failed
DataConcurrencyException - in case of concurrent access to the data
boolean setDataSafe(Serializable serializableObject,
DataPacketId packetId)
throws DataIOException,
DataConcurrencyException
serializableObject - the object to setpacketId - the unique id of the object to set
DataIOException - if the data writting failed
DataConcurrencyException - in case of concurrent access to the data
<ObjectType> ObjectType getDataUnsafe(DataPacketId packetId)
throws DataIOException
packetId - the unique id of the object to retrieve
DataIOException - in case data reading failed
<ObjectType extends Serializable> ObjectType getDataSafe(String objectName)
throws DataIOException,
DataConcurrencyException
objectName - the name of the object to retrieve
DataIOException - in case data reading failed
DataConcurrencyException - in case of concurrent access to the data
<ObjectType> ObjectType getDataUnsafe(String objectName)
throws DataIOException
objectName - the name of the object to retrieve
DataIOException - in case data reading failed
<ObjectType extends Serializable> ObjectType getDataSafe(DataPacketId packetId)
throws DataIOException,
DataConcurrencyException
packetId - the unique id of the object to retrieve
DataIOException - in case data reading failed
DataConcurrencyException - in case of concurrent access to the dataSet<DataPacketId> getDataListSafe(Class<?> objectClass)
objectClass - the type of object to fetch
DataIOException - in case data reading failedSet<DataPacketId> getDataListUnsafe(Class<?> objectClass)
objectClass - the type of object to fetch
DataIOException - in case data reading failedboolean addDataStorageListener(DataStorageListener listener)
listener - the listener to addboolean removeDataStorageListener(DataStorageListener listener)
listener - the listener to remove
boolean addDataPacketListener(DataPacketId packetId,
DataPacketListener listener)
packetId - the id of the packet to listenthe - listener to add
boolean removeDataPacketListener(DataPacketId packetId,
DataPacketListener listener)
packetId - the id of the packet to stop listenningthe - listener to removeString getPacketInformation(DataPacketId packetId)
packetId - the id of the packet
Boolean isWriteLocked(DataPacketId packetId)
packetId - the id of the packet to check
Boolean isReadLocked(DataPacketId packetId)
packetId - the id of the packet to check
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||