Class BasePreviewableDLProcessor

java.lang.Object
com.liferay.document.library.preview.processor.BasePreviewableDLProcessor
All Implemented Interfaces:
com.liferay.document.library.kernel.processor.DLProcessor

public abstract class BasePreviewableDLProcessor extends Object implements com.liferay.document.library.kernel.processor.DLProcessor
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    static final String
     
    protected com.liferay.document.library.kernel.processor.DLProcessorHelper
     
    protected Map<String,Future<?>>
     
    protected com.liferay.portal.kernel.messaging.MessageBus
     
    static final String
     
    static final String
     
    static final long
     
    protected com.liferay.document.library.kernel.store.Store
     
    static final int
     
    static final int
     
    static final int
     
    static final String
     
    static final String
     
    static final String
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    addFileToStore(long companyId, String dirName, String filePath, File srcFile)
     
    protected void
    addFileToStore(long companyId, String dirName, String filePath, InputStream inputStream)
     
    void
    cleanUp(com.liferay.portal.kernel.repository.model.FileEntry fileEntry)
     
    void
    cleanUp(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    void
    copy(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
     
    protected void
    copyPreviews(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
     
    protected void
    copyThumbnail(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion, int index)
     
    protected void
    copyThumbnails(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
     
    protected void
    deleteFiles(long companyId, long groupId, long fileEntryId, long fileVersionId, String thumbnailType)
     
    void
    deleteFiles(com.liferay.portal.kernel.repository.model.FileEntry fileEntry, String thumbnailType)
     
    void
    deleteFiles(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String thumbnailType)
     
    protected void
    deletePreviews(long companyId, long groupId, long fileEntryId, long fileVersionId)
     
    protected void
    deleteThumbnail(long companyId, long groupId, long fileEntryId, long fileVersionId, String thumbnailType, int index)
     
    protected void
    deleteThumbnails(long companyId, long groupId, long fileEntryId, long fileVersionId, String thumbnailType)
     
    protected void
    destroyProcess(String processIdentity)
     
    protected abstract void
    doExportGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement)
     
    protected InputStream
    doGetPreviewAsStream(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index, String type)
     
    protected InputStream
    doGetPreviewAsStream(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
     
    protected int
    doGetPreviewFileCount(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected long
    doGetPreviewFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
     
    protected long
    doGetPreviewFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index, String type)
     
    protected long
    doGetPreviewFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
     
    protected InputStream
    doGetThumbnailAsStream(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
     
    protected long
    doGetThumbnailFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
     
    protected abstract void
    doImportGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement)
     
    protected void
    exportBinary(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.xml.Element fileEntryElement, com.liferay.portal.kernel.repository.model.FileVersion fileVersion, InputStream inputStream, String binPath, String binPathName)
     
    void
    exportGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement)
     
    protected void
    exportPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType)
     
    protected void
    exportPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType, int fileIndex)
     
    protected void
    exportThumbnail(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathName, int index)
     
    protected void
    exportThumbnails(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix)
     
    protected String
    getBinPath(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, int index)
     
    protected String
    getBinPath(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, String type)
     
    protected File
     
    protected abstract List<Long>
     
    protected String
    getPathSegment(long groupId, long fileEntryId, long fileVersionId, boolean preview)
     
    protected String
    getPathSegment(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, boolean preview)
     
    protected String
    getPreviewFilePath(long groupId, long fileEntryId, long fileVersionId, int index, String type)
     
    protected String
    getPreviewFilePath(long groupId, long fileEntryId, long fileVersionId, String type)
     
    protected String
    getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected String
    getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
     
    protected String
    getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index, String type)
     
    protected String
    getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
     
    protected File
     
    protected File
    getPreviewTempFile(String id, int index)
     
    protected File
    getPreviewTempFile(String id, int index, String type)
     
    protected File
     
    protected int
    getPreviewTempFileCount(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected int
    getPreviewTempFileCount(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
     
    protected String
     
    protected String
     
    protected String
    getPreviewTempFilePath(String id, int index, String type)
     
    protected String
     
    protected String
     
    protected String
    getPreviewType(int index)
     
    protected abstract String
    getPreviewType(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected String[]
     
    protected String
    getThumbnailFilePath(long groupId, long fileEntryId, long fileVersionId, String thumbnailType, int index)
     
    protected String
    getThumbnailFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
     
    protected String
    getThumbnailFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type, int index)
     
    protected File
     
    protected File
     
    protected String
     
    protected String
     
    protected String
     
    protected abstract String
    getThumbnailType(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected boolean
    hasPreview(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
     
    protected boolean
    hasPreviews(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected boolean
    hasThumbnail(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
     
    protected boolean
    hasThumbnails(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    void
    importGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement)
     
    protected void
    importPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType)
     
    protected void
    importPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType, int fileIndex)
     
    protected void
    importPreviewFromLAR(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType, int fileIndex)
     
    protected void
    importThumbnail(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathName, int index)
     
    protected void
    importThumbnailFromLAR(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathName, int index)
     
    protected void
    importThumbnails(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix)
     
    boolean
    isSupported(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
     
    protected boolean
    isThumbnailEnabled(int index)
     
    protected void
    sendGenerationMessage(String destinationName, com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
     
    protected void
    storeThumbnailImage(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, RenderedImage renderedImage, int index)
     
    protected void
    storeThumbnailImages(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, RenderedImage renderedImage)
     
    protected void
    storeThumbnailImages(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, File file)
     
    void
    trigger(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.liferay.document.library.kernel.processor.DLProcessor

    getType, isSupported
  • Field Details

    • DECRYPT_PATH

      public static final String DECRYPT_PATH
      See Also:
    • DECRYPT_TMP_PATH

      public static final String DECRYPT_TMP_PATH
    • PREVIEW_PATH

      public static final String PREVIEW_PATH
      See Also:
    • PREVIEW_TMP_PATH

      public static final String PREVIEW_TMP_PATH
    • REPOSITORY_ID

      public static final long REPOSITORY_ID
      See Also:
    • THUMBNAIL_INDEX_CUSTOM_1

      public static final int THUMBNAIL_INDEX_CUSTOM_1
      See Also:
    • THUMBNAIL_INDEX_CUSTOM_2

      public static final int THUMBNAIL_INDEX_CUSTOM_2
      See Also:
    • THUMBNAIL_INDEX_DEFAULT

      public static final int THUMBNAIL_INDEX_DEFAULT
      See Also:
    • THUMBNAIL_PATH

      public static final String THUMBNAIL_PATH
      See Also:
    • THUMBNAIL_TMP_PATH

      public static final String THUMBNAIL_TMP_PATH
    • TMP_PATH

      public static final String TMP_PATH
    • dlProcessorHelper

      protected com.liferay.document.library.kernel.processor.DLProcessorHelper dlProcessorHelper
    • futures

      protected Map<String,Future<?>> futures
    • messageBus

      protected com.liferay.portal.kernel.messaging.MessageBus messageBus
    • store

      protected com.liferay.document.library.kernel.store.Store store
  • Constructor Details

    • BasePreviewableDLProcessor

      public BasePreviewableDLProcessor()
  • Method Details

    • cleanUp

      public void cleanUp(com.liferay.portal.kernel.repository.model.FileEntry fileEntry)
      Specified by:
      cleanUp in interface com.liferay.document.library.kernel.processor.DLProcessor
    • cleanUp

      public void cleanUp(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
      Specified by:
      cleanUp in interface com.liferay.document.library.kernel.processor.DLProcessor
    • copy

      public void copy(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
      Specified by:
      copy in interface com.liferay.document.library.kernel.processor.DLProcessor
    • deleteFiles

      public void deleteFiles(com.liferay.portal.kernel.repository.model.FileEntry fileEntry, String thumbnailType)
    • deleteFiles

      public void deleteFiles(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String thumbnailType)
    • exportGeneratedFiles

      public void exportGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement) throws Exception
      Specified by:
      exportGeneratedFiles in interface com.liferay.document.library.kernel.processor.DLProcessor
      Throws:
      Exception
    • importGeneratedFiles

      public void importGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement) throws Exception
      Specified by:
      importGeneratedFiles in interface com.liferay.document.library.kernel.processor.DLProcessor
      Throws:
      Exception
    • isSupported

      public boolean isSupported(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
      Specified by:
      isSupported in interface com.liferay.document.library.kernel.processor.DLProcessor
    • trigger

      public void trigger(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
      Specified by:
      trigger in interface com.liferay.document.library.kernel.processor.DLProcessor
    • addFileToStore

      protected void addFileToStore(long companyId, String dirName, String filePath, File srcFile) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • addFileToStore

      protected void addFileToStore(long companyId, String dirName, String filePath, InputStream inputStream) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • copyPreviews

      protected void copyPreviews(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
    • copyThumbnail

      protected void copyThumbnail(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion, int index)
    • copyThumbnails

      protected void copyThumbnails(com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
    • deleteFiles

      protected void deleteFiles(long companyId, long groupId, long fileEntryId, long fileVersionId, String thumbnailType)
    • deletePreviews

      protected void deletePreviews(long companyId, long groupId, long fileEntryId, long fileVersionId)
    • deleteThumbnail

      protected void deleteThumbnail(long companyId, long groupId, long fileEntryId, long fileVersionId, String thumbnailType, int index)
    • deleteThumbnails

      protected void deleteThumbnails(long companyId, long groupId, long fileEntryId, long fileVersionId, String thumbnailType)
    • destroyProcess

      protected void destroyProcess(String processIdentity)
    • doExportGeneratedFiles

      protected abstract void doExportGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement) throws Exception
      Throws:
      Exception
    • doGetPreviewAsStream

      protected InputStream doGetPreviewAsStream(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index, String type) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doGetPreviewAsStream

      protected InputStream doGetPreviewAsStream(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doGetPreviewFileCount

      protected int doGetPreviewFileCount(com.liferay.portal.kernel.repository.model.FileVersion fileVersion) throws Exception
      Throws:
      Exception
    • doGetPreviewFileSize

      protected long doGetPreviewFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doGetPreviewFileSize

      protected long doGetPreviewFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index, String type) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doGetPreviewFileSize

      protected long doGetPreviewFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doGetThumbnailAsStream

      protected InputStream doGetThumbnailAsStream(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doGetThumbnailFileSize

      protected long doGetThumbnailFileSize(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • doImportGeneratedFiles

      protected abstract void doImportGeneratedFiles(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement) throws Exception
      Throws:
      Exception
    • exportBinary

      protected void exportBinary(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.xml.Element fileEntryElement, com.liferay.portal.kernel.repository.model.FileVersion fileVersion, InputStream inputStream, String binPath, String binPathName)
    • exportPreview

      protected void exportPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType) throws Exception
      Throws:
      Exception
    • exportPreview

      protected void exportPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType, int fileIndex) throws Exception
      Throws:
      Exception
    • exportThumbnail

      protected void exportThumbnail(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathName, int index) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • exportThumbnails

      protected void exportThumbnails(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • getBinPath

      protected String getBinPath(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, int index)
    • getBinPath

      protected String getBinPath(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, String type)
    • getDecryptedTempFile

      protected File getDecryptedTempFile(String id)
    • getFileVersionIds

      protected abstract List<Long> getFileVersionIds()
    • getPathSegment

      protected String getPathSegment(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, boolean preview)
    • getPathSegment

      protected String getPathSegment(long groupId, long fileEntryId, long fileVersionId, boolean preview)
    • getPreviewFilePath

      protected String getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
    • getPreviewFilePath

      protected String getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
    • getPreviewFilePath

      protected String getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index, String type)
    • getPreviewFilePath

      protected String getPreviewFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
    • getPreviewFilePath

      protected String getPreviewFilePath(long groupId, long fileEntryId, long fileVersionId, int index, String type)
    • getPreviewFilePath

      protected String getPreviewFilePath(long groupId, long fileEntryId, long fileVersionId, String type)
    • getPreviewTempFile

      protected File getPreviewTempFile(String id)
    • getPreviewTempFile

      protected File getPreviewTempFile(String id, int index)
    • getPreviewTempFile

      protected File getPreviewTempFile(String id, int index, String type)
    • getPreviewTempFile

      protected File getPreviewTempFile(String id, String type)
    • getPreviewTempFileCount

      protected int getPreviewTempFileCount(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
    • getPreviewTempFileCount

      protected int getPreviewTempFileCount(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type)
    • getPreviewTempFilePath

      protected String getPreviewTempFilePath(String id)
    • getPreviewTempFilePath

      protected String getPreviewTempFilePath(String id, int index)
    • getPreviewTempFilePath

      protected String getPreviewTempFilePath(String id, int index, String type)
    • getPreviewTempFilePath

      protected String getPreviewTempFilePath(String id, String type)
    • getPreviewType

      protected String getPreviewType()
    • getPreviewType

      protected abstract String getPreviewType(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
    • getPreviewType

      protected String getPreviewType(int index)
    • getPreviewTypes

      protected String[] getPreviewTypes()
    • getThumbnailFilePath

      protected String getThumbnailFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
    • getThumbnailFilePath

      protected String getThumbnailFilePath(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type, int index)
    • getThumbnailFilePath

      protected String getThumbnailFilePath(long groupId, long fileEntryId, long fileVersionId, String thumbnailType, int index)
    • getThumbnailTempFile

      protected File getThumbnailTempFile(String id)
    • getThumbnailTempFile

      protected File getThumbnailTempFile(String id, String type)
    • getThumbnailTempFilePath

      protected String getThumbnailTempFilePath(String id)
    • getThumbnailTempFilePath

      protected String getThumbnailTempFilePath(String id, String type)
    • getThumbnailType

      protected String getThumbnailType()
    • getThumbnailType

      protected abstract String getThumbnailType(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
    • hasPreview

      protected boolean hasPreview(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, String type) throws Exception
      Throws:
      Exception
    • hasPreviews

      protected boolean hasPreviews(com.liferay.portal.kernel.repository.model.FileVersion fileVersion) throws Exception
      Throws:
      Exception
    • hasThumbnail

      protected boolean hasThumbnail(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, int index)
    • hasThumbnails

      protected boolean hasThumbnails(com.liferay.portal.kernel.repository.model.FileVersion fileVersion)
    • importPreview

      protected void importPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType) throws Exception
      Throws:
      Exception
    • importPreview

      protected void importPreview(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType, int fileIndex) throws Exception
      Throws:
      Exception
    • importPreviewFromLAR

      protected void importPreviewFromLAR(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix, String previewType, int fileIndex) throws Exception
      Throws:
      Exception
    • importThumbnail

      protected void importThumbnail(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathName, int index) throws Exception
      Throws:
      Exception
    • importThumbnailFromLAR

      protected void importThumbnailFromLAR(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathName, int index) throws Exception
      Throws:
      Exception
    • importThumbnails

      protected void importThumbnails(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext, com.liferay.portal.kernel.repository.model.FileEntry fileEntry, com.liferay.portal.kernel.repository.model.FileEntry importedFileEntry, com.liferay.portal.kernel.xml.Element fileEntryElement, String binPathSuffix) throws Exception
      Throws:
      Exception
    • isThumbnailEnabled

      protected boolean isThumbnailEnabled(int index)
    • sendGenerationMessage

      protected void sendGenerationMessage(String destinationName, com.liferay.portal.kernel.repository.model.FileVersion sourceFileVersion, com.liferay.portal.kernel.repository.model.FileVersion destinationFileVersion)
    • storeThumbnailImage

      protected void storeThumbnailImage(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, RenderedImage renderedImage, int index) throws Exception
      Throws:
      Exception
    • storeThumbnailImages

      protected void storeThumbnailImages(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, File file) throws Exception
      Throws:
      Exception
    • storeThumbnailImages

      protected void storeThumbnailImages(com.liferay.portal.kernel.repository.model.FileVersion fileVersion, RenderedImage renderedImage) throws Exception
      Throws:
      Exception