Liferay 7.0-ce-b4

com.liferay.portlet.documentlibrary.service.impl
Class DLFileEntryLocalServiceImpl

java.lang.Object
  extended by com.liferay.portal.service.BaseLocalServiceImpl
      extended by com.liferay.portlet.documentlibrary.service.base.DLFileEntryLocalServiceBaseImpl
          extended by com.liferay.portlet.documentlibrary.service.impl.DLFileEntryLocalServiceImpl
All Implemented Interfaces:
IdentifiableOSGiService, BaseLocalService, PersistedModelLocalService, DLFileEntryLocalService

public class DLFileEntryLocalServiceImpl
extends DLFileEntryLocalServiceBaseImpl

Provides the local service for accessing, adding, checking in/out, deleting, locking/unlocking, moving, reverting, updating, and verifying document library file entries.

Due to legacy code, the names of some file entry properties are not intuitive. Each file entry has both a name and title. The name is a unique identifier for a given file and is generally numeric, whereas the title is the actual name specified by the user (such as "Budget.xls").


Field Summary
 
Fields inherited from class com.liferay.portlet.documentlibrary.service.base.DLFileEntryLocalServiceBaseImpl
assetCategoryFinder, assetCategoryLocalService, assetCategoryPersistence, assetEntryFinder, assetEntryLocalService, assetEntryPersistence, assetLinkLocalService, assetLinkPersistence, assetTagFinder, assetTagLocalService, assetTagPersistence, classNameLocalService, classNamePersistence, counterLocalService, dlAppHelperLocalService, dlFileEntryFinder, dlFileEntryLocalService, dlFileEntryMetadataFinder, dlFileEntryMetadataLocalService, dlFileEntryMetadataPersistence, dlFileEntryPersistence, dlFileEntryTypeFinder, dlFileEntryTypeLocalService, dlFileEntryTypePersistence, dlFileVersionLocalService, dlFileVersionPersistence, dlFolderFinder, dlFolderLocalService, dlFolderPersistence, expandoRowLocalService, expandoRowPersistence, expandoTableLocalService, expandoTablePersistence, groupFinder, groupLocalService, groupPersistence, imageLocalService, imagePersistence, persistedModelLocalServiceRegistry, ratingsStatsFinder, ratingsStatsLocalService, ratingsStatsPersistence, repositoryLocalService, repositoryPersistence, resourceLocalService, trashEntryLocalService, trashEntryPersistence, userFinder, userLocalService, userPersistence, webDAVPropsLocalService, webDAVPropsPersistence, workflowInstanceLinkLocalService, workflowInstanceLinkPersistence
 
Constructor Summary
DLFileEntryLocalServiceImpl()
           
 
Method Summary
 DLFileEntry addFileEntry(long userId, long groupId, long repositoryId, long folderId, String sourceFileName, String mimeType, String title, String description, String changeLog, long fileEntryTypeId, Map<String,DDMFormValues> ddmFormValuesMap, File file, InputStream is, long size, ServiceContext serviceContext)
           
protected  DLFileVersion addFileVersion(User user, DLFileEntry dlFileEntry, String fileName, String extension, String mimeType, String title, String description, String changeLog, String extraSettings, long fileEntryTypeId, Map<String,DDMFormValues> ddmFormValuesMap, String version, long size, int status, ServiceContext serviceContext)
           
 DLFileVersion cancelCheckOut(long userId, long fileEntryId)
           
 void checkInFileEntry(long userId, long fileEntryId, boolean majorVersion, String changeLog, ServiceContext serviceContext)
           
 void checkInFileEntry(long userId, long fileEntryId, String lockUuid)
          Deprecated. As of 6.2.0, replaced by checkInFileEntry(long, long, String, ServiceContext)
 void checkInFileEntry(long userId, long fileEntryId, String lockUuid, ServiceContext serviceContext)
           
 DLFileEntry checkOutFileEntry(long userId, long fileEntryId)
          Deprecated. As of 6.2.0, replaced by checkOutFileEntry(long, long, ServiceContext)
 DLFileEntry checkOutFileEntry(long userId, long fileEntryId, ServiceContext serviceContext)
           
 DLFileEntry checkOutFileEntry(long userId, long fileEntryId, String owner, long expirationTime)
          Deprecated. As of 6.2.0, replaced by checkOutFileEntry(long, long, String, long, ServiceContext)
 DLFileEntry checkOutFileEntry(long userId, long fileEntryId, String owner, long expirationTime, ServiceContext serviceContext)
           
protected  void convertExtraSettings(DLFileEntry dlFileEntry, DLFileVersion dlFileVersion, String[] keys)
           
protected  void convertExtraSettings(DLFileEntry dlFileEntry, String[] keys)
           
 void convertExtraSettings(String[] keys)
           
protected  void convertExtraSettings(UnicodeProperties extraSettingsProperties, ExpandoBridge expandoBridge, String[] keys)
           
protected  void copyExpandoRowModifiedDate(long companyId, long sourceFileVersionId, long destinationFileVersionId)
           
 DLFileEntry copyFileEntry(long userId, long groupId, long repositoryId, long fileEntryId, long destFolderId, ServiceContext serviceContext)
           
 void copyFileEntryMetadata(long companyId, long fileEntryTypeId, long fileEntryId, long fromFileVersionId, long toFileVersionId, ServiceContext serviceContext)
           
