public class VideoProcessorImpl extends DLPreviewableProcessor implements VideoProcessor
DECRYPT_PATH, DECRYPT_TMP_PATH, futures, PREVIEW_PATH, PREVIEW_TMP_PATH, REPOSITORY_ID, THUMBNAIL_INDEX_CUSTOM_1, THUMBNAIL_INDEX_CUSTOM_2, THUMBNAIL_INDEX_DEFAULT, THUMBNAIL_PATH, THUMBNAIL_TMP_PATH, TMP_PATHTHUMBNAIL_TYPE| Constructor and Description |
|---|
VideoProcessorImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
protected void |
doExportGeneratedFiles(PortletDataContext portletDataContext,
FileEntry fileEntry,
Element fileEntryElement) |
protected void |
doImportGeneratedFiles(PortletDataContext portletDataContext,
FileEntry fileEntry,
FileEntry importedFileEntry,
Element fileEntryElement) |
protected void |
exportPreviews(PortletDataContext portletDataContext,
FileEntry fileEntry,
Element fileEntryElement) |
void |
generateVideo(FileVersion sourceFileVersion,
FileVersion destinationFileVersion) |
protected java.util.List<java.lang.Long> |
getFileVersionIds() |
java.io.InputStream |
getPreviewAsStream(FileVersion fileVersion,
java.lang.String type) |
long |
getPreviewFileSize(FileVersion fileVersion,
java.lang.String type) |
protected java.lang.String |
getPreviewType(FileVersion fileVersion) |
protected java.lang.String[] |
getPreviewTypes() |
java.io.InputStream |
getThumbnailAsStream(FileVersion fileVersion,
int index) |
long |
getThumbnailFileSize(FileVersion fileVersion,
int index) |
protected java.lang.String |
getThumbnailType(FileVersion fileVersion) |
java.lang.String |
getType()
Returns the processor's type.
|
java.util.Set<java.lang.String> |
getVideoMimeTypes() |
boolean |
hasVideo(FileVersion fileVersion) |
protected void |
importPreviews(PortletDataContext portletDataContext,
FileEntry fileEntry,
FileEntry importedFileEntry,
Element fileEntryElement) |
boolean |
isSupported(java.lang.String mimeType)
Returns
true if the given file MIME type is supported by
this processor. |
boolean |
isVideoSupported(FileVersion fileVersion) |
boolean |
isVideoSupported(java.lang.String mimeType) |
protected void |
storeThumbnailImages(FileVersion fileVersion,
java.io.File file) |
void |
trigger(FileVersion sourceFileVersion,
FileVersion destinationFileVersion)
Launches the processor's work with respect to the destination file
version.
|
addFileToStore, addFileToStore, cleanUp, cleanUp, copy, copyPreviews, copyThumbnail, copyThumbnails, deleteFiles, deleteFiles, deleteFiles, deleteFiles, deletePreviews, deleteThumbnail, deleteThumbnails, destroyProcess, doGetPreviewAsStream, doGetPreviewAsStream, doGetPreviewFileCount, doGetPreviewFileSize, doGetPreviewFileSize, doGetPreviewFileSize, doGetThumbnailAsStream, doGetThumbnailFileSize, exportBinary, exportGeneratedFiles, exportPreview, exportPreview, exportThumbnail, exportThumbnails, getBinPath, getBinPath, getDecryptedTempFile, getPathSegment, getPathSegment, getPreviewFilePath, getPreviewFilePath, getPreviewFilePath, getPreviewFilePath, getPreviewFilePath, getPreviewFilePath, getPreviewTempFile, getPreviewTempFile, getPreviewTempFile, getPreviewTempFile, getPreviewTempFileCount, getPreviewTempFileCount, getPreviewTempFilePath, getPreviewTempFilePath, getPreviewTempFilePath, getPreviewTempFilePath, getPreviewType, getPreviewType, getThumbnailFilePath, getThumbnailFilePath, getThumbnailFilePath, getThumbnailTempFile, getThumbnailTempFile, getThumbnailTempFilePath, getThumbnailTempFilePath, getThumbnailType, hasPreview, hasPreviews, hasThumbnail, hasThumbnails, importGeneratedFiles, importPreview, importPreview, importPreviewFromLAR, importThumbnail, importThumbnailFromLAR, importThumbnails, isSupported, isThumbnailEnabled, sendGenerationMessage, storeThumbnailImage, storeThumbnailImagesclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitexportGeneratedFiles, importGeneratedFilesdestroypublic void afterPropertiesSet()
afterPropertiesSet in interface DLProcessorpublic void generateVideo(FileVersion sourceFileVersion, FileVersion destinationFileVersion) throws java.lang.Exception
generateVideo in interface VideoProcessorjava.lang.Exceptionpublic java.io.InputStream getPreviewAsStream(FileVersion fileVersion, java.lang.String type) throws java.lang.Exception
getPreviewAsStream in interface VideoProcessorjava.lang.Exceptionpublic long getPreviewFileSize(FileVersion fileVersion, java.lang.String type) throws java.lang.Exception
getPreviewFileSize in interface VideoProcessorjava.lang.Exceptionpublic java.io.InputStream getThumbnailAsStream(FileVersion fileVersion, int index) throws java.lang.Exception
getThumbnailAsStream in interface VideoProcessorjava.lang.Exceptionpublic long getThumbnailFileSize(FileVersion fileVersion, int index) throws java.lang.Exception
getThumbnailFileSize in interface VideoProcessorjava.lang.Exceptionpublic java.lang.String getType()
DLProcessorcom.liferay.portlet.documentlibrary.model.DLProcessorConstants for the
set of predefined processor types.getType in interface DLProcessorpublic java.util.Set<java.lang.String> getVideoMimeTypes()
getVideoMimeTypes in interface VideoProcessorpublic boolean hasVideo(FileVersion fileVersion)
hasVideo in interface VideoProcessorpublic boolean isSupported(java.lang.String mimeType)
DLProcessortrue if the given file MIME type is supported by
this processor.isSupported in interface DLProcessorisSupported in interface VideoProcessormimeType - the MIME typetrue if this processor supports the MIME type;
false otherwisepublic boolean isVideoSupported(FileVersion fileVersion)
isVideoSupported in interface VideoProcessorpublic boolean isVideoSupported(java.lang.String mimeType)
isVideoSupported in interface VideoProcessorpublic void trigger(FileVersion sourceFileVersion, FileVersion destinationFileVersion)
DLProcessortrigger in interface DLProcessortrigger in interface VideoProcessortrigger in class DLPreviewableProcessorsourceFileVersion - the file version to copy previews and thumbnails
from (optionally null)destinationFileVersion - the latest file version to processprotected void doExportGeneratedFiles(PortletDataContext portletDataContext, FileEntry fileEntry, Element fileEntryElement) throws java.lang.Exception
doExportGeneratedFiles in class DLPreviewableProcessorjava.lang.Exceptionprotected void doImportGeneratedFiles(PortletDataContext portletDataContext, FileEntry fileEntry, FileEntry importedFileEntry, Element fileEntryElement) throws java.lang.Exception
doImportGeneratedFiles in class DLPreviewableProcessorjava.lang.Exceptionprotected void exportPreviews(PortletDataContext portletDataContext, FileEntry fileEntry, Element fileEntryElement) throws java.lang.Exception
java.lang.Exceptionprotected java.util.List<java.lang.Long> getFileVersionIds()
getFileVersionIds in class DLPreviewableProcessorprotected java.lang.String getPreviewType(FileVersion fileVersion)
getPreviewType in class DLPreviewableProcessorprotected java.lang.String[] getPreviewTypes()
getPreviewTypes in class DLPreviewableProcessorprotected java.lang.String getThumbnailType(FileVersion fileVersion)
getThumbnailType in class DLPreviewableProcessorprotected void importPreviews(PortletDataContext portletDataContext, FileEntry fileEntry, FileEntry importedFileEntry, Element fileEntryElement) throws java.lang.Exception
java.lang.Exceptionprotected void storeThumbnailImages(FileVersion fileVersion, java.io.File file) throws java.lang.Exception
storeThumbnailImages in class DLPreviewableProcessorjava.lang.Exception