+3rdparty/nuxeo/nuxeo-platform-thumbnail/.classpath
+3rdparty/nuxeo/nuxeo-platform-thumbnail/.project
+3rdparty/nuxeo/nuxeo-platform-thumbnail/.settings/
+logo.miff
target/
*tenant-bindings.merged.xml
.settings/org.eclipse.core.resources.prefs
<module>nuxeo-platform-collectionspace</module>
<module>nuxeo-platform-quote-api</module>
<module>nuxeo-platform-quote</module>
+ <!-- REM : 8/23/2012 - Disabled due to integration and dependency issues between ImageMagick and Ghostscript on Linux machines
<module>nuxeo-platform-thumbnail</module>
+ -->
</modules>
<dependencies>
\r
return result;\r
}\r
+ \r
+ /*\r
+ * Find out if this document's blob/file-contents are allowed to be purged. For instance, we currently\r
+ * only want to allow the purging the contents of Nuxeo "Picture" documents. \r
+ */\r
+ static private boolean isPurgeAllowed(DocumentModel docModel) {\r
+ boolean result = false;\r
+ \r
+ if (docModel.hasFacet(ImagingDocumentConstants.PICTURE_FACET) == true) {\r
+ result = true; // Yes, delete/purge the original content\r
+ }\r
+ \r
+ return result;\r
+ }\r
\r
/**\r
* Creates the image blob.\r
\r
result = createBlobsCommon(documentModel, fileBlob); // Now create our metadata resource document\r
\r
- // If the sender only wanted use to generate derivatives, we need to clear the original content\r
- if (purgeOriginal == true) {\r
+ // If the sender wanted us to generate only derivatives, we need to purge/clear the original contents\r
+ if (purgeOriginal == true && isPurgeAllowed(documentModel) == true) {\r
// Empty the document model's "content" property -this does not delete the actual file/blob\r
documentModel.setPropertyValue("file:content", (Serializable) null);\r
\r