Class MediaFormatProvider

  • All Implemented Interfaces:
    io.wcm.sling.commons.caservice.ContextAwareService

    @ConsumerType
    public abstract class MediaFormatProvider
    extends Object
    implements io.wcm.sling.commons.caservice.ContextAwareService
    MediaFormatProvider OSGi services provide media formats for the media handler. Applications can set service properties or bundle headers as defined in ContextAwareService to apply this configuration only for resources that match the relevant resource paths.
    • Constructor Detail

      • MediaFormatProvider

        protected MediaFormatProvider​(Set<MediaFormat> mediaFormats)
        Parameters:
        mediaFormats - Set of media formats for parameter provider
      • MediaFormatProvider

        protected MediaFormatProvider​(Class<?> type)
        Parameters:
        type - Type containing media format definitions as public static fields.
    • Method Detail

      • getMediaFormats

        public Set<MediaFormat> getMediaFormats()
        Returns:
        Media formats that the application defines