001
014
015 package com.liferay.portlet.shopping.service.base;
016
017 import com.liferay.portal.kernel.bean.BeanReference;
018 import com.liferay.portal.kernel.bean.IdentifiableBean;
019 import com.liferay.portal.kernel.dao.db.DB;
020 import com.liferay.portal.kernel.dao.db.DBFactoryUtil;
021 import com.liferay.portal.kernel.dao.jdbc.SqlUpdate;
022 import com.liferay.portal.kernel.dao.jdbc.SqlUpdateFactoryUtil;
023 import com.liferay.portal.kernel.exception.SystemException;
024 import com.liferay.portal.service.BaseServiceImpl;
025 import com.liferay.portal.service.persistence.UserFinder;
026 import com.liferay.portal.service.persistence.UserPersistence;
027 import com.liferay.portal.util.PortalUtil;
028
029 import com.liferay.portlet.shopping.model.ShoppingCoupon;
030 import com.liferay.portlet.shopping.service.ShoppingCouponService;
031 import com.liferay.portlet.shopping.service.persistence.ShoppingCategoryPersistence;
032 import com.liferay.portlet.shopping.service.persistence.ShoppingCouponFinder;
033 import com.liferay.portlet.shopping.service.persistence.ShoppingCouponPersistence;
034 import com.liferay.portlet.shopping.service.persistence.ShoppingItemFinder;
035 import com.liferay.portlet.shopping.service.persistence.ShoppingItemPersistence;
036
037 import javax.sql.DataSource;
038
039
051 public abstract class ShoppingCouponServiceBaseImpl extends BaseServiceImpl
052 implements ShoppingCouponService, IdentifiableBean {
053
058
059
064 public com.liferay.portlet.shopping.service.ShoppingCouponLocalService getShoppingCouponLocalService() {
065 return shoppingCouponLocalService;
066 }
067
068
073 public void setShoppingCouponLocalService(
074 com.liferay.portlet.shopping.service.ShoppingCouponLocalService shoppingCouponLocalService) {
075 this.shoppingCouponLocalService = shoppingCouponLocalService;
076 }
077
078
083 public ShoppingCouponService getShoppingCouponService() {
084 return shoppingCouponService;
085 }
086
087
092 public void setShoppingCouponService(
093 ShoppingCouponService shoppingCouponService) {
094 this.shoppingCouponService = shoppingCouponService;
095 }
096
097
102 public ShoppingCouponPersistence getShoppingCouponPersistence() {
103 return shoppingCouponPersistence;
104 }
105
106
111 public void setShoppingCouponPersistence(
112 ShoppingCouponPersistence shoppingCouponPersistence) {
113 this.shoppingCouponPersistence = shoppingCouponPersistence;
114 }
115
116
121 public ShoppingCouponFinder getShoppingCouponFinder() {
122 return shoppingCouponFinder;
123 }
124
125
130 public void setShoppingCouponFinder(
131 ShoppingCouponFinder shoppingCouponFinder) {
132 this.shoppingCouponFinder = shoppingCouponFinder;
133 }
134
135
140 public com.liferay.counter.service.CounterLocalService getCounterLocalService() {
141 return counterLocalService;
142 }
143
144
149 public void setCounterLocalService(
150 com.liferay.counter.service.CounterLocalService counterLocalService) {
151 this.counterLocalService = counterLocalService;
152 }
153
154
159 public com.liferay.portal.service.UserLocalService getUserLocalService() {
160 return userLocalService;
161 }
162
163
168 public void setUserLocalService(
169 com.liferay.portal.service.UserLocalService userLocalService) {
170 this.userLocalService = userLocalService;
171 }
172
173
178 public com.liferay.portal.service.UserService getUserService() {
179 return userService;
180 }
181
182
187 public void setUserService(
188 com.liferay.portal.service.UserService userService) {
189 this.userService = userService;
190 }
191
192
197 public UserPersistence getUserPersistence() {
198 return userPersistence;
199 }
200
201
206 public void setUserPersistence(UserPersistence userPersistence) {
207 this.userPersistence = userPersistence;
208 }
209
210
215 public UserFinder getUserFinder() {
216 return userFinder;
217 }
218
219
224 public void setUserFinder(UserFinder userFinder) {
225 this.userFinder = userFinder;
226 }
227
228
233 public com.liferay.portlet.shopping.service.ShoppingCategoryLocalService getShoppingCategoryLocalService() {
234 return shoppingCategoryLocalService;
235 }
236
237
242 public void setShoppingCategoryLocalService(
243 com.liferay.portlet.shopping.service.ShoppingCategoryLocalService shoppingCategoryLocalService) {
244 this.shoppingCategoryLocalService = shoppingCategoryLocalService;
245 }
246
247
252 public com.liferay.portlet.shopping.service.ShoppingCategoryService getShoppingCategoryService() {
253 return shoppingCategoryService;
254 }
255
256
261 public void setShoppingCategoryService(
262 com.liferay.portlet.shopping.service.ShoppingCategoryService shoppingCategoryService) {
263 this.shoppingCategoryService = shoppingCategoryService;
264 }
265
266
271 public ShoppingCategoryPersistence getShoppingCategoryPersistence() {
272 return shoppingCategoryPersistence;
273 }
274
275
280 public void setShoppingCategoryPersistence(
281 ShoppingCategoryPersistence shoppingCategoryPersistence) {
282 this.shoppingCategoryPersistence = shoppingCategoryPersistence;
283 }
284
285
290 public com.liferay.portlet.shopping.service.ShoppingItemLocalService getShoppingItemLocalService() {
291 return shoppingItemLocalService;
292 }
293
294
299 public void setShoppingItemLocalService(
300 com.liferay.portlet.shopping.service.ShoppingItemLocalService shoppingItemLocalService) {
301 this.shoppingItemLocalService = shoppingItemLocalService;
302 }
303
304
309 public com.liferay.portlet.shopping.service.ShoppingItemService getShoppingItemService() {
310 return shoppingItemService;
311 }
312
313
318 public void setShoppingItemService(
319 com.liferay.portlet.shopping.service.ShoppingItemService shoppingItemService) {
320 this.shoppingItemService = shoppingItemService;
321 }
322
323
328 public ShoppingItemPersistence getShoppingItemPersistence() {
329 return shoppingItemPersistence;
330 }
331
332
337 public void setShoppingItemPersistence(
338 ShoppingItemPersistence shoppingItemPersistence) {
339 this.shoppingItemPersistence = shoppingItemPersistence;
340 }
341
342
347 public ShoppingItemFinder getShoppingItemFinder() {
348 return shoppingItemFinder;
349 }
350
351
356 public void setShoppingItemFinder(ShoppingItemFinder shoppingItemFinder) {
357 this.shoppingItemFinder = shoppingItemFinder;
358 }
359
360 public void afterPropertiesSet() {
361 }
362
363 public void destroy() {
364 }
365
366
371 @Override
372 public String getBeanIdentifier() {
373 return _beanIdentifier;
374 }
375
376
381 @Override
382 public void setBeanIdentifier(String beanIdentifier) {
383 _beanIdentifier = beanIdentifier;
384 }
385
386 protected Class<?> getModelClass() {
387 return ShoppingCoupon.class;
388 }
389
390 protected String getModelClassName() {
391 return ShoppingCoupon.class.getName();
392 }
393
394
399 protected void runSQL(String sql) {
400 try {
401 DataSource dataSource = shoppingCouponPersistence.getDataSource();
402
403 DB db = DBFactoryUtil.getDB();
404
405 sql = db.buildSQL(sql);
406 sql = PortalUtil.transformSQL(sql);
407
408 SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
409 sql, new int[0]);
410
411 sqlUpdate.update();
412 }
413 catch (Exception e) {
414 throw new SystemException(e);
415 }
416 }
417
418 @BeanReference(type = com.liferay.portlet.shopping.service.ShoppingCouponLocalService.class)
419 protected com.liferay.portlet.shopping.service.ShoppingCouponLocalService shoppingCouponLocalService;
420 @BeanReference(type = ShoppingCouponService.class)
421 protected ShoppingCouponService shoppingCouponService;
422 @BeanReference(type = ShoppingCouponPersistence.class)
423 protected ShoppingCouponPersistence shoppingCouponPersistence;
424 @BeanReference(type = ShoppingCouponFinder.class)
425 protected ShoppingCouponFinder shoppingCouponFinder;
426 @BeanReference(type = com.liferay.counter.service.CounterLocalService.class)
427 protected com.liferay.counter.service.CounterLocalService counterLocalService;
428 @BeanReference(type = com.liferay.portal.service.UserLocalService.class)
429 protected com.liferay.portal.service.UserLocalService userLocalService;
430 @BeanReference(type = com.liferay.portal.service.UserService.class)
431 protected com.liferay.portal.service.UserService userService;
432 @BeanReference(type = UserPersistence.class)
433 protected UserPersistence userPersistence;
434 @BeanReference(type = UserFinder.class)
435 protected UserFinder userFinder;
436 @BeanReference(type = com.liferay.portlet.shopping.service.ShoppingCategoryLocalService.class)
437 protected com.liferay.portlet.shopping.service.ShoppingCategoryLocalService shoppingCategoryLocalService;
438 @BeanReference(type = com.liferay.portlet.shopping.service.ShoppingCategoryService.class)
439 protected com.liferay.portlet.shopping.service.ShoppingCategoryService shoppingCategoryService;
440 @BeanReference(type = ShoppingCategoryPersistence.class)
441 protected ShoppingCategoryPersistence shoppingCategoryPersistence;
442 @BeanReference(type = com.liferay.portlet.shopping.service.ShoppingItemLocalService.class)
443 protected com.liferay.portlet.shopping.service.ShoppingItemLocalService shoppingItemLocalService;
444 @BeanReference(type = com.liferay.portlet.shopping.service.ShoppingItemService.class)
445 protected com.liferay.portlet.shopping.service.ShoppingItemService shoppingItemService;
446 @BeanReference(type = ShoppingItemPersistence.class)
447 protected ShoppingItemPersistence shoppingItemPersistence;
448 @BeanReference(type = ShoppingItemFinder.class)
449 protected ShoppingItemFinder shoppingItemFinder;
450 private String _beanIdentifier;
451 }