Interface AMImageValidator
public interface AMImageValidator
Validates image size for Adaptive Media.
-
Method Summary
Modifier and TypeMethodDescription<T> booleanisProcessingRequired(com.liferay.adaptive.media.AdaptiveMedia<T> adaptiveMedia, com.liferay.portal.kernel.repository.model.FileVersion fileVersion) default booleanisProcessingSupported(com.liferay.portal.kernel.repository.model.FileVersion fileVersion) Returnstrueif the provided file version supports image processing.booleanisProcessingSupported(String mimeType) Returnstrueif the provided mimeType supports image processing.booleanisValid(com.liferay.portal.kernel.repository.model.FileVersion fileVersion) Returnstrueif the provided file version is valid for Adaptive Media.
-
Method Details
-
isProcessingRequired
<T> boolean isProcessingRequired(com.liferay.adaptive.media.AdaptiveMedia<T> adaptiveMedia, com.liferay.portal.kernel.repository.model.FileVersion fileVersion) -
isProcessingSupported
default boolean isProcessingSupported(com.liferay.portal.kernel.repository.model.FileVersion fileVersion) Returnstrueif the provided file version supports image processing. Adaptive Media works with some media types where the content doesn't need to be processed or doesn't support processing at all (e.g. SVG).- Returns:
trueif the file version supports image processing.
-
isProcessingSupported
Returnstrueif the provided mimeType supports image processing. Adaptive Media works with some media types where the content doesn't need to be processed or doesn't support processing at all (e.g. SVG).- Returns:
trueif the file version supports image processing.
-
isValid
boolean isValid(com.liferay.portal.kernel.repository.model.FileVersion fileVersion) Returnstrueif the provided file version is valid for Adaptive Media.- Returns:
trueif the file version is valid for Adaptive Media
-