Skip navigation links


com.fatwire.assetapi.data
Interface AssetData

All Known Subinterfaces:
MutableAssetData
All Known Implementing Classes:
AssetDataImpl

public interface AssetData

This interface represents an asset instance (data of a single asset). The intention of the interface is to provide a view (possibly a narrower view) of data contained in the asset.

AssetData is a combination of

AttributeData represents data for a given attribute. A given instance of AssetData may not contain data for all attributes. List of attribute names whose data is part of an AssetData instance can be obtained by invoking AssetData.getAttributeNames().

Attributes for which data exists in an AssetData instance is determined by how the instance of AssetData was obtained. See AssetDataManager for ways to obtain an instance of AssetData.


Method Summary
 AssetId getAssetId()
          Returns unique identification of the asset instance AssetId
 AssetTypeDef getAssetTypeDef()
          Returns AssetTypeDef this instance is based on.
 java.util.List<AssetId> getAssociatedAssets(java.lang.String name)
          Returns named associations by given name.
 java.util.List<AttributeData> getAttributeData()
          Returns a list of all attribute data associated with this instance of asset
 AttributeData getAttributeData(java.lang.String attributeName)
          Returns data associated with a given attribute.
 AttributeData getAttributeData(java.lang.String attributeName, boolean isMetaAttribute)
          Returns a data associated with a given attribute
 java.util.List<java.lang.String> getAttributeNames()
          Returns List of attribute names contained in this instance of AssetData.
 java.util.List<AssetId> getImmediateParents()
          Returns the Asset Identifiers of immediate parents, if any.
 java.util.List<AssetId> getImmediateParents(java.lang.String parentDefName)
          Returns the Asset Identifiers of immediate parents, if any.
 java.util.List<AssetId> getParents()
          Returns Asset identifiers of parent assets, if any.
 void setAssetId(AssetId assetId)
          Sets unique identification of the asset instance AssetId

 

Method Detail

getAssetId

AssetId getAssetId()
Returns unique identification of the asset instance AssetId
Returns:
AssetId associated with the instance

getAttributeNames

java.util.List<java.lang.String> getAttributeNames()
Returns List of attribute names contained in this instance of AssetData.
Returns:
Attribute names that make this instance of AssetData. (note: the asset itself could have more attributes, use AssetTypeDef to get to those).

getAssetTypeDef

AssetTypeDef getAssetTypeDef()
Returns AssetTypeDef this instance is based on.
Returns:
returns a AssetTypeDef handle to the asset type this instance is built upon.

getAttributeData

AttributeData getAttributeData(java.lang.String attributeName)
Returns data associated with a given attribute.
Parameters:
attributeName - name of the attribute
Returns:
AttributeData instance for an attribute of a given name. Returns null if no AttributeData of specified name

getAttributeData

AttributeData getAttributeData(java.lang.String attributeName,
                               boolean isMetaAttribute)
Returns a data associated with a given attribute
Parameters:
attributeName - name of the attribute
isMetaAttribute - whether attribute is user defined, or it is system defined (for flex asset only)
Returns:
AttributeData instance for an attribute of given name and boolean property. Returns null if no AttributeData of specified name and specified user defined or not property.

getAttributeData

java.util.List<AttributeData> getAttributeData()
Returns a list of all attribute data associated with this instance of asset
Returns:
List of all attribute data

getAssociatedAssets

java.util.List<AssetId> getAssociatedAssets(java.lang.String name)
Returns named associations by given name. Note: unnamed association is retrieved by using AssetAssociationDef.UnnamedAssociationName constant in place association name.
Parameters:
name - name of the association
Returns:
List of AssetId of associated assets.

getParents

java.util.List<AssetId> getParents()
                                   throws AssetAccessException
Returns Asset identifiers of parent assets, if any.
Returns:
List of parent asset identifiers for this asset instance, if any.
Throws:
AssetAccessException - captures layer specific failures and wraps other internal exceptions.

getImmediateParents

java.util.List<AssetId> getImmediateParents()
                                            throws AssetAccessException
Returns the Asset Identifiers of immediate parents, if any.
Returns:
List of parents asset ids
Throws:
AssetAccessException - captures layer specific failures and wraps other internal excetpions

getImmediateParents

java.util.List<AssetId> getImmediateParents(java.lang.String parentDefName)
                                            throws AssetAccessException
Returns the Asset Identifiers of immediate parents, if any. The immediate parents are grouped with the flex parent definition id
Parameters:
parentDefName - the name of the parent definition
Returns:
List of parents asset ids
Throws:
AssetAccessException - captures layer specific failures and wraps other internal excetpions

setAssetId

void setAssetId(AssetId assetId)
Sets unique identification of the asset instance AssetId
Parameters:
assetId - associated with the instance

Skip navigation links


Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.