Liferay 6.2-ce-ga5

com.liferay.portal.upgrade.v6_1_0
Class UpgradeImageGallery

java.lang.Object
  extended by com.liferay.portal.kernel.dao.db.BaseDBProcess
      extended by com.liferay.portal.kernel.upgrade.UpgradeProcess
          extended by com.liferay.portal.upgrade.v6_1_0.UpgradeImageGallery
All Implemented Interfaces:
DBProcess

public class UpgradeImageGallery
extends UpgradeProcess


Constructor Summary
UpgradeImageGallery()
           
 
Method Summary
protected  void addDLFileEntry(String uuid, long fileEntryId, long groupId, long companyId, long userId, String userName, long versionUserId, String versionUserName, Timestamp createDate, Timestamp modifiedDate, long repositoryId, long folderId, String name, String extension, String mimeType, String title, String description, String extraSettings, long fileEntryTypeId, String version, long size, int readCount, long smallImageId, long largeImageId, long custom1ImageId, long custom2ImageId)
           
protected  void addDLFileVersion(long fileVersionId, long groupId, long companyId, long userId, String userName, Timestamp createDate, long repositoryId, long folderId, long fileEntryId, String extension, String mimeType, String title, String description, String changeLog, String extraSettings, long fileEntryTypeId, String version, long size, int status, long statusByUserId, String statusByUserName, Timestamp statusDate)
           
protected  void addDLFolderEntry(String uuid, long folderId, long groupId, long companyId, long userId, String userName, Timestamp createDate, Timestamp modifiedDate, long repositoryId, long parentFolderId, String name, String description, Timestamp lastPostDate)
           
protected  void addIGImageDLFileEntryType()
           
protected  void addIGImageDLFileEntryType(long groupId, long companyId, long userId, String userName, Timestamp createDate, Timestamp modifiedDate)
           
protected  void deleteConflictingIGPermissions(String igResourceName, String dlResourceName)
           
protected  void doUpgrade()
           
protected  long getBitwiseValue(Map<String,Long> bitwiseValues, List<String> actionIds)
           
protected  Map<String,Long> getBitwiseValues(String name)
           
protected  long getCompanyGroupId(long companyId)
           
protected  byte[] getDatabaseImageAsBytes(Image image)
           
protected  long getDefaultUserId(long companyId)
           
protected  byte[] getHookImageAsBytes(Image image)
           
protected  InputStream getHookImageAsStream(Image image)
           
protected  Object[] getImage(long imageId)
           
protected  List<String> getResourceActionIds(Map<String,Long> bitwiseValues, long actionIdsLong)
           
protected  void migrateFile(long repositoryId, long companyId, String name, Image image)
           
protected  void migrateImage(long imageId)
           
protected  void migrateImage(long fileEntryId, long companyId, long groupId, long folderId, String name, long smallImageId, long largeImageId, long custom1ImageId, long custom2ImageId)
           
protected  void migrateImageFiles()
           
protected  void updateIGFolderEntries()
           
protected  void updateIGFolderPermissions()
           
protected  void updateIGImageEntries()
           
protected  void updateIGImageEntries(long companyId, long fileEntryTypeId)
           
protected  boolean updateIGImageFolderId(long groupId, String name, long parentFolderId, long folderId, Map<Long,Long> folderIds)
           
protected  void updateIGImagePermissions()
           
protected  void updateIGtoDLPermissions(String igResourceName, String dlResourceName)
           
 
Methods inherited from class com.liferay.portal.kernel.upgrade.UpgradeProcess
doHasTable, getThreshold, hasTable, increment, increment, isSupportsAlterColumnName, isSupportsAlterColumnType, isSupportsStringCaseSensitiveQuery, isSupportsUpdateWithInnerJoin, tableHasColumn, tableHasData, upgrade, upgrade, upgrade, upgradeTable, upgradeTable
 
Methods inherited from class com.liferay.portal.kernel.dao.db.BaseDBProcess
runSQL, runSQL, runSQLTemplate, runSQLTemplate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UpgradeImageGallery

public UpgradeImageGallery()
                    throws Exception
Throws:
Exception
Method Detail

addDLFileEntry

protected void addDLFileEntry(String uuid,
                              long fileEntryId,
                              long groupId,
                              long companyId,
                              long userId,
                              String userName,
                              long versionUserId,
                              String versionUserName,
                              Timestamp createDate,
                              Timestamp modifiedDate,
                              long repositoryId,
                              long folderId,
                              String name,
                              String extension,
                              String mimeType,
                              String title,
                              String description,
                              String extraSettings,
                              long fileEntryTypeId,
                              String version,
                              long size,
                              int readCount,
                              long smallImageId,
                              long largeImageId,
                              long custom1ImageId,
                              long custom2ImageId)
                       throws Exception
