001
014
015 package com.liferay.portlet.shopping.service.http;
016
017 import com.liferay.portal.kernel.log.Log;
018 import com.liferay.portal.kernel.log.LogFactoryUtil;
019
020 import com.liferay.portlet.shopping.service.ShoppingCategoryServiceUtil;
021
022 import java.rmi.RemoteException;
023
024
067 public class ShoppingCategoryServiceSoap {
068 public static com.liferay.portlet.shopping.model.ShoppingCategorySoap addCategory(
069 long parentCategoryId, java.lang.String name,
070 java.lang.String description,
071 com.liferay.portal.service.ServiceContext serviceContext)
072 throws RemoteException {
073 try {
074 com.liferay.portlet.shopping.model.ShoppingCategory returnValue = ShoppingCategoryServiceUtil.addCategory(parentCategoryId,
075 name, description, serviceContext);
076
077 return com.liferay.portlet.shopping.model.ShoppingCategorySoap.toSoapModel(returnValue);
078 }
079 catch (Exception e) {
080 _log.error(e, e);
081
082 throw new RemoteException(e.getMessage());
083 }
084 }
085
086 public static void deleteCategory(long categoryId)
087 throws RemoteException {
088 try {
089 ShoppingCategoryServiceUtil.deleteCategory(categoryId);
090 }
091 catch (Exception e) {
092 _log.error(e, e);
093
094 throw new RemoteException(e.getMessage());
095 }
096 }
097
098 public static com.liferay.portlet.shopping.model.ShoppingCategorySoap getCategory(
099 long categoryId) throws RemoteException {
100 try {
101 com.liferay.portlet.shopping.model.ShoppingCategory returnValue = ShoppingCategoryServiceUtil.getCategory(categoryId);
102
103 return com.liferay.portlet.shopping.model.ShoppingCategorySoap.toSoapModel(returnValue);
104 }
105 catch (Exception e) {
106 _log.error(e, e);
107
108 throw new RemoteException(e.getMessage());
109 }
110 }
111
112 public static com.liferay.portlet.shopping.model.ShoppingCategorySoap updateCategory(
113 long categoryId, long parentCategoryId, java.lang.String name,
114 java.lang.String description, boolean mergeWithParentCategory,
115 com.liferay.portal.service.ServiceContext serviceContext)
116 throws RemoteException {
117 try {
118 com.liferay.portlet.shopping.model.ShoppingCategory returnValue = ShoppingCategoryServiceUtil.updateCategory(categoryId,
119 parentCategoryId, name, description,
120 mergeWithParentCategory, serviceContext);
121
122 return com.liferay.portlet.shopping.model.ShoppingCategorySoap.toSoapModel(returnValue);
123 }
124 catch (Exception e) {
125 _log.error(e, e);
126
127 throw new RemoteException(e.getMessage());
128 }
129 }
130
131 private static Log _log = LogFactoryUtil.getLog(ShoppingCategoryServiceSoap.class);
132 }