protected  void copyFileEntryMetadata(long companyId, long fileEntryId, long fromFileVersionId, long toFileVersionId, ServiceContext serviceContext, Map<String,DDMFormValues> ddmFormValuesMap, List<DDMStructure> ddmStructures)
           
 void deleteFileEntries(long groupId, long folderId)
           
 void deleteFileEntries(long groupId, long folderId, boolean includeTrashedEntries)
           
 DLFileEntry deleteFileEntry(DLFileEntry dlFileEntry)
           
 DLFileEntry deleteFileEntry(long fileEntryId)
           
 DLFileEntry deleteFileEntry(long userId, long fileEntryId)
           
 DLFileEntry deleteFileVersion(long userId, long fileEntryId, String version)
           
 void deleteRepositoryFileEntries(long repositoryId, long folderId)
           
 void deleteRepositoryFileEntries(long repositoryId, long folderId, boolean includeTrashedEntries)
           
 DLFileEntry fetchFileEntry(long groupId, long folderId, String title)
           
 DLFileEntry fetchFileEntryByAnyImageId(long imageId)
           
 DLFileEntry fetchFileEntryByFileName(long groupId, long folderId, String fileName)
           
 DLFileEntry fetchFileEntryByName(long groupId, long folderId, String name)
           
 List<DLFileEntry> getDDMStructureFileEntries(long[] ddmStructureIds)
           
 List<DLFileEntry> getDDMStructureFileEntries(long groupId, long[] ddmStructureIds)
           
 List<DLFileEntry> getExtraSettingsFileEntries(int start, int end)
           
 int getExtraSettingsFileEntriesCount()
           
 File getFile(long userId, long fileEntryId, String version, boolean incrementCounter)
          Deprecated. As of 7.0.0, replaced by getFile(long, String, boolean)
 File getFile(long userId, long fileEntryId, String version, boolean incrementCounter, int increment)
          Deprecated. As of 7.0.0, replaced by getFile(long, String, boolean, int)
 File getFile(long fileEntryId, String version, boolean incrementCounter)
           
 File getFile(long fileEntryId, String version, boolean incrementCounter, int increment)
           
 InputStream getFileAsStream(long userId, long fileEntryId, String version)
          Deprecated. As of 7.0.0, replaced by getFileAsStream(long, String)
 InputStream getFileAsStream(long userId, long fileEntryId, String version, boolean incrementCounter)
          Deprecated. As of 7.0.0, replaced by getFileAsStream(long, String, boolean)
 InputStream getFileAsStream(long userId, long fileEntryId, String version, boolean incrementCounter, int increment)
          Deprecated. As of 7.0.0, replaced by getFileAsStream(long, String, boolean, int)
 InputStream getFileAsStream(long fileEntryId, String version)
           
 InputStream getFileAsStream(long fileEntryId, String version, boolean incrementCounter)
           
 InputStream getFileAsStream(long fileEntryId, String version, boolean incrementCounter, int increment)
           
 List<DLFileEntry> getFileEntries(int start, int end)
           
 List<DLFileEntry> getFileEntries(long groupId, long folderId)
           
 List<DLFileEntry> getFileEntries(long groupId, long folderId, int status, int start, int end, OrderByComparator<DLFileEntry> obc)
           
 List<DLFileEntry> getFileEntries(long groupId, long folderId, int start, int end, OrderByComparator<DLFileEntry> obc)
           
 List<DLFileEntry> getFileEntries(long groupId, long userId, List<Long> repositoryIds, List<Long> folderIds, String[] mimeTypes, QueryDefinition<DLFileEntry> queryDefinition)
           
 List<DLFileEntry> getFileEntries(long groupId, long userId, List<Long> folderIds, String[] mimeTypes, QueryDefinition<DLFileEntry> queryDefinition)
           
 List<DLFileEntry> getFileEntries(long folderId, String name)
           
 int getFileEntriesCount()
           
 int getFileEntriesCount(long groupId, DateRange dateRange, long repositoryId, QueryDefinition<DLFileEntry> queryDefinition)
          Deprecated. As of 7.0.0, with no direct replacement
 int getFileEntriesCount(long groupId, long folderId)
           
 int getFileEntriesCount(long groupId, long folderId, int status)
           
 int getFileEntriesCount(long groupId, long userId, List<Long> repositoryIds, List<Long> folderIds, String[] mimeTypes, QueryDefinition<DLFileEntry> queryDefinition)
           
 int getFileEntriesCount(long groupId, long userId, List<Long> folderIds, String[] mimeTypes, QueryDefinition<DLFileEntry> queryDefinition)
           
 DLFileEntry getFileEntry(long fileEntryId)
           
 DLFileEntry getFileEntry(long groupId, long folderId, String title)
           
 DLFileEntry getFileEntryByName(long groupId, long folderId, String name)
           
 DLFileEntry getFileEntryByUuidAndGroupId(String uuid, long groupId)
           
