001    /**
002     * Copyright (c) 2000-2012 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 com.liferay.portal.service.ServiceWrapper;
018    
019    /**
020     * <p>
021     * This class is a wrapper for {@link ShoppingCouponLocalService}.
022     * </p>
023     *
024     * @author    Brian Wing Shun Chan
025     * @see       ShoppingCouponLocalService
026     * @generated
027     */
028    public class ShoppingCouponLocalServiceWrapper
029            implements ShoppingCouponLocalService,
030                    ServiceWrapper<ShoppingCouponLocalService> {
031            public ShoppingCouponLocalServiceWrapper(
032                    ShoppingCouponLocalService shoppingCouponLocalService) {
033                    _shoppingCouponLocalService = shoppingCouponLocalService;
034            }
035    
036            /**
037            * Adds the shopping coupon to the database. Also notifies the appropriate model listeners.
038            *
039            * @param shoppingCoupon the shopping coupon
040            * @return the shopping coupon that was added
041            * @throws SystemException if a system exception occurred
042            */
043            public com.liferay.portlet.shopping.model.ShoppingCoupon addShoppingCoupon(
044                    com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
045                    throws com.liferay.portal.kernel.exception.SystemException {
046                    return _shoppingCouponLocalService.addShoppingCoupon(shoppingCoupon);
047            }
048    
049            /**
050            * Creates a new shopping coupon with the primary key. Does not add the shopping coupon to the database.
051            *
052            * @param couponId the primary key for the new shopping coupon
053            * @return the new shopping coupon
054            */
055            public com.liferay.portlet.shopping.model.ShoppingCoupon createShoppingCoupon(
056                    long couponId) {
057                    return _shoppingCouponLocalService.createShoppingCoupon(couponId);
058            }
059    
060            /**
061            * Deletes the shopping coupon with the primary key from the database. Also notifies the appropriate model listeners.
062            *
063            * @param couponId the primary key of the shopping coupon
064            * @throws PortalException if a shopping coupon with the primary key could not be found
065            * @throws SystemException if a system exception occurred
066            */
067            public void deleteShoppingCoupon(long couponId)
068                    throws com.liferay.portal.kernel.exception.PortalException,
069                            com.liferay.portal.kernel.exception.SystemException {
070                    _shoppingCouponLocalService.deleteShoppingCoupon(couponId);
071            }
072    
073            /**
074            * Deletes the shopping coupon from the database. Also notifies the appropriate model listeners.
075            *
076            * @param shoppingCoupon the shopping coupon
077            * @throws SystemException if a system exception occurred
078            */
079            public void deleteShoppingCoupon(
080                    com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
081                    throws com.liferay.portal.kernel.exception.SystemException {
082                    _shoppingCouponLocalService.deleteShoppingCoupon(shoppingCoupon);
083            }
084    
085            /**
086            * Performs a dynamic query on the database and returns the matching rows.
087            *
088            * @param dynamicQuery the dynamic query
089            * @return the matching rows
090            * @throws SystemException if a system exception occurred
091            */
092            @SuppressWarnings("rawtypes")
093            public java.util.List dynamicQuery(
094                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
095                    throws com.liferay.portal.kernel.exception.SystemException {
096                    return _shoppingCouponLocalService.dynamicQuery(dynamicQuery);
097            }
098    
099            /**
100            * Performs a dynamic query on the database and returns a range of the matching rows.
101            *
102            * <p>
103            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
104            * </p>
105            *
106            * @param dynamicQuery the dynamic query
107            * @param start the lower bound of the range of model instances
108            * @param end the upper bound of the range of model instances (not inclusive)
109            * @return the range of matching rows
110            * @throws SystemException if a system exception occurred
111            */
112            @SuppressWarnings("rawtypes")
113            public java.util.List dynamicQuery(
114                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
115                    int end) throws com.liferay.portal.kernel.exception.SystemException {
116                    return _shoppingCouponLocalService.dynamicQuery(dynamicQuery, start, end);
117            }
118    
119            /**
120            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
121            *
122            * <p>
123            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
124            * </p>
125            *
126            * @param dynamicQuery the dynamic query
127            * @param start the lower bound of the range of model instances
128            * @param end the upper bound of the range of model instances (not inclusive)
129            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
130            * @return the ordered range of matching rows
131            * @throws SystemException if a system exception occurred
132            */
133            @SuppressWarnings("rawtypes")
134            public java.util.List dynamicQuery(
135                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
136                    int end,
137                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
138                    throws com.liferay.portal.kernel.exception.SystemException {
139                    return _shoppingCouponLocalService.dynamicQuery(dynamicQuery, start,
140                            end, orderByComparator);
141            }
142    
143            /**
144            * Returns the number of rows that match the dynamic query.
145            *
146            * @param dynamicQuery the dynamic query
147            * @return the number of rows that match the dynamic query
148            * @throws SystemException if a system exception occurred
149            */
150            public long dynamicQueryCount(
151                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
152                    throws com.liferay.portal.kernel.exception.SystemException {
153                    return _shoppingCouponLocalService.dynamicQueryCount(dynamicQuery);
154            }
155    
156            public com.liferay.portlet.shopping.model.ShoppingCoupon fetchShoppingCoupon(
157                    long couponId)
158                    throws com.liferay.portal.kernel.exception.SystemException {
159                    return _shoppingCouponLocalService.fetchShoppingCoupon(couponId);
160            }
161    
162            /**
163            * Returns the shopping coupon with the primary key.
164            *
165            * @param couponId the primary key of the shopping coupon
166            * @return the shopping coupon
167            * @throws PortalException if a shopping coupon with the primary key could not be found
168            * @throws SystemException if a system exception occurred
169            */
170            public com.liferay.portlet.shopping.model.ShoppingCoupon getShoppingCoupon(
171                    long couponId)
172                    throws com.liferay.portal.kernel.exception.PortalException,
173                            com.liferay.portal.kernel.exception.SystemException {
174                    return _shoppingCouponLocalService.getShoppingCoupon(couponId);
175            }
176    
177            public com.liferay.portal.model.PersistedModel getPersistedModel(
178                    java.io.Serializable primaryKeyObj)
179                    throws com.liferay.portal.kernel.exception.PortalException,
180                            com.liferay.portal.kernel.exception.SystemException {
181                    return _shoppingCouponLocalService.getPersistedModel(primaryKeyObj);
182            }
183    
184            /**
185            * Returns a range of all the shopping coupons.
186            *
187            * <p>
188            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
189            * </p>
190            *
191            * @param start the lower bound of the range of shopping coupons
192            * @param end the upper bound of the range of shopping coupons (not inclusive)
193            * @return the range of shopping coupons
194            * @throws SystemException if a system exception occurred
195            */
196            public java.util.List<com.liferay.portlet.shopping.model.ShoppingCoupon> getShoppingCoupons(
197                    int start, int end)
198                    throws com.liferay.portal.kernel.exception.SystemException {
199                    return _shoppingCouponLocalService.getShoppingCoupons(start, end);
200            }
201    
202            /**
203            * Returns the number of shopping coupons.
204            *
205            * @return the number of shopping coupons
206            * @throws SystemException if a system exception occurred
207            */
208            public int getShoppingCouponsCount()
209                    throws com.liferay.portal.kernel.exception.SystemException {
210                    return _shoppingCouponLocalService.getShoppingCouponsCount();
211            }
212    
213            /**
214            * Updates the shopping coupon in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
215            *
216            * @param shoppingCoupon the shopping coupon
217            * @return the shopping coupon that was updated
218            * @throws SystemException if a system exception occurred
219            */
220            public com.liferay.portlet.shopping.model.ShoppingCoupon updateShoppingCoupon(
221                    com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
222                    throws com.liferay.portal.kernel.exception.SystemException {
223                    return _shoppingCouponLocalService.updateShoppingCoupon(shoppingCoupon);
224            }
225    
226            /**
227            * Updates the shopping coupon in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
228            *
229            * @param shoppingCoupon the shopping coupon
230            * @param merge whether to merge the shopping coupon with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
231            * @return the shopping coupon that was updated
232            * @throws SystemException if a system exception occurred
233            */
234            public com.liferay.portlet.shopping.model.ShoppingCoupon updateShoppingCoupon(
235                    com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon,
236                    boolean merge)
237                    throws com.liferay.portal.kernel.exception.SystemException {
238                    return _shoppingCouponLocalService.updateShoppingCoupon(shoppingCoupon,
239                            merge);
240            }
241    
242            /**
243            * Returns the Spring bean ID for this bean.
244            *
245            * @return the Spring bean ID for this bean
246            */
247            public java.lang.String getBeanIdentifier() {
248                    return _shoppingCouponLocalService.getBeanIdentifier();
249            }
250    
251            /**
252            * Sets the Spring bean ID for this bean.
253            *
254            * @param beanIdentifier the Spring bean ID for this bean
255            */
256            public void setBeanIdentifier(java.lang.String beanIdentifier) {
257                    _shoppingCouponLocalService.setBeanIdentifier(beanIdentifier);
258            }
259    
260            public com.liferay.portlet.shopping.model.ShoppingCoupon addCoupon(
261                    long userId, java.lang.String code, boolean autoCode,
262                    java.lang.String name, java.lang.String description,
263                    int startDateMonth, int startDateDay, int startDateYear,
264                    int startDateHour, int startDateMinute, int endDateMonth,
265                    int endDateDay, int endDateYear, int endDateHour, int endDateMinute,
266                    boolean neverExpire, boolean active, java.lang.String limitCategories,
267                    java.lang.String limitSkus, double minOrder, double discount,
268                    java.lang.String discountType,
269                    com.liferay.portal.service.ServiceContext serviceContext)
270                    throws com.liferay.portal.kernel.exception.PortalException,
271                            com.liferay.portal.kernel.exception.SystemException {
272                    return _shoppingCouponLocalService.addCoupon(userId, code, autoCode,
273                            name, description, startDateMonth, startDateDay, startDateYear,
274                            startDateHour, startDateMinute, endDateMonth, endDateDay,
275                            endDateYear, endDateHour, endDateMinute, neverExpire, active,
276                            limitCategories, limitSkus, minOrder, discount, discountType,
277                            serviceContext);
278            }
279    
280            public void deleteCoupon(long couponId)
281                    throws com.liferay.portal.kernel.exception.PortalException,
282                            com.liferay.portal.kernel.exception.SystemException {
283                    _shoppingCouponLocalService.deleteCoupon(couponId);
284            }
285    
286            public void deleteCoupon(
287                    com.liferay.portlet.shopping.model.ShoppingCoupon coupon)
288                    throws com.liferay.portal.kernel.exception.SystemException {
289                    _shoppingCouponLocalService.deleteCoupon(coupon);
290            }
291    
292            public void deleteCoupons(long groupId)
293                    throws com.liferay.portal.kernel.exception.SystemException {
294                    _shoppingCouponLocalService.deleteCoupons(groupId);
295            }
296    
297            public com.liferay.portlet.shopping.model.ShoppingCoupon getCoupon(
298                    long couponId)
299                    throws com.liferay.portal.kernel.exception.PortalException,
300                            com.liferay.portal.kernel.exception.SystemException {
301                    return _shoppingCouponLocalService.getCoupon(couponId);
302            }
303    
304            public com.liferay.portlet.shopping.model.ShoppingCoupon getCoupon(
305                    java.lang.String code)
306                    throws com.liferay.portal.kernel.exception.PortalException,
307                            com.liferay.portal.kernel.exception.SystemException {
308                    return _shoppingCouponLocalService.getCoupon(code);
309            }
310    
311            public java.util.List<com.liferay.portlet.shopping.model.ShoppingCoupon> search(
312                    long groupId, long companyId, java.lang.String code, boolean active,
313                    java.lang.String discountType, boolean andOperator, int start, int end)
314                    throws com.liferay.portal.kernel.exception.SystemException {
315                    return _shoppingCouponLocalService.search(groupId, companyId, code,
316                            active, discountType, andOperator, start, end);
317            }
318    
319            public int searchCount(long groupId, long companyId, java.lang.String code,
320                    boolean active, java.lang.String discountType, boolean andOperator)
321                    throws com.liferay.portal.kernel.exception.SystemException {
322                    return _shoppingCouponLocalService.searchCount(groupId, companyId,
323                            code, active, discountType, andOperator);
324            }
325    
326            public com.liferay.portlet.shopping.model.ShoppingCoupon updateCoupon(
327                    long userId, long couponId, java.lang.String name,
328                    java.lang.String description, int startDateMonth, int startDateDay,
329                    int startDateYear, int startDateHour, int startDateMinute,
330                    int endDateMonth, int endDateDay, int endDateYear, int endDateHour,
331                    int endDateMinute, boolean neverExpire, boolean active,
332                    java.lang.String limitCategories, java.lang.String limitSkus,
333                    double minOrder, double discount, java.lang.String discountType,
334                    com.liferay.portal.service.ServiceContext serviceContext)
335                    throws com.liferay.portal.kernel.exception.PortalException,
336                            com.liferay.portal.kernel.exception.SystemException {
337                    return _shoppingCouponLocalService.updateCoupon(userId, couponId, name,
338                            description, startDateMonth, startDateDay, startDateYear,
339                            startDateHour, startDateMinute, endDateMonth, endDateDay,
340                            endDateYear, endDateHour, endDateMinute, neverExpire, active,
341                            limitCategories, limitSkus, minOrder, discount, discountType,
342                            serviceContext);
343            }
344    
345            /**
346             * @deprecated Renamed to {@link #getWrappedService}
347             */
348            public ShoppingCouponLocalService getWrappedShoppingCouponLocalService() {
349                    return _shoppingCouponLocalService;
350            }
351    
352            /**
353             * @deprecated Renamed to {@link #setWrappedService}
354             */
355            public void setWrappedShoppingCouponLocalService(
356                    ShoppingCouponLocalService shoppingCouponLocalService) {
357                    _shoppingCouponLocalService = shoppingCouponLocalService;
358            }
359    
360            public ShoppingCouponLocalService getWrappedService() {
361                    return _shoppingCouponLocalService;
362            }
363    
364            public void setWrappedService(
365                    ShoppingCouponLocalService shoppingCouponLocalService) {
366                    _shoppingCouponLocalService = shoppingCouponLocalService;
367            }
368    
369            private ShoppingCouponLocalService _shoppingCouponLocalService;
370    }