Liferay 6.0-ee-sp2

com.liferay.portlet.imagegallery.service
Interface IGImageLocalService

All Superinterfaces:
PersistedModelLocalService
All Known Implementing Classes:
IGImageLocalServiceWrapper

@Transactional(isolation=PORTAL,
               rollbackFor={PortalException.class,SystemException.class})
public interface IGImageLocalService
extends PersistedModelLocalService

The interface for the i g image local service.

This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.

See Also:
IGImageLocalServiceUtil, com.liferay.portlet.imagegallery.service.base.IGImageLocalServiceBaseImpl, com.liferay.portlet.imagegallery.service.impl.IGImageLocalServiceImpl

Method Summary
 IGImage addIGImage(IGImage igImage)
          Adds the i g image to the database.
 IGImage addImage(long userId, long groupId, long folderId, String name, String description, File file, String contentType, ServiceContext serviceContext)
           
 IGImage addImage(long userId, long groupId, long folderId, String name, String description, String fileName, byte[] bytes, String contentType, ServiceContext serviceContext)
           
 IGImage addImage(long userId, long groupId, long folderId, String name, String description, String fileName, InputStream is, String contentType, ServiceContext serviceContext)
           
 void addImageResources(IGImage image, boolean addCommunityPermissions, boolean addGuestPermissions)
           
 void addImageResources(IGImage image, String[] communityPermissions, String[] guestPermissions)
           
 void addImageResources(long imageId, boolean addCommunityPermissions, boolean addGuestPermissions)
           
 void addImageResources(long imageId, String[] communityPermissions, String[] guestPermissions)
           
 IGImage createIGImage(long imageId)
          Creates a new i g image with the primary key.
 void deleteIGImage(IGImage igImage)
          Deletes the i g image from the database.
 void deleteIGImage(long imageId)
          Deletes the i g image with the primary key from the database.
 void deleteImage(IGImage image)
           
 void deleteImage(long imageId)
           
 void deleteImages(long groupId, long folderId)
           
 List dynamicQuery(DynamicQuery dynamicQuery)
          Performs a dynamic query on the database and returns the matching rows.
 List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
          Performs a dynamic query on the database and returns a range of the matching rows.
 List dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator orderByComparator)
          Performs a dynamic query on the database and returns an ordered range of the matching rows.
 long dynamicQueryCount(DynamicQuery dynamicQuery)
          Returns the number of rows that match the dynamic query.
 String getBeanIdentifier()
          Returns the Spring bean ID for this bean.
 int getFoldersImagesCount(long groupId, List<Long> folderIds)
           
 List<IGImage> getGroupImages(long groupId, int start, int end)
           
 List<IGImage> getGroupImages(long groupId, long userId, int start, int end)
           
 int getGroupImagesCount(long groupId)
           
 int getGroupImagesCount(long groupId, long userId)
           
 IGImage getIGImage(long imageId)
          Returns the i g image with the primary key.
 IGImage getIGImageByUuidAndGroupId(String uuid, long groupId)
          Returns the i g image with the UUID in the group.
 List<IGImage> getIGImages(int start, int end)
          Returns a range of all the i g images.
 int getIGImagesCount()
          Returns the number of i g images.
 IGImage getImage(long imageId)
           
 IGImage getImageByCustom1ImageId(long custom1ImageId)
           
 IGImage getImageByCustom2ImageId(long custom2ImageId)
           
 IGImage getImageByFolderIdAndNameWithExtension(long groupId, long folderId, String nameWithExtension)
           
 IGImage getImageByLargeImageId(long largeImageId)
           
 IGImage getImageBySmallImageId(long smallImageId)
           
 IGImage getImageByUuidAndGroupId(String uuid, long groupId)
           
 List<IGImage> getImages(long groupId, long folderId)
           
 List<IGImage> getImages(long groupId, long folderId, int start, int end)
           
 List<IGImage> getImages(long groupId, long folderId, int start, int end, OrderByComparator obc)
           
 int getImagesCount(long groupId, long folderId)
           
 List<IGImage> getNoAssetImages()
           
 PersistedModel getPersistedModel(Serializable primaryKeyObj)
           
 void setBeanIdentifier(String beanIdentifier)
          Sets the Spring bean ID for this bean.
 void updateAsset(long userId, IGImage image, long[] assetCategoryIds, String[] assetTagNames, String contentType)
           
 IGImage updateIGImage(IGImage igImage)
          Updates the i g image in the database or adds it if it does not yet exist.
 IGImage updateIGImage(IGImage igImage, boolean merge)
          Updates the i g image in the database or adds it if it does not yet exist.
 IGImage updateImage(long userId, long imageId, long groupId, long folderId, String name, String description, byte[] bytes, String contentType, ServiceContext serviceContext)
           
 IGImage updateImage(long userId, long imageId, long groupId, long folderId, String name, String description, File file, String contentType, ServiceContext serviceContext)
           
 IGImage updateImage(long userId, long imageId, long groupId, long folderId, String name, String description, InputStream is, String contentType, ServiceContext serviceContext)
           
 void updateSmallImage(long smallImageId, long largeImageId)
           
 