protected  RepositoryEventTrigger getFolderRepositoryEventTrigger(long groupId, long folderId)
           
 List<DLFileEntry> getGroupFileEntries(long groupId, int start, int end)
           
 List<DLFileEntry> getGroupFileEntries(long groupId, int start, int end, OrderByComparator<DLFileEntry> obc)
           
 List<DLFileEntry> getGroupFileEntries(long groupId, long userId, int start, int end)
           
 List<DLFileEntry> getGroupFileEntries(long groupId, long userId, int start, int end, OrderByComparator<DLFileEntry> obc)
           
 List<DLFileEntry> getGroupFileEntries(long groupId, long userId, long rootFolderId, int start, int end, OrderByComparator<DLFileEntry> obc)
           
 List<DLFileEntry> getGroupFileEntries(long groupId, long userId, long repositoryId, long rootFolderId, int start, int end, OrderByComparator<DLFileEntry> obc)
           
 int getGroupFileEntriesCount(long groupId)
           
 int getGroupFileEntriesCount(long groupId, long userId)
           
 List<DLFileEntry> getMisversionedFileEntries()
           
protected  String getNextVersion(DLFileEntry dlFileEntry, boolean majorVersion, int workflowAction)
           
 List<DLFileEntry> getNoAssetFileEntries()
           
 List<DLFileEntry> getOrphanedFileEntries()
           
 List<DLFileEntry> getRepositoryFileEntries(long repositoryId, int start, int end)
           
 int getRepositoryFileEntriesCount(long repositoryId)
           
 String getUniqueTitle(long groupId, long folderId, long fileEntryId, String title, String extension)
           
 boolean hasExtraSettings()
           
 boolean hasFileEntryLock(long userId, long fileEntryId)
           
 void incrementViewCounter(DLFileEntry dlFileEntry, int increment)
           
 boolean isFileEntryCheckedOut(long fileEntryId)
           
protected  boolean isKeepFileVersionLabel(DLFileEntry dlFileEntry, DLFileVersion lastDLFileVersion, DLFileVersion latestDLFileVersion, ServiceContext serviceContext)
           
 boolean isKeepFileVersionLabel(long fileEntryId, ServiceContext serviceContext)
           
 Lock lockFileEntry(long userId, long fileEntryId)
           
 DLFileEntry moveFileEntry(long userId, long fileEntryId, long newFolderId, ServiceContext serviceContext)
           
protected  DLFileEntry moveFileEntryImpl(long userId, long fileEntryId, long newFolderId, ServiceContext serviceContext)
           
 void rebuildTree(long companyId)
           
protected  void reindex(DLFileEntry dlFileEntry)
           
protected  void removeFileVersion(DLFileEntry dlFileEntry, DLFileVersion dlFileVersion)
           
 void revertFileEntry(long userId, long fileEntryId, String version, ServiceContext serviceContext)
           
 Hits search(long groupId, long userId, long creatorUserId, int status, int start, int end)
           
 Hits search(long groupId, long userId, long creatorUserId, long folderId, String[] mimeTypes, int status, int start, int end)
           
 void setTreePaths(long folderId, String treePath, boolean reindex)
           
 void unlockFileEntry(long fileEntryId)
           
 DLFileEntry updateFileEntry(long userId, long fileEntryId, String sourceFileName, String mimeType, String title, String description, String changeLog, boolean majorVersion, long fileEntryTypeId, Map<String,DDMFormValues> ddmFormValuesMap, File file, InputStream is, long size, ServiceContext serviceContext)
           
protected  DLFileEntry updateFileEntry(long userId, long fileEntryId, String sourceFileName, String extension, String mimeType, String title, String description, String changeLog, boolean majorVersion, String extraSettings, long fileEntryTypeId, Map<String,DDMFormValues> ddmFormValuesMap, File file, InputStream is, long size, ServiceContext serviceContext)
           
 DLFileEntry updateFileEntryType(long userId, long fileEntryId, long fileEntryTypeId, ServiceContext serviceContext)
           
protected  DLFileVersion updateFileVersion(User user, DLFileVersion dlFileVersion, String sourceFileName, String fileName, String extension, String mimeType, String title, String description, String changeLog, String extraSettings, long fileEntryTypeId, Map<String,DDMFormValues> ddmFormValuesMap, String version, long size, int status, Date statusDate, ServiceContext serviceContext)
           
 void updateSmallImage(long smallImageId, long largeImageId)
           
 DLFileEntry updateStatus(long userId, long fileVersionId, int status, ServiceContext serviceContext, Map<String,Serializable> workflowContext)
           
 void validateFile(long groupId, long folderId, long fileEntryId, String fileName, String title)
           
protected  void validateFile(long groupId, long folderId, long fileEntryId, String sourceFileName, String fileName, String extension, String title)
           
protected  void validateFileEntryTypeId(long[] groupIds, long folderId, long fileEntryTypeId)
           
protected  void validateFileExtension(String extension)
           
 boolean verifyFileEntryCheckOut(long fileEntryId, String lockUuid)
           
 boolean verifyFileEntryLock(long fileEntryId, String lockUuid)
           
 
