|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AssetDataManager
This interface is the primary access point for getting to Asset's data.
An asset data can be looked up either by itsAssetId
using AssetDataManager.read(List)
or by using a Query
in AssetDataManager.read(Query)
.
A Query is an abstract construct that defines user's request for asset's data. Query can be considered as an object
representation of SQL.
Using Query one would be able to specify Condition
(a set of matching criterion) to limit the assets returned as well as the sorting order in which the results are to be read.
A Query also limits the number of attributes to be retrived. Limiting the Query to contain only a few attributes limits the
amount of data that read into memory.
Query also contains an accessory set of properties, QueryProperties
.
QueryProperties can be used, among other things, to specify the type of query algorithm to use.
For more details about Query, its construct and limitations please see Query
Note: Only read methods are implemented in CS version 7.0. Methods for which implementation does not exist
throw UnsupportedOperationException.
Method Summary | |
---|---|
void |
delete(java.util.List<AssetId> data)
Deletes a given Iterator of AssetIds from database. |
void |
insert(java.util.List<AssetData> data)
NOTE: This method is not implemented yet. |
AssetData |
newAssetData(java.lang.String assetTypeName,
AssetData example)
NOTE: This method is not implemented yet. |
AttributeData |
newAttribiteData(java.lang.String attributeName,
java.lang.String assetTypeName,
java.lang.String subtype)
NOTE: This method is not implemented yet. |
java.lang.Iterable<AssetData> |
read(java.util.List<AssetId> ids)
Reads asset data for all given AssetId s. |
java.lang.Iterable<AssetData> |
read(Query query)
Reads all asset data that satisfies a given Query |
AssetData |
readAttributes(AssetId id,
java.util.List<java.lang.String> attributeNames)
Reads given set attribute data and returns an AssetData instance containing them. |
java.lang.Iterable<MutableAssetData> |
readForUpdate(java.util.List<AssetId> ids)
NOTE: This method is not implemented yet. |
java.lang.Iterable<MutableAssetData> |
readForUpdate(Query query)
NOTE: This method is not implemented yet. |
void |
update(java.util.List<AssetData> data)
NOTE: This method is not implemented yet. |
Method Detail |
---|
java.lang.Iterable<AssetData> read(Query query) throws AssetAccessException
query
- Query to be satisfied.
AssetAccessException
- is thrown when Query is invalid by the way of incorrect attributes or invalid operation given
the choice of query algorithm. AssetAccessException also wraps any AssetExcptions thrown by the internal implementation.java.lang.Iterable<MutableAssetData> readForUpdate(Query query) throws AssetAccessException
query
- Query to be satisfied.
AssetAccessException
- is the layer specific failures and wraps other internal exceptions.java.lang.Iterable<AssetData> read(java.util.List<AssetId> ids) throws AssetAccessException
AssetId
s.
ids
- List of AssetIds
AssetAccessException
- is thrown when any of the AssetIds passed in does not exist.
AssetAccessException also wraps any AssetExcptions thrown by the internal implementation.java.lang.Iterable<MutableAssetData> readForUpdate(java.util.List<AssetId> ids) throws AssetAccessException
ids
- List of AssetIds
AssetAccessException
- captures layer specific failures and wraps other internal exceptions.AssetData readAttributes(AssetId id, java.util.List<java.lang.String> attributeNames) throws AssetAccessException
id
- AssetId to read attributes forattributeNames
- names of the attributes
AssetAccessException
- if thrown if the AssetId does not exist or attrbute names passed are incorrect
for the asset. AssetAccessException also wraps any AssetExcptions thrown by the internal implementation.void insert(java.util.List<AssetData> data) throws AssetAccessException
data
- AssetData to be inserted.
AssetAccessException
- captures layer specific failures and wraps other internal exceptions.void update(java.util.List<AssetData> data) throws AssetAccessException
data
- AssetData to be updated.
AssetAccessException
- captures layer specific failures and wraps other internal exceptions.void delete(java.util.List<AssetId> data) throws AssetAccessException
data
- AssetIds to be deleted.
AssetAccessException
- captures layer specific failures and wraps other internal exceptions.AttributeData newAttribiteData(java.lang.String attributeName, java.lang.String assetTypeName, java.lang.String subtype)
attributeName
- name of the attributeassetTypeName
- name of asset typesubtype
- subtype of asset type.
AssetData newAssetData(java.lang.String assetTypeName, AssetData example)
assetTypeName
- name of the asset typeexample
- optional example AsetData the returned will be based on.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |