public interface RenditionService
Modifier and Type | Method and Description |
---|---|
void |
deleteStoredRenditions(String repositoryName)
Query and delete stored renditions where the related version or live document does not exist anymore.
|
List<RenditionDefinition> |
getAvailableRenditionDefinitions(DocumentModel doc)
Returns a
List of RenditionDefinition available on the given Document. |
List<Rendition> |
getAvailableRenditions(DocumentModel doc)
Returns a
List of Rendition available on the given Document. |
List<Rendition> |
getAvailableRenditions(DocumentModel doc,
boolean onlyVisible)
Returns a
List of Rendition available on the given Document. |
List<RenditionDefinition> |
getDeclaredRenditionDefinitions()
Deprecated.
since 7.2 because unused
|
List<RenditionDefinition> |
getDeclaredRenditionDefinitionsForProviderType(String providerType)
Deprecated.
since 7.2 because unused
|
Rendition |
getDefaultRendition(DocumentModel doc,
String reason,
Map<String,Serializable> extendedInfos)
Return the default
Rendition object for the given DocumentModel . |
Rendition |
getRendition(DocumentModel doc,
String renditionName)
Return the
Rendition object for the given DocumentModel and a rendition definition name. |
Rendition |
getRendition(DocumentModel doc,
String renditionName,
boolean store)
Return the
Rendition object for the given DocumentModel and a rendition definition name. |
DocumentRef |
storeRendition(DocumentModel sourceDocument,
String renditionDefinitionName)
Render a document based on the given rendition definition name and returns the stored Rendition
DocumentRef . |
@Deprecated List<RenditionDefinition> getDeclaredRenditionDefinitions()
List
of registered RenditionDefinition
. The order of the List does not depend on the
registering order.@Deprecated List<RenditionDefinition> getDeclaredRenditionDefinitionsForProviderType(String providerType)
List
of registered RenditionDefinition
matching a given provider typeList<RenditionDefinition> getAvailableRenditionDefinitions(DocumentModel doc)
List
of RenditionDefinition
available on the given Document. The order of the List does
not depend on the registering order.DocumentRef storeRendition(DocumentModel sourceDocument, String renditionDefinitionName)
DocumentRef
.
Only the user launching the render operation has the Read right on the returned document.
sourceDocument
- the document to renderrenditionDefinitionName
- the rendition definition to useDocumentRef
of the newly created Rendition document.Rendition getRendition(DocumentModel doc, String renditionName)
Rendition
object for the given DocumentModel
and a rendition definition name.
A stored rendition is returned if found and up to date, a new Rendition is created otherwise.
doc
- the document to renderrenditionName
- the name of the rendition definitionRendition
objectRendition getDefaultRendition(DocumentModel doc, String reason, Map<String,Serializable> extendedInfos)
Rendition
object for the given DocumentModel
.
A stored rendition is returned if found and up to date, a new Rendition is created otherwise.
doc
- the document to renderreason
- the reason the rendition is being rendered (optional)extendedInfos
- map of extended info added in the default rendition computation (optional)Rendition
objectRendition getRendition(DocumentModel doc, String renditionName, boolean store)
Rendition
object for the given DocumentModel
and a rendition definition name.
A stored rendition is returned if found and up to date, a new (live) Rendition is created otherwise.
If store parameter is true, the new created rendition is stored too and returned
doc
- the document to renderrenditionName
- the name of the rendition definitionstore
- indicates if the rendition must be storedRendition
objectList<Rendition> getAvailableRenditions(DocumentModel doc)
List
of Rendition
available on the given Document.
The order of the List does not depend on the registering order.
The returned rendition may be live or stored
List<Rendition> getAvailableRenditions(DocumentModel doc, boolean onlyVisible)
List
of Rendition
available on the given Document.
If onlyVisible
is true, returns only the rendition marked as visible.
The order of the List does not depend on the registering order.
The returned rendition may be live or stored
void deleteStoredRenditions(String repositoryName)
Copyright © 2018 Nuxeo. All rights reserved.