Methods inherited from class com.liferay.portlet.documentlibrary.service.base.DLFileEntryLocalServiceBaseImpl
addDLFileEntry, afterPropertiesSet, createDLFileEntry, deleteDLFileEntry, deleteDLFileEntry, deletePersistedModel, destroy, dynamicQuery, dynamicQuery, dynamicQuery, dynamicQuery, dynamicQueryCount, dynamicQueryCount, fetchDLFileEntry, fetchDLFileEntryByUuidAndGroupId, getActionableDynamicQuery, getAssetCategoryFinder, getAssetCategoryLocalService, getAssetCategoryPersistence, getAssetEntryFinder, getAssetEntryLocalService, getAssetEntryPersistence, getAssetLinkLocalService, getAssetLinkPersistence, getAssetTagFinder, getAssetTagLocalService, getAssetTagPersistence, getClassNameLocalService, getClassNamePersistence, getCounterLocalService, getDLAppHelperLocalService, getDLFileEntries, getDLFileEntriesByUuidAndCompanyId, getDLFileEntriesByUuidAndCompanyId, getDLFileEntriesCount, getDLFileEntry, getDLFileEntryByUuidAndGroupId, getDLFileEntryFinder, getDLFileEntryLocalService, getDLFileEntryMetadataFinder, getDLFileEntryMetadataLocalService, getDLFileEntryMetadataPersistence, getDLFileEntryPersistence, getDLFileEntryTypeFinder, getDLFileEntryTypeLocalService, getDLFileEntryTypePersistence, getDLFileVersionLocalService, getDLFileVersionPersistence, getDLFolderFinder, getDLFolderLocalService, getDLFolderPersistence, getExpandoRowLocalService, getExpandoRowPersistence, getExpandoTableLocalService, getExpandoTablePersistence, getExportActionableDynamicQuery, getGroupFinder, getGroupLocalService, getGroupPersistence, getImageLocalService, getImagePersistence, getIndexableActionableDynamicQuery, getModelClass, getModelClassName, getOSGiServiceIdentifier, getPersistedModel, getRatingsStatsFinder, getRatingsStatsLocalService, getRatingsStatsPersistence, getRepositoryLocalService, getRepositoryPersistence, getResourceLocalService, getTrashEntryLocalService, getTrashEntryPersistence, getUserFinder, getUserLocalService, getUserPersistence, getWebDAVPropsLocalService, getWebDAVPropsPersistence, getWorkflowInstanceLinkLocalService, getWorkflowInstanceLinkPersistence, initActionableDynamicQuery, runSQL, setAssetCategoryFinder, setAssetCategoryLocalService, setAssetCategoryPersistence, setAssetEntryFinder, setAssetEntryLocalService, setAssetEntryPersistence, setAssetLinkLocalService, setAssetLinkPersistence, setAssetTagFinder, setAssetTagLocalService, setAssetTagPersistence, setClassNameLocalService, setClassNamePersistence, setCounterLocalService, setDLAppHelperLocalService, setDLFileEntryFinder, setDLFileEntryLocalService, setDLFileEntryMetadataFinder, setDLFileEntryMetadataLocalService, setDLFileEntryMetadataPersistence, setDLFileEntryPersistence, setDLFileEntryTypeFinder, setDLFileEntryTypeLocalService, setDLFileEntryTypePersistence, setDLFileVersionLocalService, setDLFileVersionPersistence, setDLFolderFinder, setDLFolderLocalService, setDLFolderPersistence, setExpandoRowLocalService, setExpandoRowPersistence, setExpandoTableLocalService, setExpandoTablePersistence, setGroupFinder, setGroupLocalService, setGroupPersistence, setImageLocalService, setImagePersistence, setRatingsStatsFinder, setRatingsStatsLocalService, setRatingsStatsPersistence, setRepositoryLocalService, setRepositoryPersistence, setResourceLocalService, setTrashEntryLocalService, setTrashEntryPersistence, setUserFinder, setUserLocalService, setUserPersistence, setWebDAVPropsLocalService, setWebDAVPropsPersistence, setWorkflowInstanceLinkLocalService, setWorkflowInstanceLinkPersistence, updateDLFileEntry
 
Methods inherited from class com.liferay.portal.service.BaseLocalServiceImpl
getClassLoader, getLocalizationMap
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DLFileEntryLocalServiceImpl

public DLFileEntryLocalServiceImpl()
Method Detail

addFileEntry

public DLFileEntry addFileEntry(long userId,
                                long groupId,
                                long repositoryId,
                                long folderId,
                                String sourceFileName,
                                String mimeType,
                                String title,
                                String description,
                                String changeLog,
                                long fileEntryTypeId,
                                Map<String,DDMFormValues> ddmFormValuesMap,
                                File file,
                                InputStream is,
                                long size,
                                ServiceContext serviceContext)
                         throws PortalException
Throws:
PortalException

cancelCheckOut

public DLFileVersion cancelCheckOut(long userId,
                                    long fileEntryId)
                             throws PortalException
Throws:
PortalException

checkInFileEntry

public void checkInFileEntry(long userId,
                             long fileEntryId,
                             boolean majorVersion,
                             String changeLog,
                             ServiceContext serviceContext)
                      throws PortalException
Throws:
PortalException

