Package io.wcm.handler.media.format
Class ResponsiveMediaFormatsBuilder
- java.lang.Object
-
- io.wcm.handler.media.format.ResponsiveMediaFormatsBuilder
-
@ProviderType @Deprecated public final class ResponsiveMediaFormatsBuilder extends java.lang.Object
Deprecated.Use responsive image handling methods for image sizes and picture sources from MediaBuilder together withSimpleImageMediaMarkupBuilder
.Special builder that supports generating a on-the-fly list of media formats derived from a main media format with same ratio but different sizes for different breakpoints.The main media format should not have a fixed dimension defined, but only a ratio and probably min. width and height. The resulting media formats are only generated on-the-fly for the media resolution process. On each format a
MediaNameConstants.PROP_BREAKPOINT
breakpoint is set that is used by theResponsiveImageMediaMarkupBuilder
.
-
-
Constructor Summary
Constructors Constructor Description ResponsiveMediaFormatsBuilder(@NotNull MediaFormat mainMediaFormat)
Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description ResponsiveMediaFormatsBuilder
breakpoint(@NotNull java.lang.String breakpoint, int width, int height)
Deprecated.Defines one breakpoint for each "on-the-fly" format required.MediaFormat[]
build()
Deprecated.Builds an array of media formats that can be used as forMediaBuilder.mandatoryMediaFormats(MediaFormat...)
.
-
-
-
Constructor Detail
-
ResponsiveMediaFormatsBuilder
public ResponsiveMediaFormatsBuilder(@NotNull @NotNull MediaFormat mainMediaFormat)
Deprecated.- Parameters:
mainMediaFormat
- Main media format from which the reponsive "on-the-fly" formats are derived from.
-
-
Method Detail
-
breakpoint
public ResponsiveMediaFormatsBuilder breakpoint(@NotNull @NotNull java.lang.String breakpoint, int width, int height)
Deprecated.Defines one breakpoint for each "on-the-fly" format required.- Parameters:
breakpoint
- Breakpoint name which is set in theMediaNameConstants.PROP_BREAKPOINT
property.width
- Width for the breakpointheight
- Height for the breakpoint- Returns:
- this
-
build
public MediaFormat[] build()
Deprecated.Builds an array of media formats that can be used as forMediaBuilder.mandatoryMediaFormats(MediaFormat...)
.- Returns:
- Array of on-the-fly media formats
-
-