com.uwyn.rife.cmf.transform
Interface ContentTransformer<InternalType>

All Known Subinterfaces:
ImageContentTransformer, RawContentTransformer, TextContentTransformer

public interface ContentTransformer<InternalType>

This interface defines the API that has to be implemented by classes that are capable of transforming content data after it's initially loaded.

The content attributes are provided to the transform method and can be used to provide hints for the transformation.

Each transformer is supposed to transform content data of a certain data type and return the transformed content in the same data type. You should be careful that this data type corresponds to the data type that's returned by the format method of the formatter that handles the content's mime type.

Since:
1.0
Version:
$Revision: 3634 $
Author:
Geert Bevin (gbevin[remove] at uwyn dot com)

Method Summary
 InternalType transform(InternalType data, Map<String,String> attributes)
          Transforms the content data and returns the transformed data in the same data type as the original.
 

Method Detail

transform

InternalType transform(InternalType data,
                       Map<String,String> attributes)
                       throws ContentManagerException
Transforms the content data and returns the transformed data in the same data type as the original.

Parameters:
data - the content data that has to be transformed
attributes - a map of content attributes that can be used to provide hints or parameters for the transformation
Returns:
the transformed data
Throws:
ContentManagerException
Since:
1.0


Copyright © 2001-2007 Uwyn sprl/bvba. All Rights Reserved.