checkInFileEntry

@Deprecated
public void checkInFileEntry(long userId,
                                        long fileEntryId,
                                        String lockUuid)
                      throws PortalException
Deprecated. As of 6.2.0, replaced by checkInFileEntry(long, long, String, ServiceContext)

Throws:
PortalException

checkInFileEntry

public void checkInFileEntry(long userId,
                             long fileEntryId,
                             String lockUuid,
                             ServiceContext serviceContext)
                      throws PortalException
Throws:
PortalException

checkOutFileEntry

@Deprecated
public DLFileEntry checkOutFileEntry(long userId,
                                                long fileEntryId)
                              throws PortalException
Deprecated. As of 6.2.0, replaced by checkOutFileEntry(long, long, ServiceContext)

Throws:
PortalException

checkOutFileEntry

public DLFileEntry checkOutFileEntry(long userId,
                                     long fileEntryId,
                                     ServiceContext serviceContext)
                              throws PortalException
Throws:
PortalException

checkOutFileEntry

@Deprecated
public DLFileEntry checkOutFileEntry(long userId,
                                                long fileEntryId,
                                                String owner,
                                                long expirationTime)
                              throws PortalException
Deprecated. As of 6.2.0, replaced by checkOutFileEntry(long, long, String, long, ServiceContext)

Throws:
PortalException

checkOutFileEntry

public DLFileEntry checkOutFileEntry(long userId,
                                     long fileEntryId,
                                     String owner,
                                     long expirationTime,
                                     ServiceContext serviceContext)
                              throws PortalException
Throws:
PortalException

convertExtraSettings

public void convertExtraSettings(String[] keys)
                          throws PortalException
Throws:
PortalException

copyFileEntry

public DLFileEntry copyFileEntry(long userId,
                                 long groupId,
                                 long repositoryId,
                                 long fileEntryId,
                                 long destFolderId,
                                 ServiceContext serviceContext)
                          throws PortalException
Throws:
PortalException

copyFileEntryMetadata

public void copyFileEntryMetadata(long companyId,
                                  long fileEntryTypeId,
                                  long fileEntryId,
                                  long fromFileVersionId,
                                  long toFileVersionId,
                                  ServiceContext serviceContext)
                           throws PortalException
Throws:
PortalException

deleteFileEntries

public void deleteFileEntries(long groupId,
                              long folderId)
                       throws PortalException
Throws:
PortalException

deleteFileEntries

public void deleteFileEntries(long groupId,
                              long folderId,
                              boolean includeTrashedEntries)
                       throws PortalException
Throws:
PortalException

deleteFileEntry

@Indexable(type=DELETE)
@SystemEvent(action=1,
             type=1)
public DLFileEntry deleteFileEntry(DLFileEntry dlFileEntry)
                            throws PortalException
Throws:
PortalException

deleteFileEntry

@Indexable(type=DELETE)
public DLFileEntry deleteFileEntry(long fileEntryId)
                            throws PortalException
Throws:
PortalException

deleteFileEntry

@Indexable(type=DELETE)
public DLFileEntry deleteFileEntry(long userId,
                                                       long fileEntryId)
                            throws PortalException
Throws:
PortalException

deleteFileVersion

@Indexable(type=REINDEX)
public DLFileEntry deleteFileVersion(long userId,
                                                          long fileEntryId,
                                                          String version)
                              throws PortalException
Throws:
PortalException

deleteRepositoryFileEntries

public void deleteRepositoryFileEntries(long repositoryId,
                                        long folderId)
                                 throws PortalException
Throws:
PortalException

deleteRepositoryFileEntries

public void deleteRepositoryFileEntries(long repositoryId,
                                        long folderId,
                                        boolean includeTrashedEntries)
                                 throws PortalException
Throws:
PortalException

fetchFileEntry

public DLFileEntry fetchFileEntry(long groupId,
                                  long folderId,
                                  String title)

fetchFileEntryByAnyImageId

public DLFileEntry fetchFileEntryByAnyImageId(long imageId)

fetchFileEntryByFileName

public DLFileEntry fetchFileEntryByFileName(long groupId,
                                            long folderId,
                                            String fileName)

fetchFileEntryByName

public DLFileEntry fetchFileEntryByName(long groupId,
                                        long folderId,
                                        String name)

getDDMStructureFileEntries

public List<DLFileEntry> getDDMStructureFileEntries(long groupId,
                                                    long[] ddmStructureIds)

getDDMStructureFileEntries

public List<DLFileEntry> getDDMStructureFileEntries(long[] ddmStructureIds)

getExtraSettingsFileEntries

public List<DLFileEntry> getExtraSettingsFileEntries(int start,
                                                     int end)

getExtraSettingsFileEntriesCount

public int getExtraSettingsFileEntriesCount()

getFile

@Deprecated
public File getFile(long userId,
                               long fileEntryId,
                               String version,
                               boolean incrementCounter)
             throws PortalException
Deprecated. As of 7.0.0, replaced by getFile(long, String, boolean)

Throws:
PortalException

getFile

@Deprecated
public File getFile(long userId,
                               long fileEntryId,
                               String version,
                               boolean incrementCounter,
                               int increment)
             throws PortalException
