Interface MediaConversionStrategy
- All Known Implementing Classes:
ImageMagickMediaConversionStrategy
public interface MediaConversionStrategy
Strategy on how to convert a media to a given
ConversionMediaFormatModel. The actual
MediaConversionStrategy to use is configured as a spring bean name in the ConversionMediaFormatModel
's conversionStrategy attribute.-
Method Summary
Modifier and TypeMethodDescriptionconvert(MediaConversionService mediaConversionService, MediaModel parent, ConversionMediaFormatModel format) Converts the givenparentmedia to the givenformat.
-
Method Details
-
convert
MediaModel convert(MediaConversionService mediaConversionService, MediaModel parent, ConversionMediaFormatModel format) throws MediaConversionException Converts the givenparentmedia to the givenformat.- Parameters:
mediaConversionService- to avoid cyclic IoC errors, theMediaConversionServiceis passed.parent- the media to convertformat- the format to convert to- Returns:
- a fresh created media in the given format
- Throws:
MediaConversionException- if the conversion could not be processed due to a technical reasonIllegalArgumentException- if any of the parameters isnull
-