Method Detail

addIGImage

IGImage addIGImage(IGImage igImage)
                   throws SystemException
Adds the i g image to the database. Also notifies the appropriate model listeners.

Parameters:
igImage - the i g image
Returns:
the i g image that was added
Throws:
SystemException - if a system exception occurred

createIGImage

IGImage createIGImage(long imageId)
Creates a new i g image with the primary key. Does not add the i g image to the database.

Parameters:
imageId - the primary key for the new i g image
Returns:
the new i g image

deleteIGImage

void deleteIGImage(long imageId)
                   throws PortalException,
                          SystemException
Deletes the i g image with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
imageId - the primary key of the i g image
Throws:
PortalException - if a i g image with the primary key could not be found
SystemException - if a system exception occurred

deleteIGImage

void deleteIGImage(IGImage igImage)
                   throws SystemException
Deletes the i g image from the database. Also notifies the appropriate model listeners.

Parameters:
igImage - the i g image
Throws:
SystemException - if a system exception occurred

dynamicQuery

List dynamicQuery(DynamicQuery dynamicQuery)
                  throws SystemException
Performs a dynamic query on the database and returns the matching rows.

Parameters:
dynamicQuery - the dynamic query
Returns:
the matching rows
Throws:
SystemException - if a system exception occurred

dynamicQuery

List dynamicQuery(DynamicQuery dynamicQuery,
                  int start,
                  int end)
                  throws SystemException
Performs a dynamic query on the database and returns a range of the matching rows.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
dynamicQuery - the dynamic query
start - the lower bound of the range of model instances
end - the upper bound of the range of model instances (not inclusive)
Returns:
the range of matching rows
Throws:
SystemException - if a system exception occurred

dynamicQuery

List dynamicQuery(DynamicQuery dynamicQuery,
                  int start,
                  int end,
                  OrderByComparator orderByComparator)
                  throws SystemException
Performs a dynamic query on the database and returns an ordered range of the matching rows.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
dynamicQuery - the dynamic query
start - the lower bound of the range of model instances
end - the upper bound of the range of model instances (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of matching rows
Throws:
SystemException - if a system exception occurred

dynamicQueryCount

long dynamicQueryCount(DynamicQuery dynamicQuery)
                       throws SystemException
Returns the number of rows that match the dynamic query.

Parameters:
dynamicQuery - the dynamic query
Returns:
the number of rows that match the dynamic query
Throws:
SystemException - if a system exception occurred

getIGImage

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getIGImage(long imageId)
                   throws PortalException,
                          SystemException
Returns the i g image with the primary key.

Parameters:
imageId - the primary key of the i g image
Returns:
the i g image
Throws:
PortalException - if a i g image with the primary key could not be found
SystemException - if a system exception occurred

getPersistedModel

@Transactional(propagation=SUPPORTS,
               readOnly=true)
PersistedModel getPersistedModel(Serializable primaryKeyObj)
                                 throws PortalException,
                                        SystemException
Specified by:
getPersistedModel in interface PersistedModelLocalService
Throws:
PortalException
SystemException

getIGImageByUuidAndGroupId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getIGImageByUuidAndGroupId(String uuid,
                                                                            long groupId)
                                   throws PortalException,
                                          SystemException
Returns the i g image with the UUID in the group.

Parameters:
uuid - the UUID of i g image
groupId - the group id of the i g image
Returns:
the i g image
Throws:
PortalException - if a i g image with the UUID in the group could not be found
SystemException - if a system exception occurred

getIGImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getIGImages(int start,
                                                                   int end)
                          throws SystemException
Returns a range of all the i g images.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
start - the lower bound of the range of i g images
end - the upper bound of the range of i g images (not inclusive)
Returns:
the range of i g images
Throws:
SystemException - if a system exception occurred

getIGImagesCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getIGImagesCount()
                     throws SystemException
Returns the number of i g images.

Returns:
the number of i g images
Throws:
SystemException - if a system exception occurred

updateIGImage

IGImage updateIGImage(IGImage igImage)
                      throws SystemException
Updates the i g image in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.

Parameters:
igImage - the i g image
Returns:
the i g image that was updated
Throws:
SystemException - if a system exception occurred

updateIGImage

IGImage updateIGImage(IGImage igImage,
                      boolean merge)
                      throws SystemException
Updates the i g image in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.

Parameters:
igImage - the i g image
merge - whether to merge the i g image with the current session. See BatchSession.update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean) for an explanation.
Returns:
the i g image that was updated
Throws:
SystemException - if a system exception occurred

getBeanIdentifier

String getBeanIdentifier()
Returns the Spring bean ID for this bean.

Returns:
the Spring bean ID for this bean

setBeanIdentifier

void setBeanIdentifier(String beanIdentifier)
Sets the Spring bean ID for this bean.

Parameters:
beanIdentifier - the Spring bean ID for this bean

addImage

IGImage addImage(long userId,
                 long groupId,
                 long folderId,
                 String name,
                 String description,
                 File file,
                 String contentType,
                 ServiceContext serviceContext)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