Deprecated. As of 7.0.0, replaced by getFile(long, String, boolean, int)

Throws:
PortalException

getFile

public File getFile(long fileEntryId,
                    String version,
                    boolean incrementCounter)
             throws PortalException
Throws:
PortalException

getFile

public File getFile(long fileEntryId,
                    String version,
                    boolean incrementCounter,
                    int increment)
             throws PortalException
Throws:
PortalException

getFileAsStream

@Deprecated
public InputStream getFileAsStream(long userId,
                                              long fileEntryId,
                                              String version)
                            throws PortalException
Deprecated. As of 7.0.0, replaced by getFileAsStream(long, String)

Throws:
PortalException

getFileAsStream

@Deprecated
public InputStream getFileAsStream(long userId,
                                              long fileEntryId,
                                              String version,
                                              boolean incrementCounter)
                            throws PortalException
Deprecated. As of 7.0.0, replaced by getFileAsStream(long, String, boolean)

Throws:
PortalException

getFileAsStream

@Deprecated
public InputStream getFileAsStream(long userId,
                                              long fileEntryId,
                                              String version,
                                              boolean incrementCounter,
                                              int increment)
                            throws PortalException
Deprecated. As of 7.0.0, replaced by getFileAsStream(long, String, boolean, int)

Throws:
PortalException

getFileAsStream

public InputStream getFileAsStream(long fileEntryId,
                                   String version)
                            throws PortalException
Throws:
PortalException

getFileAsStream

public InputStream getFileAsStream(long fileEntryId,
                                   String version,
                                   boolean incrementCounter)
                            throws PortalException
Throws:
PortalException

getFileAsStream

public InputStream getFileAsStream(long fileEntryId,
                                   String version,
                                   boolean incrementCounter,
                                   int increment)
                            throws PortalException
Throws:
PortalException

getFileEntries

public List<DLFileEntry> getFileEntries(int start,
                                        int end)

getFileEntries

public List<DLFileEntry> getFileEntries(long groupId,
                                        long folderId)

getFileEntries

public List<DLFileEntry> getFileEntries(long groupId,
                                        long folderId,
                                        int status,
                                        int start,
                                        int end,
                                        OrderByComparator<DLFileEntry> obc)

getFileEntries

public List<DLFileEntry> getFileEntries(long groupId,
                                        long folderId,
                                        int start,
                                        int end,
                                        OrderByComparator<DLFileEntry> obc)

getFileEntries

public List<DLFileEntry> getFileEntries(long groupId,
                                        long userId,
                                        List<Long> repositoryIds,
                                        List<Long> folderIds,
                                        String[] mimeTypes,
                                        QueryDefinition<DLFileEntry> queryDefinition)
                                 throws Exception
Throws:
Exception

getFileEntries

public List<DLFileEntry> getFileEntries(long groupId,
                                        long userId,
                                        List<Long> folderIds,
                                        String[] mimeTypes,
                                        QueryDefinition<DLFileEntry> queryDefinition)
                                 throws Exception
Throws:
Exception

getFileEntries

public List<DLFileEntry> getFileEntries(long folderId,
                                        String name)

getFileEntriesCount

public int getFileEntriesCount()

getFileEntriesCount

@Deprecated
public int getFileEntriesCount(long groupId,
                                          DateRange dateRange,
                                          long repositoryId,
                                          QueryDefinition<DLFileEntry> queryDefinition)
Deprecated. As of 7.0.0, with no direct replacement


getFileEntriesCount

public int getFileEntriesCount(long groupId,
                               long folderId)

getFileEntriesCount

public int getFileEntriesCount(long groupId,
                               long folderId,
                               int status)

getFileEntriesCount

public int getFileEntriesCount(long groupId,
                               long userId,
                               List<Long> repositoryIds,
                               List<Long> folderIds,
                               String[] mimeTypes,
                               QueryDefinition<DLFileEntry> queryDefinition)
                        throws Exception
Throws:
Exception

getFileEntriesCount

public int getFileEntriesCount(long groupId,
                               long userId,
                               List<Long> folderIds,
                               String[] mimeTypes,
                               QueryDefinition<DLFileEntry> queryDefinition)
                        throws Exception
Throws:
Exception

getFileEntry

public DLFileEntry getFileEntry(long fileEntryId)
                         throws PortalException
Throws:
PortalException

getFileEntry

public DLFileEntry getFileEntry(long groupId,
                                long folderId,
                                String title)
                         throws PortalException
Throws:
PortalException

getFileEntryByName

public DLFileEntry getFileEntryByName(long groupId,
                                      long folderId,
                                      String name)
                               throws PortalException
Throws:
PortalException

getFileEntryByUuidAndGroupId

public DLFileEntry getFileEntryByUuidAndGroupId(String uuid,
                                                long groupId)
                                         throws PortalException
Throws:
PortalException

getGroupFileEntries

public List<DLFileEntry> getGroupFileEntries(long groupId,
                                             int start,
                                             int end)

getGroupFileEntries

public List<DLFileEntry> getGroupFileEntries(long groupId,
                                             int start,
                                             int end,
                                             OrderByComparator<DLFileEntry> obc)

