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.mobiledevicerules.service.base;
016    
017    import com.liferay.counter.service.CounterLocalService;
018    
019    import com.liferay.portal.kernel.bean.BeanReference;
020    import com.liferay.portal.kernel.bean.IdentifiableBean;
021    import com.liferay.portal.kernel.dao.jdbc.SqlUpdate;
022    import com.liferay.portal.kernel.dao.jdbc.SqlUpdateFactoryUtil;
023    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
024    import com.liferay.portal.kernel.dao.orm.DynamicQueryFactoryUtil;
025    import com.liferay.portal.kernel.exception.PortalException;
026    import com.liferay.portal.kernel.exception.SystemException;
027    import com.liferay.portal.kernel.search.Indexable;
028    import com.liferay.portal.kernel.search.IndexableType;
029    import com.liferay.portal.kernel.util.OrderByComparator;
030    import com.liferay.portal.model.PersistedModel;
031    import com.liferay.portal.service.BaseLocalServiceImpl;
032    import com.liferay.portal.service.GroupLocalService;
033    import com.liferay.portal.service.GroupService;
034    import com.liferay.portal.service.PersistedModelLocalServiceRegistry;
035    import com.liferay.portal.service.ResourceLocalService;
036    import com.liferay.portal.service.UserLocalService;
037    import com.liferay.portal.service.UserService;
038    import com.liferay.portal.service.persistence.GroupFinder;
039    import com.liferay.portal.service.persistence.GroupPersistence;
040    import com.liferay.portal.service.persistence.UserFinder;
041    import com.liferay.portal.service.persistence.UserPersistence;
042    
043    import com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup;
044    import com.liferay.portlet.mobiledevicerules.service.MDRActionLocalService;
045    import com.liferay.portlet.mobiledevicerules.service.MDRActionService;
046    import com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceLocalService;
047    import com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupInstanceService;
048    import com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalService;
049    import com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupService;
050    import com.liferay.portlet.mobiledevicerules.service.MDRRuleLocalService;
051    import com.liferay.portlet.mobiledevicerules.service.MDRRuleService;
052    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRActionPersistence;
053    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRuleGroupFinder;
054    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRuleGroupInstancePersistence;
055    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRuleGroupPersistence;
056    import com.liferay.portlet.mobiledevicerules.service.persistence.MDRRulePersistence;
057    
058    import java.io.Serializable;
059    
060    import java.util.List;
061    
062    import javax.sql.DataSource;
063    
064    /**
065     * The base implementation of the m d r rule group local service.
066     *
067     * <p>
068     * 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.MDRRuleGroupLocalServiceImpl}.
069     * </p>
070     *
071     * @author Edward C. Han
072     * @see com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleGroupLocalServiceImpl
073     * @see com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalServiceUtil
074     * @generated
075     */
076    public abstract class MDRRuleGroupLocalServiceBaseImpl
077            extends BaseLocalServiceImpl implements MDRRuleGroupLocalService,
078                    IdentifiableBean {
079            /*
080             * NOTE FOR DEVELOPERS:
081             *
082             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.mobiledevicerules.service.MDRRuleGroupLocalServiceUtil} to access the m d r rule group local service.
083             */
084    
085            /**
086             * Adds the m d r rule group to the database. Also notifies the appropriate model listeners.
087             *
088             * @param mdrRuleGroup the m d r rule group
089             * @return the m d r rule group that was added
090             * @throws SystemException if a system exception occurred
091             */
092            @Indexable(type = IndexableType.REINDEX)
093            public MDRRuleGroup addMDRRuleGroup(MDRRuleGroup mdrRuleGroup)
094                    throws SystemException {
095                    mdrRuleGroup.setNew(true);
096    
097                    return mdrRuleGroupPersistence.update(mdrRuleGroup);
098            }
099    
100            /**
101             * Creates a new m d r rule group with the primary key. Does not add the m d r rule group to the database.
102             *
103             * @param ruleGroupId the primary key for the new m d r rule group
104             * @return the new m d r rule group
105             */
106            public MDRRuleGroup createMDRRuleGroup(long ruleGroupId) {
107                    return mdrRuleGroupPersistence.create(ruleGroupId);
108            }
109    
110            /**
111             * Deletes the m d r rule group with the primary key from the database. Also notifies the appropriate model listeners.
112             *
113             * @param ruleGroupId the primary key of the m d r rule group
114             * @return the m d r rule group that was removed
115             * @throws PortalException if a m d r rule group with the primary key could not be found
116             * @throws SystemException if a system exception occurred
117             */
118            @Indexable(type = IndexableType.DELETE)
119            public MDRRuleGroup deleteMDRRuleGroup(long ruleGroupId)
120                    throws PortalException, SystemException {
121                    return mdrRuleGroupPersistence.remove(ruleGroupId);
122            }
123    
124            /**
125             * Deletes the m d r rule group from the database. Also notifies the appropriate model listeners.
126             *
127             * @param mdrRuleGroup the m d r rule group
128             * @return the m d r rule group that was removed
129             * @throws SystemException if a system exception occurred
130             */
131            @Indexable(type = IndexableType.DELETE)
132            public MDRRuleGroup deleteMDRRuleGroup(MDRRuleGroup mdrRuleGroup)
133                    throws SystemException {
134                    return mdrRuleGroupPersistence.remove(mdrRuleGroup);
135            }
136    
137            public DynamicQuery dynamicQuery() {
138                    Class<?> clazz = getClass();
139    
140                    return DynamicQueryFactoryUtil.forClass(MDRRuleGroup.class,
141                            clazz.getClassLoader());
142            }
143    
144            /**
145             * Performs a dynamic query on the database and returns the matching rows.
146             *
147             * @param dynamicQuery the dynamic query
148             * @return the matching rows
149             * @throws SystemException if a system exception occurred
150             */
151            @SuppressWarnings("rawtypes")
152            public List dynamicQuery(DynamicQuery dynamicQuery)
153                    throws SystemException {
154                    return mdrRuleGroupPersistence.findWithDynamicQuery(dynamicQuery);
155            }
156    
157            /**
158             * Performs a dynamic query on the database and returns a range of the matching rows.
159             *
160             * <p>
161             * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.mobiledevicerules.model.impl.MDRRuleGroupModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
162             * </p>
163             *
164             * @param dynamicQuery the dynamic query
165             * @param start the lower bound of the range of model instances
166             * @param end the upper bound of the range of model instances (not inclusive)
167             * @return the range of matching rows
168             * @throws SystemException if a system exception occurred
169             */
170            @SuppressWarnings("rawtypes")
171            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
172                    throws SystemException {
173                    return mdrRuleGroupPersistence.findWithDynamicQuery(dynamicQuery,
174                            start, end);
175            }
176    
177            /**
178             * Performs a dynamic query on the database and returns an ordered range of the matching rows.
179             *
180             * <p>
181             * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.mobiledevicerules.model.impl.MDRRuleGroupModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
182             * </p>
183             *
184             * @param dynamicQuery the dynamic query
185             * @param start the lower bound of the range of model instances
186             * @param end the upper bound of the range of model instances (not inclusive)
187             * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
188             * @return the ordered range of matching rows
189             * @throws SystemException if a system exception occurred
190             */
191            @SuppressWarnings("rawtypes")
192            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end,
193                    OrderByComparator orderByComparator) throws SystemException {
194                    return mdrRuleGroupPersistence.findWithDynamicQuery(dynamicQuery,
195                            start, end, orderByComparator);
196            }
197    
198            /**
199             * Returns the number of rows that match the dynamic query.
200             *
201             * @param dynamicQuery the dynamic query
202             * @return the number of rows that match the dynamic query
203             * @throws SystemException if a system exception occurred
204             */
205            public long dynamicQueryCount(DynamicQuery dynamicQuery)
206                    throws SystemException {
207                    return mdrRuleGroupPersistence.countWithDynamicQuery(dynamicQuery);
208            }
209    
210            public MDRRuleGroup fetchMDRRuleGroup(long ruleGroupId)
211                    throws SystemException {
212                    return mdrRuleGroupPersistence.fetchByPrimaryKey(ruleGroupId);
213            }
214    
215            /**
216             * Returns the m d r rule group with the primary key.
217             *
218             * @param ruleGroupId the primary key of the m d r rule group
219             * @return the m d r rule group
220             * @throws PortalException if a m d r rule group with the primary key could not be found
221             * @throws SystemException if a system exception occurred
222             */
223            public MDRRuleGroup getMDRRuleGroup(long ruleGroupId)
224                    throws PortalException, SystemException {
225                    return mdrRuleGroupPersistence.findByPrimaryKey(ruleGroupId);
226            }
227    
228            public PersistedModel getPersistedModel(Serializable primaryKeyObj)
229                    throws PortalException, SystemException {
230                    return mdrRuleGroupPersistence.findByPrimaryKey(primaryKeyObj);
231            }
232    
233            /**
234             * Returns the m d r rule group with the UUID in the group.
235             *
236             * @param uuid the UUID of m d r rule group
237             * @param groupId the group id of the m d r rule group
238             * @return the m d r rule group
239             * @throws PortalException if a m d r rule group with the UUID in the group could not be found
240             * @throws SystemException if a system exception occurred
241             */
242            public MDRRuleGroup getMDRRuleGroupByUuidAndGroupId(String uuid,
243                    long groupId) throws PortalException, SystemException {
244                    return mdrRuleGroupPersistence.findByUUID_G(uuid, groupId);
245            }
246    
247            /**
248             * Returns a range of all the m d r rule groups.
249             *
250             * <p>
251             * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.mobiledevicerules.model.impl.MDRRuleGroupModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
252             * </p>
253             *
254             * @param start the lower bound of the range of m d r rule groups
255             * @param end the upper bound of the range of m d r rule groups (not inclusive)
256             * @return the range of m d r rule groups
257             * @throws SystemException if a system exception occurred
258             */
259            public List<MDRRuleGroup> getMDRRuleGroups(int start, int end)
260                    throws SystemException {
261                    return mdrRuleGroupPersistence.findAll(start, end);
262            }
263    
264            /**
265             * Returns the number of m d r rule groups.
266             *
267             * @return the number of m d r rule groups
268             * @throws SystemException if a system exception occurred
269             */
270            public int getMDRRuleGroupsCount() throws SystemException {
271                    return mdrRuleGroupPersistence.countAll();
272            }
273    
274            /**
275             * Updates the m d r rule group in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
276             *
277             * @param mdrRuleGroup the m d r rule group
278             * @return the m d r rule group that was updated
279             * @throws SystemException if a system exception occurred
280             */
281            @Indexable(type = IndexableType.REINDEX)
282            public MDRRuleGroup updateMDRRuleGroup(MDRRuleGroup mdrRuleGroup)
283                    throws SystemException {
284                    return mdrRuleGroupPersistence.update(mdrRuleGroup);
285            }
286    
287            /**
288             * Returns the m d r action local service.
289             *
290             * @return the m d r action local service
291             */
292            public MDRActionLocalService getMDRActionLocalService() {
293                    return mdrActionLocalService;
294            }
295    
296            /**
297             * Sets the m d r action local service.
298             *
299             * @param mdrActionLocalService the m d r action local service
300             */
301            public void setMDRActionLocalService(
302                    MDRActionLocalService mdrActionLocalService) {
303                    this.mdrActionLocalService = mdrActionLocalService;
304            }
305    
306            /**
307             * Returns the m d r action remote service.
308             *
309             * @return the m d r action remote service
310             */
311            public MDRActionService getMDRActionService() {
312                    return mdrActionService;
313            }
314    
315            /**
316             * Sets the m d r action remote service.
317             *
318             * @param mdrActionService the m d r action remote service
319             */
320            public void setMDRActionService(MDRActionService mdrActionService) {
321                    this.mdrActionService = mdrActionService;
322            }
323    
324            /**
325             * Returns the m d r action persistence.
326             *
327             * @return the m d r action persistence
328             */
329            public MDRActionPersistence getMDRActionPersistence() {
330                    return mdrActionPersistence;
331            }
332    
333            /**
334             * Sets the m d r action persistence.
335             *
336             * @param mdrActionPersistence the m d r action persistence
337             */
338            public void setMDRActionPersistence(
339                    MDRActionPersistence mdrActionPersistence) {
340                    this.mdrActionPersistence = mdrActionPersistence;
341            }
342    
343            /**
344             * Returns the m d r rule local service.
345             *
346             * @return the m d r rule local service
347             */
348            public MDRRuleLocalService getMDRRuleLocalService() {
349                    return mdrRuleLocalService;
350            }
351    
352            /**
353             * Sets the m d r rule local service.
354             *
355             * @param mdrRuleLocalService the m d r rule local service
356             */
357            public void setMDRRuleLocalService(MDRRuleLocalService mdrRuleLocalService) {
358                    this.mdrRuleLocalService = mdrRuleLocalService;
359            }
360    
361            /**
362             * Returns the m d r rule remote service.
363             *
364             * @return the m d r rule remote service
365             */
366            public MDRRuleService getMDRRuleService() {
367                    return mdrRuleService;
368            }
369    
370            /**
371             * Sets the m d r rule remote service.
372             *
373             * @param mdrRuleService the m d r rule remote service
374             */
375            public void setMDRRuleService(MDRRuleService mdrRuleService) {
376                    this.mdrRuleService = mdrRuleService;
377            }
378    
379            /**
380             * Returns the m d r rule persistence.
381             *
382             * @return the m d r rule persistence
383             */
384            public MDRRulePersistence getMDRRulePersistence() {
385                    return mdrRulePersistence;
386            }
387    
388            /**
389             * Sets the m d r rule persistence.
390             *
391             * @param mdrRulePersistence the m d r rule persistence
392             */
393            public void setMDRRulePersistence(MDRRulePersistence mdrRulePersistence) {
394                    this.mdrRulePersistence = mdrRulePersistence;
395            }
396    
397            /**
398             * Returns the m d r rule group local service.
399             *
400             * @return the m d r rule group local service
401             */
402            public MDRRuleGroupLocalService getMDRRuleGroupLocalService() {
403                    return mdrRuleGroupLocalService;
404            }
405    
406            /**
407             * Sets the m d r rule group local service.
408             *
409             * @param mdrRuleGroupLocalService the m d r rule group local service
410             */
411            public void setMDRRuleGroupLocalService(
412                    MDRRuleGroupLocalService mdrRuleGroupLocalService) {
413                    this.mdrRuleGroupLocalService = mdrRuleGroupLocalService;
414            }
415    
416            /**
417             * Returns the m d r rule group remote service.
418             *
419             * @return the m d r rule group remote service
420             */
421            public MDRRuleGroupService getMDRRuleGroupService() {
422                    return mdrRuleGroupService;
423            }
424    
425            /**
426             * Sets the m d r rule group remote service.
427             *
428             * @param mdrRuleGroupService the m d r rule group remote service
429             */
430            public void setMDRRuleGroupService(MDRRuleGroupService mdrRuleGroupService) {
431                    this.mdrRuleGroupService = mdrRuleGroupService;
432            }
433    
434            /**
435             * Returns the m d r rule group persistence.
436             *
437             * @return the m d r rule group persistence
438             */
439            public MDRRuleGroupPersistence getMDRRuleGroupPersistence() {
440                    return mdrRuleGroupPersistence;
441            }
442    
443            /**
444             * Sets the m d r rule group persistence.
445             *
446             * @param mdrRuleGroupPersistence the m d r rule group persistence
447             */
448            public void setMDRRuleGroupPersistence(
449                    MDRRuleGroupPersistence mdrRuleGroupPersistence) {
450                    this.mdrRuleGroupPersistence = mdrRuleGroupPersistence;
451            }
452    
453            /**
454             * Returns the m d r rule group finder.
455             *
456             * @return the m d r rule group finder
457             */
458            public MDRRuleGroupFinder getMDRRuleGroupFinder() {
459                    return mdrRuleGroupFinder;
460            }
461    
462            /**
463             * Sets the m d r rule group finder.
464             *
465             * @param mdrRuleGroupFinder the m d r rule group finder
466             */
467            public void setMDRRuleGroupFinder(MDRRuleGroupFinder mdrRuleGroupFinder) {
468                    this.mdrRuleGroupFinder = mdrRuleGroupFinder;
469            }
470    
471            /**
472             * Returns the m d r rule group instance local service.
473             *
474             * @return the m d r rule group instance local service
475             */
476            public MDRRuleGroupInstanceLocalService getMDRRuleGroupInstanceLocalService() {
477                    return mdrRuleGroupInstanceLocalService;
478            }
479    
480            /**
481             * Sets the m d r rule group instance local service.
482             *
483             * @param mdrRuleGroupInstanceLocalService the m d r rule group instance local service
484             */
485            public void setMDRRuleGroupInstanceLocalService(
486                    MDRRuleGroupInstanceLocalService mdrRuleGroupInstanceLocalService) {
487                    this.mdrRuleGroupInstanceLocalService = mdrRuleGroupInstanceLocalService;
488            }
489    
490            /**
491             * Returns the m d r rule group instance remote service.
492             *
493             * @return the m d r rule group instance remote service
494             */
495            public MDRRuleGroupInstanceService getMDRRuleGroupInstanceService() {
496                    return mdrRuleGroupInstanceService;
497            }
498    
499            /**
500             * Sets the m d r rule group instance remote service.
501             *
502             * @param mdrRuleGroupInstanceService the m d r rule group instance remote service
503             */
504            public void setMDRRuleGroupInstanceService(
505                    MDRRuleGroupInstanceService mdrRuleGroupInstanceService) {
506                    this.mdrRuleGroupInstanceService = mdrRuleGroupInstanceService;
507            }
508    
509            /**
510             * Returns the m d r rule group instance persistence.
511             *
512             * @return the m d r rule group instance persistence
513             */
514            public MDRRuleGroupInstancePersistence getMDRRuleGroupInstancePersistence() {
515                    return mdrRuleGroupInstancePersistence;
516            }
517    
518            /**
519             * Sets the m d r rule group instance persistence.
520             *
521             * @param mdrRuleGroupInstancePersistence the m d r rule group instance persistence
522             */
523            public void setMDRRuleGroupInstancePersistence(
524                    MDRRuleGroupInstancePersistence mdrRuleGroupInstancePersistence) {
525                    this.mdrRuleGroupInstancePersistence = mdrRuleGroupInstancePersistence;
526            }
527    
528            /**
529             * Returns the counter local service.
530             *
531             * @return the counter local service
532             */
533            public CounterLocalService getCounterLocalService() {
534                    return counterLocalService;
535            }
536    
537            /**
538             * Sets the counter local service.
539             *
540             * @param counterLocalService the counter local service
541             */
542            public void setCounterLocalService(CounterLocalService counterLocalService) {
543                    this.counterLocalService = counterLocalService;
544            }
545    
546            /**
547             * Returns the group local service.
548             *
549             * @return the group local service
550             */
551            public GroupLocalService getGroupLocalService() {
552                    return groupLocalService;
553            }
554    
555            /**
556             * Sets the group local service.
557             *
558             * @param groupLocalService the group local service
559             */
560            public void setGroupLocalService(GroupLocalService groupLocalService) {
561                    this.groupLocalService = groupLocalService;
562            }
563    
564            /**
565             * Returns the group remote service.
566             *
567             * @return the group remote service
568             */
569            public GroupService getGroupService() {
570                    return groupService;
571            }
572    
573            /**
574             * Sets the group remote service.
575             *
576             * @param groupService the group remote service
577             */
578            public void setGroupService(GroupService groupService) {
579                    this.groupService = groupService;
580            }
581    
582            /**
583             * Returns the group persistence.
584             *
585             * @return the group persistence
586             */
587            public GroupPersistence getGroupPersistence() {
588                    return groupPersistence;
589            }
590    
591            /**
592             * Sets the group persistence.
593             *
594             * @param groupPersistence the group persistence
595             */
596            public void setGroupPersistence(GroupPersistence groupPersistence) {
597                    this.groupPersistence = groupPersistence;
598            }
599    
600            /**
601             * Returns the group finder.
602             *
603             * @return the group finder
604             */
605            public GroupFinder getGroupFinder() {
606                    return groupFinder;
607            }
608    
609            /**
610             * Sets the group finder.
611             *
612             * @param groupFinder the group finder
613             */
614            public void setGroupFinder(GroupFinder groupFinder) {
615                    this.groupFinder = groupFinder;
616            }
617    
618            /**
619             * Returns the resource local service.
620             *
621             * @return the resource local service
622             */
623            public ResourceLocalService getResourceLocalService() {
624                    return resourceLocalService;
625            }
626    
627            /**
628             * Sets the resource local service.
629             *
630             * @param resourceLocalService the resource local service
631             */
632            public void setResourceLocalService(
633                    ResourceLocalService resourceLocalService) {
634                    this.resourceLocalService = resourceLocalService;
635            }
636    
637            /**
638             * Returns the user local service.
639             *
640             * @return the user local service
641             */
642            public UserLocalService getUserLocalService() {
643                    return userLocalService;
644            }
645    
646            /**
647             * Sets the user local service.
648             *
649             * @param userLocalService the user local service
650             */
651            public void setUserLocalService(UserLocalService userLocalService) {
652                    this.userLocalService = userLocalService;
653            }
654    
655            /**
656             * Returns the user remote service.
657             *
658             * @return the user remote service
659             */
660            public UserService getUserService() {
661                    return userService;
662            }
663    
664            /**
665             * Sets the user remote service.
666             *
667             * @param userService the user remote service
668             */
669            public void setUserService(UserService userService) {
670                    this.userService = userService;
671            }
672    
673            /**
674             * Returns the user persistence.
675             *
676             * @return the user persistence
677             */
678            public UserPersistence getUserPersistence() {
679                    return userPersistence;
680            }
681    
682            /**
683             * Sets the user persistence.
684             *
685             * @param userPersistence the user persistence
686             */
687            public void setUserPersistence(UserPersistence userPersistence) {
688                    this.userPersistence = userPersistence;
689            }
690    
691            /**
692             * Returns the user finder.
693             *
694             * @return the user finder
695             */
696            public UserFinder getUserFinder() {
697                    return userFinder;
698            }
699    
700            /**
701             * Sets the user finder.
702             *
703             * @param userFinder the user finder
704             */
705            public void setUserFinder(UserFinder userFinder) {
706                    this.userFinder = userFinder;
707            }
708    
709            public void afterPropertiesSet() {
710                    persistedModelLocalServiceRegistry.register("com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup",
711                            mdrRuleGroupLocalService);
712            }
713    
714            public void destroy() {
715                    persistedModelLocalServiceRegistry.unregister(
716                            "com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup");
717            }
718    
719            /**
720             * Returns the Spring bean ID for this bean.
721             *
722             * @return the Spring bean ID for this bean
723             */
724            public String getBeanIdentifier() {
725                    return _beanIdentifier;
726            }
727    
728            /**
729             * Sets the Spring bean ID for this bean.
730             *
731             * @param beanIdentifier the Spring bean ID for this bean
732             */
733            public void setBeanIdentifier(String beanIdentifier) {
734                    _beanIdentifier = beanIdentifier;
735            }
736    
737            protected Class<?> getModelClass() {
738                    return MDRRuleGroup.class;
739            }
740    
741            protected String getModelClassName() {
742                    return MDRRuleGroup.class.getName();
743            }
744    
745            /**
746             * Performs an SQL query.
747             *
748             * @param sql the sql query
749             */
750            protected void runSQL(String sql) throws SystemException {
751                    try {
752                            DataSource dataSource = mdrRuleGroupPersistence.getDataSource();
753    
754                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
755                                            sql, new int[0]);
756    
757                            sqlUpdate.update();
758                    }
759                    catch (Exception e) {
760                            throw new SystemException(e);
761                    }
762            }
763    
764            @BeanReference(type = MDRActionLocalService.class)
765            protected MDRActionLocalService mdrActionLocalService;
766            @BeanReference(type = MDRActionService.class)
767            protected MDRActionService mdrActionService;
768            @BeanReference(type = MDRActionPersistence.class)
769            protected MDRActionPersistence mdrActionPersistence;
770            @BeanReference(type = MDRRuleLocalService.class)
771            protected MDRRuleLocalService mdrRuleLocalService;
772            @BeanReference(type = MDRRuleService.class)
773            protected MDRRuleService mdrRuleService;
774            @BeanReference(type = MDRRulePersistence.class)
775            protected MDRRulePersistence mdrRulePersistence;
776            @BeanReference(type = MDRRuleGroupLocalService.class)
777            protected MDRRuleGroupLocalService mdrRuleGroupLocalService;
778            @BeanReference(type = MDRRuleGroupService.class)
779            protected MDRRuleGroupService mdrRuleGroupService;
780            @BeanReference(type = MDRRuleGroupPersistence.class)
781            protected MDRRuleGroupPersistence mdrRuleGroupPersistence;
782            @BeanReference(type = MDRRuleGroupFinder.class)
783            protected MDRRuleGroupFinder mdrRuleGroupFinder;
784            @BeanReference(type = MDRRuleGroupInstanceLocalService.class)
785            protected MDRRuleGroupInstanceLocalService mdrRuleGroupInstanceLocalService;
786            @BeanReference(type = MDRRuleGroupInstanceService.class)
787            protected MDRRuleGroupInstanceService mdrRuleGroupInstanceService;
788            @BeanReference(type = MDRRuleGroupInstancePersistence.class)
789            protected MDRRuleGroupInstancePersistence mdrRuleGroupInstancePersistence;
790            @BeanReference(type = CounterLocalService.class)
791            protected CounterLocalService counterLocalService;
792            @BeanReference(type = GroupLocalService.class)
793            protected GroupLocalService groupLocalService;
794            @BeanReference(type = GroupService.class)
795            protected GroupService groupService;
796            @BeanReference(type = GroupPersistence.class)
797            protected GroupPersistence groupPersistence;
798            @BeanReference(type = GroupFinder.class)
799            protected GroupFinder groupFinder;
800            @BeanReference(type = ResourceLocalService.class)
801            protected ResourceLocalService resourceLocalService;
802            @BeanReference(type = UserLocalService.class)
803            protected UserLocalService userLocalService;
804            @BeanReference(type = UserService.class)
805            protected UserService userService;
806            @BeanReference(type = UserPersistence.class)
807            protected UserPersistence userPersistence;
808            @BeanReference(type = UserFinder.class)
809            protected UserFinder userFinder;
810            @BeanReference(type = PersistedModelLocalServiceRegistry.class)
811            protected PersistedModelLocalServiceRegistry persistedModelLocalServiceRegistry;
812            private String _beanIdentifier;
813    }