Class ThumbnailRegistry

  • All Implemented Interfaces:
    java.util.EventListener, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.context.event.ApplicationContextEvent>

    @Deprecated
    public class ThumbnailRegistry
    extends java.lang.Object
    implements org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.context.event.ApplicationContextEvent>
    Deprecated.
    The thumbnails code is being moved out of the codebase and replaced by the new async RenditionService2 or other external libraries.
    Registry of all the thumbnail details available
    Author:
    Roy Wetherall, Neil McErlean
    • Field Detail

      • transactionService

        protected TransactionService transactionService
        Deprecated.
        Transaction service
      • renditionService

        protected RenditionService renditionService
        Deprecated.
        Rendition service
    • Constructor Detail

      • ThumbnailRegistry

        public ThumbnailRegistry()
        Deprecated.
    • Method Detail

      • setThumbnailRenditionConvertor

        public void setThumbnailRenditionConvertor​(ThumbnailRenditionConvertor thumbnailRenditionConvertor)
        Deprecated.
      • setContentService

        public void setContentService​(ContentService contentService)
        Deprecated.
        Content service
        Parameters:
        contentService - content service
      • setTransactionService

        public void setTransactionService​(TransactionService transactionService)
        Deprecated.
        Transaction service
        Parameters:
        transactionService - transaction service
      • setRenditionService

        public void setRenditionService​(RenditionService renditionService)
        Deprecated.
        Rendition service
        Parameters:
        renditionService - rendition service
      • setTenantAdminService

        public void setTenantAdminService​(TenantAdminService tenantAdminService)
        Deprecated.
      • setRedeployStaticDefsOnStartup

        public void setRedeployStaticDefsOnStartup​(boolean redeployStaticDefsOnStartup)
        Deprecated.
      • setJobLockService

        public void setJobLockService​(JobLockService jobLockService)
        Deprecated.
      • setTransformServiceRegistry

        public void setTransformServiceRegistry​(TransformServiceRegistry transformServiceRegistry)
        Deprecated.
      • setRenditionDefinitionRegistry2

        public void setRenditionDefinitionRegistry2​(RenditionDefinitionRegistry2 renditionDefinitionRegistry2)
        Deprecated.
      • setThumbnailDefinitions

        public void setThumbnailDefinitions​(java.util.List<ThumbnailDefinition> thumbnailDefinitions)
        Deprecated.
        This method is used to inject the thumbnail definitions.
      • initThumbnailDefinitions

        public void initThumbnailDefinitions()
        Deprecated.
      • getThumbnailDefinitions

        public java.util.List<ThumbnailDefinition> getThumbnailDefinitions()
        Deprecated.
        Get a list of all the thumbnail definitions
        Returns:
        collection of thumbnail definitions
      • getThumbnailDefinitions

        public java.util.List<ThumbnailDefinition> getThumbnailDefinitions​(java.lang.String mimetype)
        Deprecated.
        use overloaded version with sourceSize parameter.
      • getThumbnailDefinitions

        public java.util.List<ThumbnailDefinition> getThumbnailDefinitions​(java.lang.String mimetype,
                                                                           long sourceSize)
        Deprecated.
      • getThumbnailDefinitions

        public java.util.List<ThumbnailDefinition> getThumbnailDefinitions​(java.lang.String sourceUrl,
                                                                           java.lang.String mimetype,
                                                                           long sourceSize)
        Deprecated.
      • isThumbnailDefinitionAvailable

        public boolean isThumbnailDefinitionAvailable​(java.lang.String sourceUrl,
                                                      java.lang.String sourceMimetype,
                                                      long sourceSize,
                                                      org.alfresco.service.cmr.repository.NodeRef sourceNodeRef,
                                                      ThumbnailDefinition thumbnailDefinition)
        Deprecated.
        Checks to see if at this moment in time, the specified ThumbnailDefinition is able to thumbnail the source mimetype. Typically used with Thumbnail Definitions retrieved by name, and/or when dealing with transient ContentTransformers.
        Parameters:
        sourceUrl - The URL of the source (optional)
        sourceMimetype - The source mimetype
        sourceSize - the size (in bytes) of the source. Use -1 if unknown.
        sourceNodeRef - which is set in a copy of the thumbnailDefinition transformation options, so that it may be used by transformers and debug.
        thumbnailDefinition - The ThumbnailDefinition to check for
      • isThumbnailDefinitionAvailable

        public boolean isThumbnailDefinitionAvailable​(java.lang.String sourceUrl,
                                                      java.lang.String sourceMimeType,
                                                      long sourceSize,
                                                      ThumbnailDefinition thumbnailDefinition)
        Deprecated.
        Checks to see if at this moment in time, the specified ThumbnailDefinition is able to thumbnail the source mimetype. Typically used with Thumbnail Definitions retrieved by name, and/or when dealing with transient ContentTransformers.
        Parameters:
        sourceUrl - The URL of the source (optional)
        sourceMimeType - The source mimetype
        sourceSize - the size (in bytes) of the source. Use -1 if unknown.
        thumbnailDefinition - The ThumbnailDefinition to check for
      • getMaxSourceSizeBytes

        public long getMaxSourceSizeBytes​(java.lang.String sourceMimetype,
                                          ThumbnailDefinition thumbnailDefinition)
        Deprecated.
        Returns the maximum source size of any content that may transformed between the supplied sourceMimetype and thumbnailDefinition's targetMimetype using its transformation options.
        Parameters:
        sourceMimetype - String
        thumbnailDefinition - ThumbnailDefinition
        Returns:
        0 if there are no transformers, -1 if there is no limit or if positive the size in bytes.
      • addThumbnailDefinition

        public void addThumbnailDefinition​(ThumbnailDefinition thumbnailDetails)
        Deprecated.
        Add a thumbnail details
        Parameters:
        thumbnailDetails - thumbnail details
      • getThumbnailDefinition

        public ThumbnailDefinition getThumbnailDefinition​(java.lang.String thumbnailName)
        Deprecated.
        Get the definition of a named thumbnail
        Parameters:
        thumbnailName - the thumbnail name
        Returns:
        ThumbnailDetails the details of the thumbnail
      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
                                   throws org.springframework.beans.BeansException
        Deprecated.
        Specified by:
        setApplicationContext in interface org.springframework.context.ApplicationContextAware
        Throws:
        org.springframework.beans.BeansException
      • onApplicationEvent

        public void onApplicationEvent​(org.springframework.context.event.ApplicationContextEvent event)
        Deprecated.
        Specified by:
        onApplicationEvent in interface org.springframework.context.ApplicationListener<org.springframework.context.event.ApplicationContextEvent>
      • redeploy

        protected boolean redeploy()
        Deprecated.