addImage

IGImage addImage(long userId,
                 long groupId,
                 long folderId,
                 String name,
                 String description,
                 String fileName,
                 byte[] bytes,
                 String contentType,
                 ServiceContext serviceContext)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

addImage

IGImage addImage(long userId,
                 long groupId,
                 long folderId,
                 String name,
                 String description,
                 String fileName,
                 InputStream is,
                 String contentType,
                 ServiceContext serviceContext)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

addImageResources

void addImageResources(IGImage image,
                       boolean addCommunityPermissions,
                       boolean addGuestPermissions)
                       throws PortalException,
                              SystemException
Throws:
PortalException
SystemException

addImageResources

void addImageResources(IGImage image,
                       String[] communityPermissions,
                       String[] guestPermissions)
                       throws PortalException,
                              SystemException
Throws:
PortalException
SystemException

addImageResources

void addImageResources(long imageId,
                       boolean addCommunityPermissions,
                       boolean addGuestPermissions)
                       throws PortalException,
                              SystemException
Throws:
PortalException
SystemException

addImageResources

void addImageResources(long imageId,
                       String[] communityPermissions,
                       String[] guestPermissions)
                       throws PortalException,
                              SystemException
Throws:
PortalException
SystemException

deleteImage

void deleteImage(IGImage image)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

deleteImage

void deleteImage(long imageId)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

deleteImages

void deleteImages(long groupId,
                  long folderId)
                  throws PortalException,
                         SystemException
Throws:
PortalException
SystemException

getFoldersImagesCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getFoldersImagesCount(long groupId,
                                                                   List<Long> folderIds)
                          throws SystemException
Throws:
SystemException

getGroupImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getGroupImages(long groupId,
                                                                      int start,
                                                                      int end)
                             throws SystemException
Throws:
SystemException

getGroupImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getGroupImages(long groupId,
                                                                      long userId,
                                                                      int start,
                                                                      int end)
                             throws SystemException
Throws:
SystemException

getGroupImagesCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getGroupImagesCount(long groupId)
                        throws SystemException
Throws:
SystemException

getGroupImagesCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getGroupImagesCount(long groupId,
                                                                 long userId)
                        throws SystemException
Throws:
SystemException

getImage

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImage(long imageId)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

getImageByCustom1ImageId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImageByCustom1ImageId(long custom1ImageId)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

getImageByCustom2ImageId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImageByCustom2ImageId(long custom2ImageId)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

getImageByFolderIdAndNameWithExtension

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImageByFolderIdAndNameWithExtension(long groupId,
                                                                                        long folderId,
                                                                                        String nameWithExtension)
                                               throws PortalException,
                                                      SystemException
Throws:
PortalException
SystemException

getImageByLargeImageId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImageByLargeImageId(long largeImageId)
                               throws PortalException,
                                      SystemException
Throws:
PortalException
SystemException

getImageBySmallImageId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImageBySmallImageId(long smallImageId)
                               throws PortalException,
                                      SystemException
Throws:
PortalException
SystemException

getImageByUuidAndGroupId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
IGImage getImageByUuidAndGroupId(String uuid,
                                                                          long groupId)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

getImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getImages(long groupId,
                                                                 long folderId)
                        throws SystemException
Throws:
SystemException

getImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getImages(long groupId,
                                                                 long folderId,
                                                                 int start,
                                                                 int end)
                        throws SystemException
Throws:
SystemException

getImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getImages(long groupId,
                                                                 long folderId,
                                                                 int start,
                                                                 int end,
                                                                 OrderByComparator obc)
                        throws SystemException
Throws:
SystemException

getImagesCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getImagesCount(long groupId,
                                                            long folderId)
                   throws SystemException
Throws:
SystemException

getNoAssetImages

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<IGImage> getNoAssetImages()
                               throws SystemException
Throws:
SystemException

updateAsset

void updateAsset(long userId,
                 IGImage image,
                 long[] assetCategoryIds,
                 String[] assetTagNames,
                 String contentType)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

updateImage

IGImage updateImage(long userId,
                    long imageId,
                    long groupId,
                    long folderId,
                    String name,
                    String description,
                    byte[] bytes,
                    String contentType,
                    ServiceContext serviceContext)
                    throws PortalException,
                           SystemException
Throws:
PortalException
SystemException

updateImage

IGImage updateImage(long userId,
                    long imageId,
                    long groupId,
                    long folderId,
                    String name,
                    String description,
                    File file,
                    String contentType,
                    ServiceContext serviceContext)
                    throws PortalException,
                           SystemException
Throws:
PortalException
SystemException

updateImage

IGImage updateImage(long userId,
                    long imageId,
                    long groupId,
                    long folderId,
                    String name,
                    String description,
                    InputStream is,
                    String contentType,
                    ServiceContext serviceContext)
                    throws PortalException,
                           SystemException
Throws:
PortalException
SystemException

updateSmallImage

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

Liferay 6.0-ee-sp2