001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.shopping.service;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.exception.PortalException;
020    import com.liferay.portal.kernel.exception.SystemException;
021    import com.liferay.portal.kernel.jsonwebservice.JSONWebService;
022    import com.liferay.portal.kernel.security.access.control.AccessControlled;
023    import com.liferay.portal.kernel.transaction.Isolation;
024    import com.liferay.portal.kernel.transaction.Propagation;
025    import com.liferay.portal.kernel.transaction.Transactional;
026    import com.liferay.portal.service.BaseService;
027    
028    /**
029     * Provides the remote service interface for ShoppingItem. Methods of this
030     * service are expected to have security checks based on the propagated JAAS
031     * credentials because this service can be accessed remotely.
032     *
033     * @author Brian Wing Shun Chan
034     * @see ShoppingItemServiceUtil
035     * @see com.liferay.portlet.shopping.service.base.ShoppingItemServiceBaseImpl
036     * @see com.liferay.portlet.shopping.service.impl.ShoppingItemServiceImpl
037     * @generated
038     */
039    @AccessControlled
040    @JSONWebService
041    @ProviderType
042    @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
043            PortalException.class, SystemException.class})
044    public interface ShoppingItemService extends BaseService {
045            /*
046             * NOTE FOR DEVELOPERS:
047             *
048             * Never modify or reference this interface directly. Always use {@link ShoppingItemServiceUtil} to access the shopping item remote service. Add custom service methods to {@link com.liferay.portlet.shopping.service.impl.ShoppingItemServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface.
049             */
050            public com.liferay.portlet.shopping.model.ShoppingItem addItem(
051                    long groupId, long categoryId, java.lang.String sku,
052                    java.lang.String name, java.lang.String description,
053                    java.lang.String properties, java.lang.String fieldsQuantities,
054                    boolean requiresShipping, int stockQuantity, boolean featured,
055                    java.lang.Boolean sale, boolean smallImage,
056                    java.lang.String smallImageURL, java.io.File smallFile,
057                    boolean mediumImage, java.lang.String mediumImageURL,
058                    java.io.File mediumFile, boolean largeImage,
059                    java.lang.String largeImageURL, java.io.File largeFile,
060                    java.util.List<com.liferay.portlet.shopping.model.ShoppingItemField> itemFields,
061                    java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> itemPrices,
062                    com.liferay.portal.service.ServiceContext serviceContext)
063                    throws PortalException;
064    
065            public void deleteItem(long itemId) throws PortalException;
066    
067            /**
068            * Returns the Spring bean ID for this bean.
069            *
070            * @return the Spring bean ID for this bean
071            */
072            public java.lang.String getBeanIdentifier();
073    
074            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
075            public int getCategoriesItemsCount(long groupId,
076                    java.util.List<java.lang.Long> categoryIds);
077    
078            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
079            public com.liferay.portlet.shopping.model.ShoppingItem getItem(long itemId)
080                    throws PortalException;
081    
082            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
083            public java.util.List<com.liferay.portlet.shopping.model.ShoppingItem> getItems(
084                    long groupId, long categoryId);
085    
086            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
087            public java.util.List<com.liferay.portlet.shopping.model.ShoppingItem> getItems(
088                    long groupId, long categoryId, int start, int end,
089                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.shopping.model.ShoppingItem> obc);
090    
091            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
092            public int getItemsCount(long groupId, long categoryId);
093    
094            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
095            public com.liferay.portlet.shopping.model.ShoppingItem[] getItemsPrevAndNext(
096                    long itemId,
097                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.shopping.model.ShoppingItem> obc)
098                    throws PortalException;
099    
100            /**
101            * Sets the Spring bean ID for this bean.
102            *
103            * @param beanIdentifier the Spring bean ID for this bean
104            */
105            public void setBeanIdentifier(java.lang.String beanIdentifier);
106    
107            public com.liferay.portlet.shopping.model.ShoppingItem updateItem(
108                    long itemId, long groupId, long categoryId, java.lang.String sku,
109                    java.lang.String name, java.lang.String description,
110                    java.lang.String properties, java.lang.String fieldsQuantities,
111                    boolean requiresShipping, int stockQuantity, boolean featured,
112                    java.lang.Boolean sale, boolean smallImage,
113                    java.lang.String smallImageURL, java.io.File smallFile,
114                    boolean mediumImage, java.lang.String mediumImageURL,
115                    java.io.File mediumFile, boolean largeImage,
116                    java.lang.String largeImageURL, java.io.File largeFile,
117                    java.util.List<com.liferay.portlet.shopping.model.ShoppingItemField> itemFields,
118                    java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> itemPrices,
119                    com.liferay.portal.service.ServiceContext serviceContext)
120                    throws PortalException;
121    }