info.magnolia.dam.asset
Interface Asset

All Known Subinterfaces:
Rendition
All Known Implementing Classes:
AbstractBaseAsset, AssetWrapper, JcrAsset

public interface Asset

Asset interface definition. Important:
getIdentifier() must return the composite Id


Method Summary
 String getAssetProviderIdentifier()
           
 String getCaption()
           
 String getComment()
           
 InputStream getContentStream()
           
 String getCopyright()
           
 Object getCustomProperty(String propertyName)
          Give the ability to access a custom property from the Asset API.
 String getDescription()
           
 String getFileExtension()
           
 String getFileName()
           
 long getFileSize()
           
 String getIdentifier()
          This identifier is the key used by the DamIdParser in order to be able to identify both:
the Asset
the Asset Provider.
 String getLanguage()
           
 Calendar getLastModified()
           
 String getLink()
           
 String getMediaType()
           
 AssetMetadata getMetadata(String metaDataType)
           
 String getMimeType()
           
 String getName()
           
 String getPath()
           
 String getSubject()
           
 String getTitle()
           
 

Method Detail

getName

String getName()
Returns:
Name of the Asset.

getLanguage

String getLanguage()
Returns:
String representation of Locale http://www.ics.uci.edu/pub/ietf/http/related/iso639.txt.

getIdentifier

String getIdentifier()
This identifier is the key used by the DamIdParser in order to be able to identify both:
the Asset
the Asset Provider.

Returns:
Unique Identifier of the Asset.

getTitle

String getTitle()
Returns:
Title of the Asset.

getMediaType

String getMediaType()
Returns:
The MediaType definition part of the MediaType.

getSubject

String getSubject()
Returns:
The Subject of the Asset.

getDescription

String getDescription()
Returns:
The Description of Asset.

getCaption

String getCaption()
Returns:
The Asset Caption.

getCopyright

String getCopyright()
Returns:
The Asset Copyright.

getMimeType

String getMimeType()
Returns:
The Asset binary content mimeType.

getFileSize

long getFileSize()
Returns:
The Asset binary content size.

getContentStream

InputStream getContentStream()
Returns:
The Asset binary data as InputStream.

getMetadata

AssetMetadata getMetadata(String metaDataType)
                          throws AssetMetadataTypeNotSupportedException
Returns:
The specific implementation of the requested Metadata. Null if the specified implementation was not found.
Throws:
AssetMetadataTypeNotSupportedException

getLink

String getLink()
               throws DamException
Returns:
Return the Link to the default rendition.
Throws:
DamException

getPath

String getPath()
Returns:
The Asset path. For JCR this is equivalent to Node.getPath()

getLastModified

Calendar getLastModified()
Returns:
The Asset last modified Date.

getFileExtension

String getFileExtension()
Returns:
The Asset Binary content extension.

getFileName

String getFileName()
Returns:
The Asset Binary content file Name.

getComment

String getComment()
Returns:
The Asset comment.

getAssetProviderIdentifier

String getAssetProviderIdentifier()
Returns:
The related Asset Provider Id.

getCustomProperty

Object getCustomProperty(String propertyName)
Give the ability to access a custom property from the Asset API.

Parameters:
propertyName -
Returns:
The Asset property referred to by the propertyName. Null if not found.


Copyright © 2014 Magnolia International Ltd.. All Rights Reserved.