info.magnolia.dam.asset.metadata.builder
Interface AssetMetadataBuilder<M extends AssetMetadata,O>

Type Parameters:
M -
O -
All Known Implementing Classes:
JcrAssetMetadataBuilder

public interface AssetMetadataBuilder<M extends AssetMetadata,O>

Generic definition of an Asset Metadata Builder.
The main task of the builder is to create Asset Matadata based on a source Object and a Metadata Type.


Method Summary
 M createAssetMetadata(O source, String metadataType)
          Create an Asset Metadata based on a source Object and of the desired metadataType.
 O createSourceMetadata(M assetMetadata, String metadata)
          Create an Source Asset Metadata representation based on the assetMetadata object and desired metadataType.
 

Method Detail

createAssetMetadata

M createAssetMetadata(O source,
                      String metadataType)
                                            throws AssetMetadataTypeNotSupportedException
Create an Asset Metadata based on a source Object and of the desired metadataType.

Returns:
null in case of exception.
Throws:
AssetMetadataTypeNotSupportedException

createSourceMetadata

O createSourceMetadata(M assetMetadata,
                       String metadata)
                       throws AssetMetadataTypeNotSupportedException
Create an Source Asset Metadata representation based on the assetMetadata object and desired metadataType.

Returns:
null in case of exception.
Throws:
AssetMetadataTypeNotSupportedException


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