Throws:
Exception

addDLFileVersion

protected void addDLFileVersion(long fileVersionId,
                                long groupId,
                                long companyId,
                                long userId,
                                String userName,
                                Timestamp createDate,
                                long repositoryId,
                                long folderId,
                                long fileEntryId,
                                String extension,
                                String mimeType,
                                String title,
                                String description,
                                String changeLog,
                                String extraSettings,
                                long fileEntryTypeId,
                                String version,
                                long size,
                                int status,
                                long statusByUserId,
                                String statusByUserName,
                                Timestamp statusDate)
                         throws Exception
Throws:
Exception

addDLFolderEntry

protected void addDLFolderEntry(String uuid,
                                long folderId,
                                long groupId,
                                long companyId,
                                long userId,
                                String userName,
                                Timestamp createDate,
                                Timestamp modifiedDate,
                                long repositoryId,
                                long parentFolderId,
                                String name,
                                String description,
                                Timestamp lastPostDate)
                         throws Exception
Throws:
Exception

addIGImageDLFileEntryType

protected void addIGImageDLFileEntryType()
                                  throws Exception
Throws:
Exception

addIGImageDLFileEntryType

protected void addIGImageDLFileEntryType(long groupId,
                                         long companyId,
                                         long userId,
                                         String userName,
                                         Timestamp createDate,
                                         Timestamp modifiedDate)
                                  throws Exception
Throws:
Exception

deleteConflictingIGPermissions

protected void deleteConflictingIGPermissions(String igResourceName,
                                              String dlResourceName)
                                       throws Exception
Throws:
Exception

doUpgrade

protected void doUpgrade()
                  throws Exception
Overrides:
doUpgrade in class UpgradeProcess
Throws:
Exception

getBitwiseValue

protected long getBitwiseValue(Map<String,Long> bitwiseValues,
                               List<String> actionIds)

getBitwiseValues

protected Map<String,Long> getBitwiseValues(String name)
                                     throws Exception
Throws:
Exception

getCompanyGroupId

protected long getCompanyGroupId(long companyId)
                          throws Exception
Throws:
Exception

getDatabaseImageAsBytes

protected byte[] getDatabaseImageAsBytes(Image image)
                                  throws SQLException
Throws:
SQLException

getDefaultUserId

protected long getDefaultUserId(long companyId)
                         throws Exception
Throws:
Exception

getHookImageAsBytes

protected byte[] getHookImageAsBytes(Image image)
                              throws IOException,
                                     PortalException,
                                     SQLException,
                                     SystemException
Throws:
IOException
PortalException
SQLException
SystemException

getHookImageAsStream

protected InputStream getHookImageAsStream(Image image)
                                    throws PortalException,
                                           SQLException,
                                           SystemException
Throws:
PortalException
SQLException
SystemException

getImage

protected Object[] getImage(long imageId)
                     throws Exception
Throws:
Exception

getResourceActionIds

protected List<String> getResourceActionIds(Map<String,Long> bitwiseValues,
                                            long actionIdsLong)

migrateFile

protected void migrateFile(long repositoryId,
                           long companyId,
                           String name,
                           Image image)
                    throws Exception
Throws:
Exception

migrateImage

protected void migrateImage(long imageId)
                     throws Exception
Throws:
Exception

migrateImage

protected void migrateImage(long fileEntryId,
                            long companyId,
                            long groupId,
                            long folderId,
                            String name,
                            long smallImageId,
                            long largeImageId,
                            long custom1ImageId,
                            long custom2ImageId)
                     throws Exception
Throws:
Exception

migrateImageFiles

protected void migrateImageFiles()
                          throws Exception
Throws:
Exception

updateIGFolderEntries

protected void updateIGFolderEntries()
                              throws Exception
Throws:
Exception

updateIGFolderPermissions

protected void updateIGFolderPermissions()
                                  throws Exception
Throws:
Exception

updateIGImageEntries

protected void updateIGImageEntries()
                             throws Exception
Throws:
Exception

updateIGImageEntries

protected void updateIGImageEntries(long companyId,
                                    long fileEntryTypeId)
                             throws Exception
Throws:
Exception

updateIGImageFolderId

protected boolean updateIGImageFolderId(long groupId,
                                        String name,
                                        long parentFolderId,
                                        long folderId,
                                        Map<Long,Long> folderIds)
                                 throws Exception
Throws:
Exception

updateIGImagePermissions

protected void updateIGImagePermissions()
                                 throws Exception
Throws:
Exception

updateIGtoDLPermissions

protected void updateIGtoDLPermissions(String igResourceName,
                                       String dlResourceName)
                                throws Exception
Throws:
Exception

Liferay 6.2-ce-ga5