001
014
015 package com.liferay.portlet.shopping.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018
019
036 public class ShoppingItemServiceUtil {
037 public static void addBookItems(long groupId, long categoryId,
038 java.lang.String[] isbns)
039 throws com.liferay.portal.kernel.exception.PortalException,
040 com.liferay.portal.kernel.exception.SystemException {
041 getService().addBookItems(groupId, categoryId, isbns);
042 }
043
044 public static com.liferay.portlet.shopping.model.ShoppingItem addItem(
045 long groupId, long categoryId, java.lang.String sku,
046 java.lang.String name, java.lang.String description,
047 java.lang.String properties, java.lang.String fieldsQuantities,
048 boolean requiresShipping, int stockQuantity, boolean featured,
049 java.lang.Boolean sale, boolean smallImage,
050 java.lang.String smallImageURL, java.io.File smallFile,
051 boolean mediumImage, java.lang.String mediumImageURL,
052 java.io.File mediumFile, boolean largeImage,
053 java.lang.String largeImageURL, java.io.File largeFile,
054 java.util.List<com.liferay.portlet.shopping.model.ShoppingItemField> itemFields,
055 java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> itemPrices,
056 com.liferay.portal.service.ServiceContext serviceContext)
057 throws com.liferay.portal.kernel.exception.PortalException,
058 com.liferay.portal.kernel.exception.SystemException {
059 return getService()
060 .addItem(groupId, categoryId, sku, name, description,
061 properties, fieldsQuantities, requiresShipping, stockQuantity,
062 featured, sale, smallImage, smallImageURL, smallFile, mediumImage,
063 mediumImageURL, mediumFile, largeImage, largeImageURL, largeFile,
064 itemFields, itemPrices, serviceContext);
065 }
066
067 public static void deleteItem(long itemId)
068 throws com.liferay.portal.kernel.exception.PortalException,
069 com.liferay.portal.kernel.exception.SystemException {
070 getService().deleteItem(itemId);
071 }
072
073 public static com.liferay.portlet.shopping.model.ShoppingItem getItem(
074 long itemId)
075 throws com.liferay.portal.kernel.exception.PortalException,
076 com.liferay.portal.kernel.exception.SystemException {
077 return getService().getItem(itemId);
078 }
079
080 public static com.liferay.portlet.shopping.model.ShoppingItem updateItem(
081 long itemId, long groupId, long categoryId, java.lang.String sku,
082 java.lang.String name, java.lang.String description,
083 java.lang.String properties, java.lang.String fieldsQuantities,
084 boolean requiresShipping, int stockQuantity, boolean featured,
085 java.lang.Boolean sale, boolean smallImage,
086 java.lang.String smallImageURL, java.io.File smallFile,
087 boolean mediumImage, java.lang.String mediumImageURL,
088 java.io.File mediumFile, boolean largeImage,
089 java.lang.String largeImageURL, java.io.File largeFile,
090 java.util.List<com.liferay.portlet.shopping.model.ShoppingItemField> itemFields,
091 java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> itemPrices,
092 com.liferay.portal.service.ServiceContext serviceContext)
093 throws com.liferay.portal.kernel.exception.PortalException,
094 com.liferay.portal.kernel.exception.SystemException {
095 return getService()
096 .updateItem(itemId, groupId, categoryId, sku, name,
097 description, properties, fieldsQuantities, requiresShipping,
098 stockQuantity, featured, sale, smallImage, smallImageURL,
099 smallFile, mediumImage, mediumImageURL, mediumFile, largeImage,
100 largeImageURL, largeFile, itemFields, itemPrices, serviceContext);
101 }
102
103 public static ShoppingItemService getService() {
104 if (_service == null) {
105 _service = (ShoppingItemService)PortalBeanLocatorUtil.locate(ShoppingItemService.class.getName());
106 }
107
108 return _service;
109 }
110
111 public void setService(ShoppingItemService service) {
112 _service = service;
113 }
114
115 private static ShoppingItemService _service;
116 }