getGroupFileEntries

public List<DLFileEntry> getGroupFileEntries(long groupId,
                                             long userId,
                                             int start,
                                             int end)

getGroupFileEntries

public List<DLFileEntry> getGroupFileEntries(long groupId,
                                             long userId,
                                             int start,
                                             int end,
                                             OrderByComparator<DLFileEntry> obc)

getGroupFileEntries

public List<DLFileEntry> getGroupFileEntries(long groupId,
                                             long userId,
                                             long rootFolderId,
                                             int start,
                                             int end,
                                             OrderByComparator<DLFileEntry> obc)

getGroupFileEntries

public List<DLFileEntry> getGroupFileEntries(long groupId,
                                             long userId,
                                             long repositoryId,
                                             long rootFolderId,
                                             int start,
                                             int end,
                                             OrderByComparator<DLFileEntry> obc)

getGroupFileEntriesCount

public int getGroupFileEntriesCount(long groupId)

getGroupFileEntriesCount

public int getGroupFileEntriesCount(long groupId,
                                    long userId)

getMisversionedFileEntries

public List<DLFileEntry> getMisversionedFileEntries()

getNoAssetFileEntries

public List<DLFileEntry> getNoAssetFileEntries()

getOrphanedFileEntries

public List<DLFileEntry> getOrphanedFileEntries()

getRepositoryFileEntries

public List<DLFileEntry> getRepositoryFileEntries(long repositoryId,
                                                  int start,
                                                  int end)

getRepositoryFileEntriesCount

public int getRepositoryFileEntriesCount(long repositoryId)

getUniqueTitle

public String getUniqueTitle(long groupId,
                             long folderId,
                             long fileEntryId,
                             String title,
                             String extension)
                      throws PortalException
Throws:
PortalException

hasExtraSettings

public boolean hasExtraSettings()

hasFileEntryLock

public boolean hasFileEntryLock(long userId,
                                long fileEntryId)
                         throws PortalException
Throws:
PortalException

incrementViewCounter

@BufferedIncrement(configuration="DLFileEntry",
                   incrementClass=NumberIncrement.class)
public void incrementViewCounter(DLFileEntry dlFileEntry,
                                                                                                   int increment)

isFileEntryCheckedOut

public boolean isFileEntryCheckedOut(long fileEntryId)
                              throws PortalException
Throws:
PortalException

isKeepFileVersionLabel

public boolean isKeepFileVersionLabel(long fileEntryId,
                                      ServiceContext serviceContext)
                               throws PortalException
Throws:
PortalException

lockFileEntry

public Lock lockFileEntry(long userId,
                          long fileEntryId)
                   throws PortalException
Throws:
PortalException

moveFileEntry

@Indexable(type=REINDEX)
public DLFileEntry moveFileEntry(long userId,
                                                      long fileEntryId,
                                                      long newFolderId,
                                                      ServiceContext serviceContext)
                          throws PortalException
Throws:
PortalException

rebuildTree

public void rebuildTree(long companyId)
                 throws PortalException
Throws:
PortalException

revertFileEntry

public void revertFileEntry(long userId,
                            long fileEntryId,
                            String version,
                            ServiceContext serviceContext)
                     throws PortalException
Throws:
PortalException

search

public Hits search(long groupId,
                   long userId,
                   long creatorUserId,
                   int status,
                   int start,
                   int end)
            throws PortalException
Throws:
PortalException

search

public Hits search(long groupId,
                   long userId,
                   long creatorUserId,
                   long folderId,
                   String[] mimeTypes,
                   int status,
                   int start,
                   int end)
            throws PortalException
Throws:
PortalException

setTreePaths

public void setTreePaths(long folderId,
                         String treePath,
                         boolean reindex)
                  throws PortalException
Throws:
PortalException

unlockFileEntry

public void unlockFileEntry(long fileEntryId)

updateFileEntry

public DLFileEntry updateFileEntry(long userId,
                                   long fileEntryId,
                                   String sourceFileName,
                                   String mimeType,
                                   String title,
                                   String description,
                                   String changeLog,
                                   boolean majorVersion,
                                   long fileEntryTypeId,
                                   Map<String,DDMFormValues> ddmFormValuesMap,
                                   File file,
                                   InputStream is,
                                   long size,
                                   ServiceContext serviceContext)
                            throws PortalException
Throws:
PortalException

updateFileEntryType

public DLFileEntry updateFileEntryType(long userId,
                                       long fileEntryId,
                                       long fileEntryTypeId,
                                       ServiceContext serviceContext)
                                throws PortalException
Throws:
PortalException

updateSmallImage

public void updateSmallImage(long smallImageId,
                             long largeImageId)
                      throws PortalException
Throws:
PortalException

updateStatus

public DLFileEntry updateStatus(long userId,
                                long fileVersionId,
                                int status,
                                ServiceContext serviceContext,
                                Map<String,Serializable> workflowContext)
                         throws PortalException
Throws:
PortalException

validateFile

public void validateFile(long groupId,
                         long folderId,
                         long fileEntryId,
                         String fileName,
                         String title)
                  throws PortalException
Throws:
PortalException

verifyFileEntryCheckOut

