Class AbstractLazyCachableRenditionProvider
java.lang.Object
org.nuxeo.ecm.platform.rendition.extension.DefaultAutomationRenditionProvider
org.nuxeo.ecm.platform.rendition.lazy.AbstractLazyCachableRenditionProvider
- All Implemented Interfaces:
RenditionProvider
- Direct Known Subclasses:
AutomationLazyRenditionProvider
public abstract class AbstractLazyCachableRenditionProvider
extends DefaultAutomationRenditionProvider
Default implementation of an asynchronous
RenditionProvider
- Since:
- 7.2
- Author:
- Tiry
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
protected static org.apache.logging.log4j.Logger
static final String
Fields inherited from class org.nuxeo.ecm.platform.rendition.extension.DefaultAutomationRenditionProvider
VARIANT_POLICY_USER
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
getBlobInfo
(List<Blob> blobs) protected String
protected abstract Work
getRenditionWork
(String key, DocumentModel doc, RenditionDefinition def) getSourceDocumentModificationDate
(DocumentModel doc, RenditionDefinition definition) protected TransientStore
protected void
handleCompletedRendition
(String key, DocumentModel doc, RenditionDefinition definition, String sourceDocumentModificationDate, String tsSourceDocumentModificationDate, List<Blob> blobs) protected void
handleIncompleteRendition
(String key, DocumentModel doc, RenditionDefinition definition, String sourceDocumentModificationDate, String tsSourceDocumentModificationDate) handleNewRendition
(String key, DocumentModel doc, RenditionDefinition definition, String sourceDocumentModificationDate) render
(DocumentModel doc, RenditionDefinition definition) Generate the rendition Blobs for a givenRenditionDefinition
.protected String
toHexString
(byte[] data) Methods inherited from class org.nuxeo.ecm.platform.rendition.extension.DefaultAutomationRenditionProvider
getVariant, isAvailable
-
Field Details
-
SOURCE_DOCUMENT_MODIFICATION_DATE_KEY
- See Also:
-
CACHE_NAME
- See Also:
-
log
protected static org.apache.logging.log4j.Logger log
-
-
Constructor Details
-
AbstractLazyCachableRenditionProvider
public AbstractLazyCachableRenditionProvider()
-
-
Method Details
-
render
Description copied from interface:RenditionProvider
Generate the rendition Blobs for a givenRenditionDefinition
. Return is a List of Blob for bigger flexibility (typically HTML rendition with resources)- Specified by:
render
in interfaceRenditionProvider
- Overrides:
render
in classDefaultAutomationRenditionProvider
- Parameters:
doc
- the targetDocumentModel
definition
- theRenditionDefinition
to use- Returns:
- The list of Blobs
-
getBlobInfo
- Since:
- 11.1
-
buildRenditionKey
-
getSourceDocumentModificationDate
-
getDigest
-
toHexString
-
getTransientStore
-
handleNewRendition
protected List<Blob> handleNewRendition(String key, DocumentModel doc, RenditionDefinition definition, String sourceDocumentModificationDate) -
handleCompletedRendition
protected void handleCompletedRendition(String key, DocumentModel doc, RenditionDefinition definition, String sourceDocumentModificationDate, String tsSourceDocumentModificationDate, List<Blob> blobs) -
handleIncompleteRendition
protected void handleIncompleteRendition(String key, DocumentModel doc, RenditionDefinition definition, String sourceDocumentModificationDate, String tsSourceDocumentModificationDate) -
getRenditionWork
Return theWork
that will compute theRendition
.AbstractRenditionBuilderWork
can be used as a base class- Parameters:
key
- the key used to renditiondoc
- the targetDocumentModel
def
- theRenditionDefinition
-