001    /**
002     * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portlet.imagegallery.service;
016    
017    import com.liferay.portal.kernel.exception.PortalException;
018    import com.liferay.portal.kernel.exception.SystemException;
019    import com.liferay.portal.kernel.jsonwebservice.JSONWebService;
020    import com.liferay.portal.kernel.transaction.Isolation;
021    import com.liferay.portal.kernel.transaction.Propagation;
022    import com.liferay.portal.kernel.transaction.Transactional;
023    
024    /**
025     * The interface for the i g image remote service.
026     *
027     * <p>
028     * This is a remote service. Methods of this service are expected to have security checks based on the propagated JAAS credentials because this service can be accessed remotely.
029     * </p>
030     *
031     * @author Brian Wing Shun Chan
032     * @see IGImageServiceUtil
033     * @see com.liferay.portlet.imagegallery.service.base.IGImageServiceBaseImpl
034     * @see com.liferay.portlet.imagegallery.service.impl.IGImageServiceImpl
035     * @generated
036     */
037    @JSONWebService
038    @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
039            PortalException.class, SystemException.class})
040    public interface IGImageService {
041            /*
042             * NOTE FOR DEVELOPERS:
043             *
044             * Never modify or reference this interface directly. Always use {@link IGImageServiceUtil} to access the i g image remote service. Add custom service methods to {@link com.liferay.portlet.imagegallery.service.impl.IGImageServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface.
045             */
046            public com.liferay.portlet.imagegallery.model.IGImage addImage(
047                    long groupId, long folderId, java.lang.String name,
048                    java.lang.String description, java.io.File file,
049                    java.lang.String contentType,
050                    com.liferay.portal.service.ServiceContext serviceContext)
051                    throws com.liferay.portal.kernel.exception.PortalException,
052                            com.liferay.portal.kernel.exception.SystemException;
053    
054            public void deleteImage(long imageId)
055                    throws com.liferay.portal.kernel.exception.PortalException,
056                            com.liferay.portal.kernel.exception.SystemException;
057    
058            public void deleteImageByFolderIdAndNameWithExtension(long groupId,
059                    long folderId, java.lang.String nameWithExtension)
060                    throws com.liferay.portal.kernel.exception.PortalException,
061                            com.liferay.portal.kernel.exception.SystemException;
062    
063            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
064            public int getFoldersImagesCount(long groupId,
065                    java.util.List<java.lang.Long> folderIds)
066                    throws com.liferay.portal.kernel.exception.SystemException;
067    
068            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
069            public java.util.List<com.liferay.portlet.imagegallery.model.IGImage> getGroupImages(
070                    long groupId, long userId, int start, int end)
071                    throws com.liferay.portal.kernel.exception.SystemException;
072    
073            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
074            public int getGroupImagesCount(long groupId, long userId)
075                    throws com.liferay.portal.kernel.exception.SystemException;
076    
077            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
078            public com.liferay.portlet.imagegallery.model.IGImage getImage(long imageId)
079                    throws com.liferay.portal.kernel.exception.PortalException,
080                            com.liferay.portal.kernel.exception.SystemException;
081    
082            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
083            public com.liferay.portlet.imagegallery.model.IGImage getImageByFolderIdAndNameWithExtension(
084                    long groupId, long folderId, java.lang.String nameWithExtension)
085                    throws com.liferay.portal.kernel.exception.PortalException,
086                            com.liferay.portal.kernel.exception.SystemException;
087    
088            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
089            public com.liferay.portlet.imagegallery.model.IGImage getImageByLargeImageId(
090                    long largeImageId)
091                    throws com.liferay.portal.kernel.exception.PortalException,
092                            com.liferay.portal.kernel.exception.SystemException;
093    
094            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
095            public com.liferay.portlet.imagegallery.model.IGImage getImageBySmallImageId(
096                    long smallImageId)
097                    throws com.liferay.portal.kernel.exception.PortalException,
098                            com.liferay.portal.kernel.exception.SystemException;
099    
100            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
101            public java.util.List<com.liferay.portlet.imagegallery.model.IGImage> getImages(
102                    long groupId, long folderId)
103                    throws com.liferay.portal.kernel.exception.SystemException;
104    
105            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
106            public java.util.List<com.liferay.portlet.imagegallery.model.IGImage> getImages(
107                    long groupId, long folderId, int start, int end)
108                    throws com.liferay.portal.kernel.exception.SystemException;
109    
110            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
111            public int getImagesCount(long groupId, long folderId)
112                    throws com.liferay.portal.kernel.exception.SystemException;
113    
114            public com.liferay.portlet.imagegallery.model.IGImage updateImage(
115                    long imageId, long groupId, long folderId, java.lang.String name,
116                    java.lang.String description, java.io.File file,
117                    java.lang.String contentType,
118                    com.liferay.portal.service.ServiceContext serviceContext)
119                    throws com.liferay.portal.kernel.exception.PortalException,
120                            com.liferay.portal.kernel.exception.SystemException;
121    }