public boolean verifyFileEntryCheckOut(long fileEntryId,
                                       String lockUuid)
                                throws PortalException
Throws:
PortalException

verifyFileEntryLock

public boolean verifyFileEntryLock(long fileEntryId,
                                   String lockUuid)
                            throws PortalException
Throws:
PortalException

addFileVersion

protected DLFileVersion addFileVersion(User user,
                                       DLFileEntry dlFileEntry,
                                       String fileName,
                                       String extension,
                                       String mimeType,
                                       String title,
                                       String description,
                                       String changeLog,
                                       String extraSettings,
                                       long fileEntryTypeId,
                                       Map<String,DDMFormValues> ddmFormValuesMap,
                                       String version,
                                       long size,
                                       int status,
                                       ServiceContext serviceContext)
                                throws PortalException
Throws:
PortalException

convertExtraSettings

protected void convertExtraSettings(DLFileEntry dlFileEntry,
                                    DLFileVersion dlFileVersion,
                                    String[] keys)
                             throws PortalException
Throws:
PortalException

convertExtraSettings

protected void convertExtraSettings(DLFileEntry dlFileEntry,
                                    String[] keys)
                             throws PortalException
Throws:
PortalException

convertExtraSettings

protected void convertExtraSettings(UnicodeProperties extraSettingsProperties,
                                    ExpandoBridge expandoBridge,
                                    String[] keys)

copyExpandoRowModifiedDate

protected void copyExpandoRowModifiedDate(long companyId,
                                          long sourceFileVersionId,
                                          long destinationFileVersionId)

copyFileEntryMetadata

protected void copyFileEntryMetadata(long companyId,
                                     long fileEntryId,
                                     long fromFileVersionId,
                                     long toFileVersionId,
                                     ServiceContext serviceContext,
                                     Map<String,DDMFormValues> ddmFormValuesMap,
                                     List<DDMStructure> ddmStructures)
                              throws PortalException
Throws:
PortalException

getFolderRepositoryEventTrigger

protected RepositoryEventTrigger getFolderRepositoryEventTrigger(long groupId,
                                                                 long folderId)
                                                          throws PortalException
Throws:
PortalException

getNextVersion

protected String getNextVersion(DLFileEntry dlFileEntry,
                                boolean majorVersion,
                                int workflowAction)

isKeepFileVersionLabel

protected boolean isKeepFileVersionLabel(DLFileEntry dlFileEntry,
                                         DLFileVersion lastDLFileVersion,
                                         DLFileVersion latestDLFileVersion,
                                         ServiceContext serviceContext)
                                  throws PortalException
Throws:
PortalException
See Also:
com.liferay.dynamic.data.lists.service.impl.DDLRecordLocalServiceImpl#isKeepRecordVersionLabel( com.liferay.dynamic.data.lists.model.DDLRecordVersion, com.liferay.dynamic.data.lists.model.DDLRecordVersion, ServiceContext)

moveFileEntryImpl

protected DLFileEntry moveFileEntryImpl(long userId,
                                        long fileEntryId,
                                        long newFolderId,
                                        ServiceContext serviceContext)
                                 throws PortalException
Throws:
PortalException

reindex

protected void reindex(DLFileEntry dlFileEntry)
                throws SearchException
Throws:
SearchException

removeFileVersion

protected void removeFileVersion(DLFileEntry dlFileEntry,
                                 DLFileVersion dlFileVersion)
                          throws PortalException
Throws:
PortalException

updateFileEntry

protected DLFileEntry updateFileEntry(long userId,
                                      long fileEntryId,
                                      String sourceFileName,
                                      String extension,
                                      String mimeType,
                                      String title,
                                      String description,
                                      String changeLog,
                                      boolean majorVersion,
                                      String extraSettings,
                                      long fileEntryTypeId,
                                      Map<String,DDMFormValues> ddmFormValuesMap,
                                      File file,
                                      InputStream is,
                                      long size,
                                      ServiceContext serviceContext)
                               throws PortalException
Throws:
PortalException

updateFileVersion

protected DLFileVersion updateFileVersion(User user,
                                          DLFileVersion dlFileVersion,
                                          String sourceFileName,
                                          String fileName,
                                          String extension,
                                          String mimeType,
                                          String title,
                                          String description,
                                          String changeLog,
                                          String extraSettings,
                                          long fileEntryTypeId,
                                          Map<String,DDMFormValues> ddmFormValuesMap,
                                          String version,
                                          long size,
                                          int status,
                                          Date statusDate,
                                          ServiceContext serviceContext)
                                   throws PortalException
Throws:
PortalException

validateFile

protected void validateFile(long groupId,
                            long folderId,
                            long fileEntryId,
                            String sourceFileName,
                            String fileName,
                            String extension,
                            String title)
                     throws PortalException
Throws:
PortalException

validateFileEntryTypeId

protected void validateFileEntryTypeId(long[] groupIds,
                                       long folderId,
                                       long fileEntryTypeId)
                                throws PortalException
Throws:
PortalException

validateFileExtension

protected void validateFileExtension(String extension)
                              throws PortalException
Throws:
PortalException

Liferay 7.0-ce-b4