001    /**
002     * Copyright (c) 2000-present 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.mobiledevicerules.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.GroupFinder;
026    import com.liferay.portal.service.persistence.GroupPersistence;
027    import com.liferay.portal.service.persistence.SystemEventPersistence;
028    import com.liferay.portal.service.persistence.UserFinder;
029    import com.liferay.portal.service.persistence.UserPersistence;
030    import com.liferay.portal.util.PortalUtil;
031    
032    import com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup;
033    import com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupService;
034    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRuleGroupFinder;
035    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRuleGroupInstancePersistence;
036    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRuleGroupPersistence;
037    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRulePersistence;
038    
039    import javax.sql.DataSource;
040    
041    /**
042     * Provides the base implementation for the m d r rule group remote service.
043     *
044     * <p>
045     * This implementation exists only as a container for the default service methods generated by ServiceBuilder. All custom service methods should be put in {@link com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleGroupServiceImpl}.
046     * </p>
047     *
048     * @author Edward C. Han
049     * @see com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleGroupServiceImpl
050     * @see com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupServiceUtil
051     * @generated
052     */
053    public abstract class MDRRuleGroupServiceBaseImpl extends BaseServiceImpl
054            implements MDRRuleGroupService, IdentifiableBean {
055            /*
056             * NOTE FOR DEVELOPERS:
057             *
058             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupServiceUtil} to access the m d r rule group remote service.
059             */
060    
061            /**
062             * Returns the m d r rule group local service.
063             *
064             * @return the m d r rule group local service
065             */
066            public com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalService getMDRRuleGroupLocalService() {
067                    return mdrRuleGroupLocalService;
068            }
069    
070            /**
071             * Sets the m d r rule group local service.
072             *
073             * @param mdrRuleGroupLocalService the m d r rule group local service
074             */
075            public void setMDRRuleGroupLocalService(
076                    com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalService mdrRuleGroupLocalService) {
077                    this.mdrRuleGroupLocalService = mdrRuleGroupLocalService;
078            }
079    
080            /**
081             * Returns the m d r rule group remote service.
082             *
083             * @return the m d r rule group remote service
084             */
085            public MDRRuleGroupService getMDRRuleGroupService() {
086                    return mdrRuleGroupService;
087            }
088    
089            /**
090             * Sets the m d r rule group remote service.
091             *
092             * @param mdrRuleGroupService the m d r rule group remote service
093             */
094            public void setMDRRuleGroupService(MDRRuleGroupService mdrRuleGroupService) {
095                    this.mdrRuleGroupService = mdrRuleGroupService;
096            }
097    
098            /**
099             * Returns the m d r rule group persistence.
100             *
101             * @return the m d r rule group persistence
102             */
103            public MDRRuleGroupPersistence getMDRRuleGroupPersistence() {
104                    return mdrRuleGroupPersistence;
105            }
106    
107            /**
108             * Sets the m d r rule group persistence.
109             *
110             * @param mdrRuleGroupPersistence the m d r rule group persistence
111             */
112            public void setMDRRuleGroupPersistence(
113                    MDRRuleGroupPersistence mdrRuleGroupPersistence) {
114                    this.mdrRuleGroupPersistence = mdrRuleGroupPersistence;
115            }
116    
117            /**
118             * Returns the m d r rule group finder.
119             *
120             * @return the m d r rule group finder
121             */
122            public MDRRuleGroupFinder getMDRRuleGroupFinder() {
123                    return mdrRuleGroupFinder;
124            }
125    
126            /**
127             * Sets the m d r rule group finder.
128             *
129             * @param mdrRuleGroupFinder the m d r rule group finder
130             */
131            public void setMDRRuleGroupFinder(MDRRuleGroupFinder mdrRuleGroupFinder) {
132                    this.mdrRuleGroupFinder = mdrRuleGroupFinder;
133            }
134    
135            /**
136             * Returns the counter local service.
137             *
138             * @return the counter local service
139             */
140            public com.liferay.counter.service.CounterLocalService getCounterLocalService() {
141                    return counterLocalService;
142            }
143    
144            /**
145             * Sets the counter local service.
146             *
147             * @param counterLocalService the counter local service
148             */
149            public void setCounterLocalService(
150                    com.liferay.counter.service.CounterLocalService counterLocalService) {
151                    this.counterLocalService = counterLocalService;
152            }
153    
154            /**
155             * Returns the group local service.
156             *
157             * @return the group local service
158             */
159            public com.liferay.portal.service.GroupLocalService getGroupLocalService() {
160                    return groupLocalService;
161            }
162    
163            /**
164             * Sets the group local service.
165             *
166             * @param groupLocalService the group local service
167             */
168            public void setGroupLocalService(
169                    com.liferay.portal.service.GroupLocalService groupLocalService) {
170                    this.groupLocalService = groupLocalService;
171            }
172    
173            /**
174             * Returns the group remote service.
175             *
176             * @return the group remote service
177             */
178            public com.liferay.portal.service.GroupService getGroupService() {
179                    return groupService;
180            }
181    
182            /**
183             * Sets the group remote service.
184             *
185             * @param groupService the group remote service
186             */
187            public void setGroupService(
188                    com.liferay.portal.service.GroupService groupService) {
189                    this.groupService = groupService;
190            }
191    
192            /**
193             * Returns the group persistence.
194             *
195             * @return the group persistence
196             */
197            public GroupPersistence getGroupPersistence() {
198                    return groupPersistence;
199            }
200    
201            /**
202             * Sets the group persistence.
203             *
204             * @param groupPersistence the group persistence
205             */
206            public void setGroupPersistence(GroupPersistence groupPersistence) {
207                    this.groupPersistence = groupPersistence;
208            }
209    
210            /**
211             * Returns the group finder.
212             *
213             * @return the group finder
214             */
215            public GroupFinder getGroupFinder() {
216                    return groupFinder;
217            }
218    
219            /**
220             * Sets the group finder.
221             *
222             * @param groupFinder the group finder
223             */
224            public void setGroupFinder(GroupFinder groupFinder) {
225                    this.groupFinder = groupFinder;
226            }
227    
228            /**
229             * Returns the system event local service.
230             *
231             * @return the system event local service
232             */
233            public com.liferay.portal.service.SystemEventLocalService getSystemEventLocalService() {
234                    return systemEventLocalService;
235            }
236    
237            /**
238             * Sets the system event local service.
239             *
240             * @param systemEventLocalService the system event local service
241             */
242            public void setSystemEventLocalService(
243                    com.liferay.portal.service.SystemEventLocalService systemEventLocalService) {
244                    this.systemEventLocalService = systemEventLocalService;
245            }
246    
247            /**
248             * Returns the system event persistence.
249             *
250             * @return the system event persistence
251             */
252            public SystemEventPersistence getSystemEventPersistence() {
253                    return systemEventPersistence;
254            }
255    
256            /**
257             * Sets the system event persistence.
258             *
259             * @param systemEventPersistence the system event persistence
260             */
261            public void setSystemEventPersistence(
262                    SystemEventPersistence systemEventPersistence) {
263                    this.systemEventPersistence = systemEventPersistence;
264            }
265    
266            /**
267             * Returns the user local service.
268             *
269             * @return the user local service
270             */
271            public com.liferay.portal.service.UserLocalService getUserLocalService() {
272                    return userLocalService;
273            }
274    
275            /**
276             * Sets the user local service.
277             *
278             * @param userLocalService the user local service
279             */
280            public void setUserLocalService(
281                    com.liferay.portal.service.UserLocalService userLocalService) {
282                    this.userLocalService = userLocalService;
283            }
284    
285            /**
286             * Returns the user remote service.
287             *
288             * @return the user remote service
289             */
290            public com.liferay.portal.service.UserService getUserService() {
291                    return userService;
292            }
293    
294            /**
295             * Sets the user remote service.
296             *
297             * @param userService the user remote service
298             */
299            public void setUserService(
300                    com.liferay.portal.service.UserService userService) {
301                    this.userService = userService;
302            }
303    
304            /**
305             * Returns the user persistence.
306             *
307             * @return the user persistence
308             */
309            public UserPersistence getUserPersistence() {
310                    return userPersistence;
311            }
312    
313            /**
314             * Sets the user persistence.
315             *
316             * @param userPersistence the user persistence
317             */
318            public void setUserPersistence(UserPersistence userPersistence) {
319                    this.userPersistence = userPersistence;
320            }
321    
322            /**
323             * Returns the user finder.
324             *
325             * @return the user finder
326             */
327            public UserFinder getUserFinder() {
328                    return userFinder;
329            }
330    
331            /**
332             * Sets the user finder.
333             *
334             * @param userFinder the user finder
335             */
336            public void setUserFinder(UserFinder userFinder) {
337                    this.userFinder = userFinder;
338            }
339    
340            /**
341             * Returns the m d r rule local service.
342             *
343             * @return the m d r rule local service
344             */
345            public com.liferay.portlet.mobiledevicerules.service.MDRRuleLocalService getMDRRuleLocalService() {
346                    return mdrRuleLocalService;
347            }
348    
349            /**
350             * Sets the m d r rule local service.
351             *
352             * @param mdrRuleLocalService the m d r rule local service
353             */
354            public void setMDRRuleLocalService(
355                    com.liferay.portlet.mobiledevicerules.service.MDRRuleLocalService mdrRuleLocalService) {
356                    this.mdrRuleLocalService = mdrRuleLocalService;
357            }
358    
359            /**
360             * Returns the m d r rule remote service.
361             *
362             * @return the m d r rule remote service
363             */
364            public com.liferay.portlet.mobiledevicerules.service.MDRRuleService getMDRRuleService() {
365                    return mdrRuleService;
366            }
367    
368            /**
369             * Sets the m d r rule remote service.
370             *
371             * @param mdrRuleService the m d r rule remote service
372             */
373            public void setMDRRuleService(
374                    com.liferay.portlet.mobiledevicerules.service.MDRRuleService mdrRuleService) {
375                    this.mdrRuleService = mdrRuleService;
376            }
377    
378            /**
379             * Returns the m d r rule persistence.
380             *
381             * @return the m d r rule persistence
382             */
383            public MDRRulePersistence getMDRRulePersistence() {
384                    return mdrRulePersistence;
385            }
386    
387            /**
388             * Sets the m d r rule persistence.
389             *
390             * @param mdrRulePersistence the m d r rule persistence
391             */
392            public void setMDRRulePersistence(MDRRulePersistence mdrRulePersistence) {
393                    this.mdrRulePersistence = mdrRulePersistence;
394            }
395    
396            /**
397             * Returns the m d r rule group instance local service.
398             *
399             * @return the m d r rule group instance local service
400             */
401            public com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceLocalService getMDRRuleGroupInstanceLocalService() {
402                    return mdrRuleGroupInstanceLocalService;
403            }
404    
405            /**
406             * Sets the m d r rule group instance local service.
407             *
408             * @param mdrRuleGroupInstanceLocalService the m d r rule group instance local service
409             */
410            public void setMDRRuleGroupInstanceLocalService(
411                    com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceLocalService mdrRuleGroupInstanceLocalService) {
412                    this.mdrRuleGroupInstanceLocalService = mdrRuleGroupInstanceLocalService;
413            }
414    
415            /**
416             * Returns the m d r rule group instance remote service.
417             *
418             * @return the m d r rule group instance remote service
419             */
420            public com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceService getMDRRuleGroupInstanceService() {
421                    return mdrRuleGroupInstanceService;
422            }
423    
424            /**
425             * Sets the m d r rule group instance remote service.
426             *
427             * @param mdrRuleGroupInstanceService the m d r rule group instance remote service
428             */
429            public void setMDRRuleGroupInstanceService(
430                    com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceService mdrRuleGroupInstanceService) {
431                    this.mdrRuleGroupInstanceService = mdrRuleGroupInstanceService;
432            }
433    
434            /**
435             * Returns the m d r rule group instance persistence.
436             *
437             * @return the m d r rule group instance persistence
438             */
439            public MDRRuleGroupInstancePersistence getMDRRuleGroupInstancePersistence() {
440                    return mdrRuleGroupInstancePersistence;
441            }
442    
443            /**
444             * Sets the m d r rule group instance persistence.
445             *
446             * @param mdrRuleGroupInstancePersistence the m d r rule group instance persistence
447             */
448            public void setMDRRuleGroupInstancePersistence(
449                    MDRRuleGroupInstancePersistence mdrRuleGroupInstancePersistence) {
450                    this.mdrRuleGroupInstancePersistence = mdrRuleGroupInstancePersistence;
451            }
452    
453            public void afterPropertiesSet() {
454            }
455    
456            public void destroy() {
457            }
458    
459            /**
460             * Returns the Spring bean ID for this bean.
461             *
462             * @return the Spring bean ID for this bean
463             */
464            @Override
465            public String getBeanIdentifier() {
466                    return _beanIdentifier;
467            }
468    
469            /**
470             * Sets the Spring bean ID for this bean.
471             *
472             * @param beanIdentifier the Spring bean ID for this bean
473             */
474            @Override
475            public void setBeanIdentifier(String beanIdentifier) {
476                    _beanIdentifier = beanIdentifier;
477            }
478    
479            protected Class<?> getModelClass() {
480                    return MDRRuleGroup.class;
481            }
482    
483            protected String getModelClassName() {
484                    return MDRRuleGroup.class.getName();
485            }
486    
487            /**
488             * Performs a SQL query.
489             *
490             * @param sql the sql query
491             */
492            protected void runSQL(String sql) {
493                    try {
494                            DataSource dataSource = mdrRuleGroupPersistence.getDataSource();
495    
496                            DB db = DBFactoryUtil.getDB();
497    
498                            sql = db.buildSQL(sql);
499                            sql = PortalUtil.transformSQL(sql);
500    
501                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
502                                            sql, new int[0]);
503    
504                            sqlUpdate.update();
505                    }
506                    catch (Exception e) {
507                            throw new SystemException(e);
508                    }
509            }
510    
511            @BeanReference(type = com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalService.class)
512            protected com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalService mdrRuleGroupLocalService;
513            @BeanReference(type = MDRRuleGroupService.class)
514            protected MDRRuleGroupService mdrRuleGroupService;
515            @BeanReference(type = MDRRuleGroupPersistence.class)
516            protected MDRRuleGroupPersistence mdrRuleGroupPersistence;
517            @BeanReference(type = MDRRuleGroupFinder.class)
518            protected MDRRuleGroupFinder mdrRuleGroupFinder;
519            @BeanReference(type = com.liferay.counter.service.CounterLocalService.class)
520            protected com.liferay.counter.service.CounterLocalService counterLocalService;
521            @BeanReference(type = com.liferay.portal.service.GroupLocalService.class)
522            protected com.liferay.portal.service.GroupLocalService groupLocalService;
523            @BeanReference(type = com.liferay.portal.service.GroupService.class)
524            protected com.liferay.portal.service.GroupService groupService;
525            @BeanReference(type = GroupPersistence.class)
526            protected GroupPersistence groupPersistence;
527            @BeanReference(type = GroupFinder.class)
528            protected GroupFinder groupFinder;
529            @BeanReference(type = com.liferay.portal.service.SystemEventLocalService.class)
530            protected com.liferay.portal.service.SystemEventLocalService systemEventLocalService;
531            @BeanReference(type = SystemEventPersistence.class)
532            protected SystemEventPersistence systemEventPersistence;
533            @BeanReference(type = com.liferay.portal.service.UserLocalService.class)
534            protected com.liferay.portal.service.UserLocalService userLocalService;
535            @BeanReference(type = com.liferay.portal.service.UserService.class)
536            protected com.liferay.portal.service.UserService userService;
537            @BeanReference(type = UserPersistence.class)
538            protected UserPersistence userPersistence;
539            @BeanReference(type = UserFinder.class)
540            protected UserFinder userFinder;
541            @BeanReference(type = com.liferay.portlet.mobiledevicerules.service.MDRRuleLocalService.class)
542            protected com.liferay.portlet.mobiledevicerules.service.MDRRuleLocalService mdrRuleLocalService;
543            @BeanReference(type = com.liferay.portlet.mobiledevicerules.service.MDRRuleService.class)
544            protected com.liferay.portlet.mobiledevicerules.service.MDRRuleService mdrRuleService;
545            @BeanReference(type = MDRRulePersistence.class)
546            protected MDRRulePersistence mdrRulePersistence;
547            @BeanReference(type = com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceLocalService.class)
548            protected com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceLocalService mdrRuleGroupInstanceLocalService;
549            @BeanReference(type = com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceService.class)
550            protected com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceService mdrRuleGroupInstanceService;
551            @BeanReference(type = MDRRuleGroupInstancePersistence.class)
552            protected MDRRuleGroupInstancePersistence mdrRuleGroupInstancePersistence;
553            private String _beanIdentifier;
554    }