001
014
015 package com.liferay.portlet.shopping.service;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020 import com.liferay.portal.kernel.util.ReferenceRegistry;
021
022
036 @ProviderType
037 public class ShoppingCouponLocalServiceUtil {
038
043
044
051 public static com.liferay.portlet.shopping.model.ShoppingCoupon addShoppingCoupon(
052 com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
053 throws com.liferay.portal.kernel.exception.SystemException {
054 return getService().addShoppingCoupon(shoppingCoupon);
055 }
056
057
063 public static com.liferay.portlet.shopping.model.ShoppingCoupon createShoppingCoupon(
064 long couponId) {
065 return getService().createShoppingCoupon(couponId);
066 }
067
068
076 public static com.liferay.portlet.shopping.model.ShoppingCoupon deleteShoppingCoupon(
077 long couponId)
078 throws com.liferay.portal.kernel.exception.PortalException,
079 com.liferay.portal.kernel.exception.SystemException {
080 return getService().deleteShoppingCoupon(couponId);
081 }
082
083
090 public static com.liferay.portlet.shopping.model.ShoppingCoupon deleteShoppingCoupon(
091 com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
092 throws com.liferay.portal.kernel.exception.SystemException {
093 return getService().deleteShoppingCoupon(shoppingCoupon);
094 }
095
096 public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() {
097 return getService().dynamicQuery();
098 }
099
100
107 @SuppressWarnings("rawtypes")
108 public static java.util.List dynamicQuery(
109 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
110 throws com.liferay.portal.kernel.exception.SystemException {
111 return getService().dynamicQuery(dynamicQuery);
112 }
113
114
127 @SuppressWarnings("rawtypes")
128 public static java.util.List dynamicQuery(
129 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
130 int end) throws com.liferay.portal.kernel.exception.SystemException {
131 return getService().dynamicQuery(dynamicQuery, start, end);
132 }
133
134
148 @SuppressWarnings("rawtypes")
149 public static java.util.List dynamicQuery(
150 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
151 int end,
152 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
153 throws com.liferay.portal.kernel.exception.SystemException {
154 return getService()
155 .dynamicQuery(dynamicQuery, start, end, orderByComparator);
156 }
157
158
165 public static long dynamicQueryCount(
166 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
167 throws com.liferay.portal.kernel.exception.SystemException {
168 return getService().dynamicQueryCount(dynamicQuery);
169 }
170
171
179 public static long dynamicQueryCount(
180 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery,
181 com.liferay.portal.kernel.dao.orm.Projection projection)
182 throws com.liferay.portal.kernel.exception.SystemException {
183 return getService().dynamicQueryCount(dynamicQuery, projection);
184 }
185
186 public static com.liferay.portlet.shopping.model.ShoppingCoupon fetchShoppingCoupon(
187 long couponId)
188 throws com.liferay.portal.kernel.exception.SystemException {
189 return getService().fetchShoppingCoupon(couponId);
190 }
191
192
200 public static com.liferay.portlet.shopping.model.ShoppingCoupon getShoppingCoupon(
201 long couponId)
202 throws com.liferay.portal.kernel.exception.PortalException,
203 com.liferay.portal.kernel.exception.SystemException {
204 return getService().getShoppingCoupon(couponId);
205 }
206
207 public static com.liferay.portal.model.PersistedModel getPersistedModel(
208 java.io.Serializable primaryKeyObj)
209 throws com.liferay.portal.kernel.exception.PortalException,
210 com.liferay.portal.kernel.exception.SystemException {
211 return getService().getPersistedModel(primaryKeyObj);
212 }
213
214
226 public static java.util.List<com.liferay.portlet.shopping.model.ShoppingCoupon> getShoppingCoupons(
227 int start, int end)
228 throws com.liferay.portal.kernel.exception.SystemException {
229 return getService().getShoppingCoupons(start, end);
230 }
231
232
238 public static int getShoppingCouponsCount()
239 throws com.liferay.portal.kernel.exception.SystemException {
240 return getService().getShoppingCouponsCount();
241 }
242
243
250 public static com.liferay.portlet.shopping.model.ShoppingCoupon updateShoppingCoupon(
251 com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
252 throws com.liferay.portal.kernel.exception.SystemException {
253 return getService().updateShoppingCoupon(shoppingCoupon);
254 }
255
256
261 public static java.lang.String getBeanIdentifier() {
262 return getService().getBeanIdentifier();
263 }
264
265
270 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
271 getService().setBeanIdentifier(beanIdentifier);
272 }
273
274 public static com.liferay.portlet.shopping.model.ShoppingCoupon addCoupon(
275 long userId, java.lang.String code, boolean autoCode,
276 java.lang.String name, java.lang.String description,
277 int startDateMonth, int startDateDay, int startDateYear,
278 int startDateHour, int startDateMinute, int endDateMonth,
279 int endDateDay, int endDateYear, int endDateHour, int endDateMinute,
280 boolean neverExpire, boolean active, java.lang.String limitCategories,
281 java.lang.String limitSkus, double minOrder, double discount,
282 java.lang.String discountType,
283 com.liferay.portal.service.ServiceContext serviceContext)
284 throws com.liferay.portal.kernel.exception.PortalException,
285 com.liferay.portal.kernel.exception.SystemException {
286 return getService()
287 .addCoupon(userId, code, autoCode, name, description,
288 startDateMonth, startDateDay, startDateYear, startDateHour,
289 startDateMinute, endDateMonth, endDateDay, endDateYear,
290 endDateHour, endDateMinute, neverExpire, active, limitCategories,
291 limitSkus, minOrder, discount, discountType, serviceContext);
292 }
293
294 public static void deleteCoupon(long couponId)
295 throws com.liferay.portal.kernel.exception.PortalException,
296 com.liferay.portal.kernel.exception.SystemException {
297 getService().deleteCoupon(couponId);
298 }
299
300 public static void deleteCoupon(
301 com.liferay.portlet.shopping.model.ShoppingCoupon coupon)
302 throws com.liferay.portal.kernel.exception.SystemException {
303 getService().deleteCoupon(coupon);
304 }
305
306 public static void deleteCoupons(long groupId)
307 throws com.liferay.portal.kernel.exception.SystemException {
308 getService().deleteCoupons(groupId);
309 }
310
311 public static com.liferay.portlet.shopping.model.ShoppingCoupon getCoupon(
312 long couponId)
313 throws com.liferay.portal.kernel.exception.PortalException,
314 com.liferay.portal.kernel.exception.SystemException {
315 return getService().getCoupon(couponId);
316 }
317
318 public static com.liferay.portlet.shopping.model.ShoppingCoupon getCoupon(
319 java.lang.String code)
320 throws com.liferay.portal.kernel.exception.PortalException,
321 com.liferay.portal.kernel.exception.SystemException {
322 return getService().getCoupon(code);
323 }
324
325 public static java.util.List<com.liferay.portlet.shopping.model.ShoppingCoupon> search(
326 long groupId, long companyId, java.lang.String code, boolean active,
327 java.lang.String discountType, boolean andOperator, int start, int end)
328 throws com.liferay.portal.kernel.exception.SystemException {
329 return getService()
330 .search(groupId, companyId, code, active, discountType,
331 andOperator, start, end);
332 }
333
334 public static int searchCount(long groupId, long companyId,
335 java.lang.String code, boolean active, java.lang.String discountType,
336 boolean andOperator)
337 throws com.liferay.portal.kernel.exception.SystemException {
338 return getService()
339 .searchCount(groupId, companyId, code, active, discountType,
340 andOperator);
341 }
342
343 public static com.liferay.portlet.shopping.model.ShoppingCoupon updateCoupon(
344 long userId, long couponId, java.lang.String name,
345 java.lang.String description, int startDateMonth, int startDateDay,
346 int startDateYear, int startDateHour, int startDateMinute,
347 int endDateMonth, int endDateDay, int endDateYear, int endDateHour,
348 int endDateMinute, boolean neverExpire, boolean active,
349 java.lang.String limitCategories, java.lang.String limitSkus,
350 double minOrder, double discount, java.lang.String discountType,
351 com.liferay.portal.service.ServiceContext serviceContext)
352 throws com.liferay.portal.kernel.exception.PortalException,
353 com.liferay.portal.kernel.exception.SystemException {
354 return getService()
355 .updateCoupon(userId, couponId, name, description,
356 startDateMonth, startDateDay, startDateYear, startDateHour,
357 startDateMinute, endDateMonth, endDateDay, endDateYear,
358 endDateHour, endDateMinute, neverExpire, active, limitCategories,
359 limitSkus, minOrder, discount, discountType, serviceContext);
360 }
361
362 public static ShoppingCouponLocalService getService() {
363 if (_service == null) {
364 _service = (ShoppingCouponLocalService)PortalBeanLocatorUtil.locate(ShoppingCouponLocalService.class.getName());
365
366 ReferenceRegistry.registerReference(ShoppingCouponLocalServiceUtil.class,
367 "_service");
368 }
369
370 return _service;
371 }
372
373
376 public void setService(ShoppingCouponLocalService service) {
377 }
378
379 private static ShoppingCouponLocalService _service;
380 }