Class RenditionServiceImpl

java.lang.Object
org.alfresco.repo.rendition.RenditionServiceImpl
All Implemented Interfaces:
CheckOutCheckInServicePolicies.BeforeCheckOut, LockServicePolicies.BeforeLock, ClassPolicy, Policy, RenditionDefinitionPersister, RenditionService

Deprecated.
  • Constructor Details

    • RenditionServiceImpl

      public RenditionServiceImpl()
      Deprecated.
  • Method Details

    • setRenditionDefinitionPersister

      public void setRenditionDefinitionPersister(RenditionDefinitionPersister renditionDefinitionPersister)
      Deprecated.
      Injects the RenditionDefinitionPersister bean.
      Parameters:
      renditionDefinitionPersister - RenditionDefinitionPersister
    • setRenditionPreventionRegistry

      public void setRenditionPreventionRegistry(RenditionPreventionRegistry registry)
      Deprecated.
      Since:
      4.0.1
    • setServiceRegistry

      public void setServiceRegistry(ServiceRegistry serviceRegistry)
      Deprecated.
      Injects the ServiceRegistry bean.
      Parameters:
      serviceRegistry - ServiceRegistry
    • setActionService

      public void setActionService(ActionService actionService)
      Deprecated.
      Injects the ActionService bean.
      Parameters:
      actionService - ActionService
    • setActionTrackingService

      public void setActionTrackingService(ActionTrackingService actionTrackingService)
      Deprecated.
      Injects the ActionTrackingService bean.
      Parameters:
      actionTrackingService - ActionTrackingService
    • setDictionaryService

      public void setDictionaryService(DictionaryService dictionaryService)
      Deprecated.
      Injects the DictionaryService bean.
      Parameters:
      dictionaryService - DictionaryService
    • setPolicyComponent

      public void setPolicyComponent(PolicyComponent policyComponent)
      Deprecated.
      Injects the PolicyComponent bean.
      Parameters:
      policyComponent - PolicyComponent
    • setKnownCancellableActionTypes

      public void setKnownCancellableActionTypes(List<String> knownCancellableActionTypes)
      Deprecated.
      Sets the list of known cancellable actions used by cancelRenditions(NodeRef).
      Since:
      4.1.6
    • setRenditionService2

      public void setRenditionService2(RenditionService2Impl renditionService2)
      Deprecated.
    • init

      public void init()
      Deprecated.
    • getRenderingEngineDefinition

      public RenderingEngineDefinition getRenderingEngineDefinition(String name)
      Deprecated.
      Description copied from interface: RenditionService
      Returns the RenderingEngineDefinition associated with the specified rendering engine name.
      Specified by:
      getRenderingEngineDefinition in interface RenditionService
      Parameters:
      name - The rendering engine name.
      Returns:
      The RenderingEngineDefinition or null.
    • getRenderingEngineDefinitions

      public List<RenderingEngineDefinition> getRenderingEngineDefinitions()
      Deprecated.
      Specified by:
      getRenderingEngineDefinitions in interface RenditionService
      Returns:
      A List of all available RenderingEngineDefinition s.
    • createRenditionDefinition

      public RenditionDefinition createRenditionDefinition(QName renditionDefinitionName, String renderingEngineName)
      Deprecated.
      Description copied from interface: RenditionService
      Creates a new RenditionDefinition and sets the rendition name and the rendering engine name to the specified values.
      Specified by:
      createRenditionDefinition in interface RenditionService
      Parameters:
      renditionDefinitionName - A unique identifier used to specify the created RenditionDefinition.
      renderingEngineName - The name of the rendering engine associated with this RenditionDefinition.
      Returns:
      the created RenditionDefinition.
    • createCompositeRenditionDefinition

      public CompositeRenditionDefinition createCompositeRenditionDefinition(QName renditionName)
      Deprecated.
      Description copied from interface: RenditionService
      Creates a new CompositeRenditionDefinition and sets the rendition name and the rendering engine name to the specified values.
      Specified by:
      createCompositeRenditionDefinition in interface RenditionService
      Parameters:
      renditionName - A unique identifier used to specify the created RenditionDefinition.
      Returns:
      the created CompositeRenditionDefinition.
    • render

      public ChildAssociationRef render(NodeRef sourceNode, RenditionDefinition definition)
      Deprecated.
      Description copied from interface: RenditionService
      This method synchronously renders content as specified by the given RenditionDefinition. The content to be rendered is provided by the specified source node.
      Specified by:
      render in interface RenditionService
      Parameters:
      sourceNode - the node from which the content is retrieved.
      definition - this fully specifies the rendition which is to be performed.
      Returns:
      a child association reference which is the link from the source node to the newly rendered content.
    • render

      public void render(NodeRef sourceNode, RenditionDefinition definition, RenderCallback callback)
      Deprecated.
      Description copied from interface: RenditionService
      This method asynchronously renders content as specified by the given RenditionDefinition. The content to be rendered is provided by the specified source node.
      Specified by:
      render in interface RenditionService
      Parameters:
      sourceNode - the node from which the content is retrieved.
      definition - this fully specifies the rendition which is to be performed.
      callback - a callback object to handle the ultimate result of the rendition.
    • render

      public ChildAssociationRef render(NodeRef sourceNode, QName renditionDefinitionQName)
      Deprecated.
      Description copied from interface: RenditionService
      This method synchronously renders content as specified by the given rendition name. The content to be rendered is provided by the specified source node.

      The Rendition Definition will be loaded from the standard location as system thus allowing rendition definitions to be used even when the Data Dictionary has restricted read access.

      Specified by:
      render in interface RenditionService
      Parameters:
      sourceNode - the node from which the content is retrieved.
      renditionDefinitionQName - the rendition definition which is to be performed.
      Returns:
      a child association reference which is the link from the source node to the newly rendered content.
    • render

      public void render(NodeRef sourceNode, QName renditionDefinitionQName, RenderCallback callback)
      Deprecated.
      Description copied from interface: RenditionService
      This method asynchronously renders content as specified by the given rendition definition name. The content to be rendered is provided by the specified source node.

      The Rendition Definition will be loaded from the standard location as system thus allowing rendition definitions to be used even when the Data Dictionary has restricted read access.

      Specified by:
      render in interface RenditionService
      Parameters:
      sourceNode - the node from which the content is retrieved.
      renditionDefinitionQName - the rendition definition which is to be performed.
      callback - a callback object to handle the ultimate result of the rendition.
    • saveRenditionDefinition

      public void saveRenditionDefinition(RenditionDefinition renderingAction)
      Deprecated.
      Description copied from interface: RenditionDefinitionPersister
      This method serializes the RenditionDefinition and stores it in the repository. RenditionDefinitions saved in this way may be retrieved using the load() method.
      Specified by:
      saveRenditionDefinition in interface RenditionDefinitionPersister
      Parameters:
      renderingAction - The RenditionDefinition to be persisted.
    • loadRenditionDefinition

      public RenditionDefinition loadRenditionDefinition(QName renditionDefinitionName)
      Deprecated.
      Description copied from interface: RenditionDefinitionPersister
      This method retrieves a RenditionDefinition that has been stored in the repository using the save() method. If no RenditionDefinition exists in the repository with the specified rendition name then this method returns null.
      Specified by:
      loadRenditionDefinition in interface RenditionDefinitionPersister
      Parameters:
      renditionDefinitionName - The unique identifier used to specify the RenditionDefinition to retrieve.
      Returns:
      The specified RenditionDefinition or null.
    • loadRenditionDefinitions

      public List<RenditionDefinition> loadRenditionDefinitions()
      Deprecated.
      Description copied from interface: RenditionDefinitionPersister
      This method retrieves the RenditionDefinitions that have been stored in the repository using the save() method.

      If there are no such RenditionDefinitions, an empty list is returned.

      Specified by:
      loadRenditionDefinitions in interface RenditionDefinitionPersister
      Returns:
      The RenditionDefinitions.
    • loadRenditionDefinitions

      public List<RenditionDefinition> loadRenditionDefinitions(String renditionEngineName)
      Deprecated.
      Description copied from interface: RenditionDefinitionPersister
      This method retrieves the stored RenditionDefinitions that have been registered for the specified rendering engine name.

      If there are no such rendering RenditionDefinitions, an empty list is returned.

      Specified by:
      loadRenditionDefinitions in interface RenditionDefinitionPersister
      Parameters:
      renditionEngineName - the name of a rendering engine. This is usually the spring bean name.
      Returns:
      The RenditionDefinitions.
      See Also:
    • getRenditions

      public List<ChildAssociationRef> getRenditions(NodeRef node)
      Deprecated.
      Description copied from interface: RenditionService
      This method gets all the renditions of the specified node.
      Specified by:
      getRenditions in interface RenditionService
      Returns:
      a list of ChildAssociationRefs which link the source node to the renditions.
    • getRenditions

      public List<ChildAssociationRef> getRenditions(NodeRef node, String mimeTypePrefix)
      Deprecated.
      Description copied from interface: RenditionService
      This method gets all the renditions of the specified node filtered by MIME-type prefix. Renditions whose MIME-type string startsWith the prefix will be returned.
      Specified by:
      getRenditions in interface RenditionService
      Parameters:
      node - the source node for the renditions
      mimeTypePrefix - a prefix to check against the rendition MIME-types. This must not be null and must not be an empty String
      Returns:
      a list of ChildAssociationRefs which link the source node to the filtered renditions.
    • getRenditionByName

      public ChildAssociationRef getRenditionByName(NodeRef node, QName renditionName)
      Deprecated.
      Description copied from interface: RenditionService
      This method gets the rendition of the specified node identified by the provided rendition name.
      Specified by:
      getRenditionByName in interface RenditionService
      Parameters:
      node - the source node for the renditions
      renditionName - the renditionName used to identify a rendition.
      Returns:
      the ChildAssociationRef which links the source node to the rendition or null if there is no such rendition.
    • isRendition

      public boolean isRendition(NodeRef node)
      Deprecated.
      Description copied from interface: RenditionService
      This method returns true if the specified NodeRef is a valid rendition node, else false. A nodeRef is a rendition node if it has the rn:rendition aspect (or sub-aspect) applied.
      Specified by:
      isRendition in interface RenditionService
      Parameters:
      node - NodeRef
      Returns:
      true if a rendition, else false
    • getSourceNode

      public ChildAssociationRef getSourceNode(NodeRef renditionNode)
      Deprecated.
      Description copied from interface: RenditionService
      This method gets the source node for the specified rendition node. There should only be one source node for any given rendition node.
      Specified by:
      getSourceNode in interface RenditionService
      Parameters:
      renditionNode - the nodeRef holding the rendition.
      Returns:
      the ChildAssociationRef whose parentNodeRef is the source node, or null if there is no source node.
      See Also:
    • cancelRenditions

      public void cancelRenditions(NodeRef sourceNode)
      Deprecated.
      Description copied from interface: RenditionService
      Cancels all known cancellable running renditions for the given NodeRef via the ActionTrackingService.
      Specified by:
      cancelRenditions in interface RenditionService
      Parameters:
      sourceNode - the NodeRef the action is acting on
    • cancelRenditions

      public void cancelRenditions(NodeRef sourceNode, String type)
      Deprecated.
      Description copied from interface: RenditionService
      Cancels all known cancellable running renditions for the given NodeRef and type via the ActionTrackingService.
      Specified by:
      cancelRenditions in interface RenditionService
      Parameters:
      sourceNode - the NodeRef the action is acting on
      type - the rendition type (rending engine name)
    • beforeCheckOut

      public void beforeCheckOut(NodeRef nodeRef, NodeRef destinationParentNodeRef, QName destinationAssocTypeQName, QName destinationAssocQName)
      Deprecated.
      Specified by:
      beforeCheckOut in interface CheckOutCheckInServicePolicies.BeforeCheckOut
      Parameters:
      nodeRef - NodeRef
      destinationParentNodeRef - NodeRef
      destinationAssocTypeQName - QName
      destinationAssocQName - QName
    • beforeLock

      public void beforeLock(NodeRef nodeRef, LockType lockType)
      Deprecated.
      Description copied from interface: LockServicePolicies.BeforeLock
      Called before an attempt to lock the given node is made.
      Specified by:
      beforeLock in interface LockServicePolicies.BeforeLock
      Parameters:
      nodeRef - NodeRef
      lockType - LockType
    • usingRenditionService2

      public boolean usingRenditionService2(NodeRef sourceNodeRef, RenditionDefinition rendDefn)
      Deprecated.
      Description copied from interface: RenditionService
      If a rendition has been created by the newer RenditionService2, this method will return true. In this case the original RenditionService should not be used to update an existing rendition if the content changes. These renditions can be identified by the existence of the rendition2 aspect. RenditionService2 also listens for content changes and will perform the rendition.

      If RenditionService2 has a definition with the same name (matched on the local part of the supplied rendDef's name) and the target mimetype matches, RenditionService2 will also be used. This is being done to help with the conversion of custom transformers and renditions. The basic definitions (called "medium", "doclib", "imgpreview", "avatar", "avatar32", "webpreview", "pdf") already exist. Rather than writing a converter form one definition to the newer one, it is suggested that a newer RenditionDefinition2 is simply defined to avoid having to worry about any complexities in converting TransformationOptions into a simple flat Map structure.
      Specified by:
      usingRenditionService2 in interface RenditionService