001    /**
002     * Copyright (c) 2000-2013 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.social.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.jdbc.SqlUpdate;
020    import com.liferay.portal.kernel.dao.jdbc.SqlUpdateFactoryUtil;
021    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
022    import com.liferay.portal.kernel.dao.orm.DynamicQueryFactoryUtil;
023    import com.liferay.portal.kernel.dao.orm.Projection;
024    import com.liferay.portal.kernel.exception.PortalException;
025    import com.liferay.portal.kernel.exception.SystemException;
026    import com.liferay.portal.kernel.search.Indexable;
027    import com.liferay.portal.kernel.search.IndexableType;
028    import com.liferay.portal.kernel.util.OrderByComparator;
029    import com.liferay.portal.model.PersistedModel;
030    import com.liferay.portal.service.BaseLocalServiceImpl;
031    import com.liferay.portal.service.PersistedModelLocalServiceRegistry;
032    import com.liferay.portal.service.persistence.GroupFinder;
033    import com.liferay.portal.service.persistence.GroupPersistence;
034    import com.liferay.portal.service.persistence.LockFinder;
035    import com.liferay.portal.service.persistence.LockPersistence;
036    import com.liferay.portal.service.persistence.UserFinder;
037    import com.liferay.portal.service.persistence.UserPersistence;
038    
039    import com.liferay.portlet.asset.service.persistence.AssetEntryFinder;
040    import com.liferay.portlet.asset.service.persistence.AssetEntryPersistence;
041    import com.liferay.portlet.social.model.SocialActivityCounter;
042    import com.liferay.portlet.social.service.SocialActivityCounterLocalService;
043    import com.liferay.portlet.social.service.persistence.SocialActivityAchievementPersistence;
044    import com.liferay.portlet.social.service.persistence.SocialActivityCounterFinder;
045    import com.liferay.portlet.social.service.persistence.SocialActivityCounterPersistence;
046    import com.liferay.portlet.social.service.persistence.SocialActivityFinder;
047    import com.liferay.portlet.social.service.persistence.SocialActivityLimitPersistence;
048    import com.liferay.portlet.social.service.persistence.SocialActivityPersistence;
049    import com.liferay.portlet.social.service.persistence.SocialActivitySetFinder;
050    import com.liferay.portlet.social.service.persistence.SocialActivitySetPersistence;
051    import com.liferay.portlet.social.service.persistence.SocialActivitySettingPersistence;
052    import com.liferay.portlet.social.service.persistence.SocialRelationPersistence;
053    import com.liferay.portlet.social.service.persistence.SocialRequestPersistence;
054    
055    import java.io.Serializable;
056    
057    import java.util.List;
058    
059    import javax.sql.DataSource;
060    
061    /**
062     * Provides the base implementation for the social activity counter local service.
063     *
064     * <p>
065     * 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.social.service.impl.SocialActivityCounterLocalServiceImpl}.
066     * </p>
067     *
068     * @author Brian Wing Shun Chan
069     * @see com.liferay.portlet.social.service.impl.SocialActivityCounterLocalServiceImpl
070     * @see com.liferay.portlet.social.service.SocialActivityCounterLocalServiceUtil
071     * @generated
072     */
073    public abstract class SocialActivityCounterLocalServiceBaseImpl
074            extends BaseLocalServiceImpl implements SocialActivityCounterLocalService,
075                    IdentifiableBean {
076            /*
077             * NOTE FOR DEVELOPERS:
078             *
079             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.social.service.SocialActivityCounterLocalServiceUtil} to access the social activity counter local service.
080             */
081    
082            /**
083             * Adds the social activity counter to the database. Also notifies the appropriate model listeners.
084             *
085             * @param socialActivityCounter the social activity counter
086             * @return the social activity counter that was added
087             * @throws SystemException if a system exception occurred
088             */
089            @Indexable(type = IndexableType.REINDEX)
090            @Override
091            public SocialActivityCounter addSocialActivityCounter(
092                    SocialActivityCounter socialActivityCounter) throws SystemException {
093                    socialActivityCounter.setNew(true);
094    
095                    return socialActivityCounterPersistence.update(socialActivityCounter);
096            }
097    
098            /**
099             * Creates a new social activity counter with the primary key. Does not add the social activity counter to the database.
100             *
101             * @param activityCounterId the primary key for the new social activity counter
102             * @return the new social activity counter
103             */
104            @Override
105            public SocialActivityCounter createSocialActivityCounter(
106                    long activityCounterId) {
107                    return socialActivityCounterPersistence.create(activityCounterId);
108            }
109    
110            /**
111             * Deletes the social activity counter with the primary key from the database. Also notifies the appropriate model listeners.
112             *
113             * @param activityCounterId the primary key of the social activity counter
114             * @return the social activity counter that was removed
115             * @throws PortalException if a social activity counter with the primary key could not be found
116             * @throws SystemException if a system exception occurred
117             */
118            @Indexable(type = IndexableType.DELETE)
119            @Override
120            public SocialActivityCounter deleteSocialActivityCounter(
121                    long activityCounterId) throws PortalException, SystemException {
122                    return socialActivityCounterPersistence.remove(activityCounterId);
123            }
124    
125            /**
126             * Deletes the social activity counter from the database. Also notifies the appropriate model listeners.
127             *
128             * @param socialActivityCounter the social activity counter
129             * @return the social activity counter that was removed
130             * @throws SystemException if a system exception occurred
131             */
132            @Indexable(type = IndexableType.DELETE)
133            @Override
134            public SocialActivityCounter deleteSocialActivityCounter(
135                    SocialActivityCounter socialActivityCounter) throws SystemException {
136                    return socialActivityCounterPersistence.remove(socialActivityCounter);
137            }
138    
139            @Override
140            public DynamicQuery dynamicQuery() {
141                    Class<?> clazz = getClass();
142    
143                    return DynamicQueryFactoryUtil.forClass(SocialActivityCounter.class,
144                            clazz.getClassLoader());
145            }
146    
147            /**
148             * Performs a dynamic query on the database and returns the matching rows.
149             *
150             * @param dynamicQuery the dynamic query
151             * @return the matching rows
152             * @throws SystemException if a system exception occurred
153             */
154            @Override
155            @SuppressWarnings("rawtypes")
156            public List dynamicQuery(DynamicQuery dynamicQuery)
157                    throws SystemException {
158                    return socialActivityCounterPersistence.findWithDynamicQuery(dynamicQuery);
159            }
160    
161            /**
162             * Performs a dynamic query on the database and returns a range of the matching rows.
163             *
164             * <p>
165             * 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.social.model.impl.SocialActivityCounterModelImpl}. 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.
166             * </p>
167             *
168             * @param dynamicQuery the dynamic query
169             * @param start the lower bound of the range of model instances
170             * @param end the upper bound of the range of model instances (not inclusive)
171             * @return the range of matching rows
172             * @throws SystemException if a system exception occurred
173             */
174            @Override
175            @SuppressWarnings("rawtypes")
176            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
177                    throws SystemException {
178                    return socialActivityCounterPersistence.findWithDynamicQuery(dynamicQuery,
179                            start, end);
180            }
181    
182            /**
183             * Performs a dynamic query on the database and returns an ordered range of the matching rows.
184             *
185             * <p>
186             * 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.social.model.impl.SocialActivityCounterModelImpl}. 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.
187             * </p>
188             *
189             * @param dynamicQuery the dynamic query
190             * @param start the lower bound of the range of model instances
191             * @param end the upper bound of the range of model instances (not inclusive)
192             * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
193             * @return the ordered range of matching rows
194             * @throws SystemException if a system exception occurred
195             */
196            @Override
197            @SuppressWarnings("rawtypes")
198            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end,
199                    OrderByComparator orderByComparator) throws SystemException {
200                    return socialActivityCounterPersistence.findWithDynamicQuery(dynamicQuery,
201                            start, end, orderByComparator);
202            }
203    
204            /**
205             * Returns the number of rows that match the dynamic query.
206             *
207             * @param dynamicQuery the dynamic query
208             * @return the number of rows that match the dynamic query
209             * @throws SystemException if a system exception occurred
210             */
211            @Override
212            public long dynamicQueryCount(DynamicQuery dynamicQuery)
213                    throws SystemException {
214                    return socialActivityCounterPersistence.countWithDynamicQuery(dynamicQuery);
215            }
216    
217            /**
218             * Returns the number of rows that match the dynamic query.
219             *
220             * @param dynamicQuery the dynamic query
221             * @param projection the projection to apply to the query
222             * @return the number of rows that match the dynamic query
223             * @throws SystemException if a system exception occurred
224             */
225            @Override
226            public long dynamicQueryCount(DynamicQuery dynamicQuery,
227                    Projection projection) throws SystemException {
228                    return socialActivityCounterPersistence.countWithDynamicQuery(dynamicQuery,
229                            projection);
230            }
231    
232            @Override
233            public SocialActivityCounter fetchSocialActivityCounter(
234                    long activityCounterId) throws SystemException {
235                    return socialActivityCounterPersistence.fetchByPrimaryKey(activityCounterId);
236            }
237    
238            /**
239             * Returns the social activity counter with the primary key.
240             *
241             * @param activityCounterId the primary key of the social activity counter
242             * @return the social activity counter
243             * @throws PortalException if a social activity counter with the primary key could not be found
244             * @throws SystemException if a system exception occurred
245             */
246            @Override
247            public SocialActivityCounter getSocialActivityCounter(
248                    long activityCounterId) throws PortalException, SystemException {
249                    return socialActivityCounterPersistence.findByPrimaryKey(activityCounterId);
250            }
251    
252            @Override
253            public PersistedModel getPersistedModel(Serializable primaryKeyObj)
254                    throws PortalException, SystemException {
255                    return socialActivityCounterPersistence.findByPrimaryKey(primaryKeyObj);
256            }
257    
258            /**
259             * Returns a range of all the social activity counters.
260             *
261             * <p>
262             * 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.social.model.impl.SocialActivityCounterModelImpl}. 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.
263             * </p>
264             *
265             * @param start the lower bound of the range of social activity counters
266             * @param end the upper bound of the range of social activity counters (not inclusive)
267             * @return the range of social activity counters
268             * @throws SystemException if a system exception occurred
269             */
270            @Override
271            public List<SocialActivityCounter> getSocialActivityCounters(int start,
272                    int end) throws SystemException {
273                    return socialActivityCounterPersistence.findAll(start, end);
274            }
275    
276            /**
277             * Returns the number of social activity counters.
278             *
279             * @return the number of social activity counters
280             * @throws SystemException if a system exception occurred
281             */
282            @Override
283            public int getSocialActivityCountersCount() throws SystemException {
284                    return socialActivityCounterPersistence.countAll();
285            }
286    
287            /**
288             * Updates the social activity counter in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
289             *
290             * @param socialActivityCounter the social activity counter
291             * @return the social activity counter that was updated
292             * @throws SystemException if a system exception occurred
293             */
294            @Indexable(type = IndexableType.REINDEX)
295            @Override
296            public SocialActivityCounter updateSocialActivityCounter(
297                    SocialActivityCounter socialActivityCounter) throws SystemException {
298                    return socialActivityCounterPersistence.update(socialActivityCounter);
299            }
300    
301            /**
302             * Returns the social activity local service.
303             *
304             * @return the social activity local service
305             */
306            public com.liferay.portlet.social.service.SocialActivityLocalService getSocialActivityLocalService() {
307                    return socialActivityLocalService;
308            }
309    
310            /**
311             * Sets the social activity local service.
312             *
313             * @param socialActivityLocalService the social activity local service
314             */
315            public void setSocialActivityLocalService(
316                    com.liferay.portlet.social.service.SocialActivityLocalService socialActivityLocalService) {
317                    this.socialActivityLocalService = socialActivityLocalService;
318            }
319    
320            /**
321             * Returns the social activity persistence.
322             *
323             * @return the social activity persistence
324             */
325            public SocialActivityPersistence getSocialActivityPersistence() {
326                    return socialActivityPersistence;
327            }
328    
329            /**
330             * Sets the social activity persistence.
331             *
332             * @param socialActivityPersistence the social activity persistence
333             */
334            public void setSocialActivityPersistence(
335                    SocialActivityPersistence socialActivityPersistence) {
336                    this.socialActivityPersistence = socialActivityPersistence;
337            }
338    
339            /**
340             * Returns the social activity finder.
341             *
342             * @return the social activity finder
343             */
344            public SocialActivityFinder getSocialActivityFinder() {
345                    return socialActivityFinder;
346            }
347    
348            /**
349             * Sets the social activity finder.
350             *
351             * @param socialActivityFinder the social activity finder
352             */
353            public void setSocialActivityFinder(
354                    SocialActivityFinder socialActivityFinder) {
355                    this.socialActivityFinder = socialActivityFinder;
356            }
357    
358            /**
359             * Returns the social activity achievement local service.
360             *
361             * @return the social activity achievement local service
362             */
363            public com.liferay.portlet.social.service.SocialActivityAchievementLocalService getSocialActivityAchievementLocalService() {
364                    return socialActivityAchievementLocalService;
365            }
366    
367            /**
368             * Sets the social activity achievement local service.
369             *
370             * @param socialActivityAchievementLocalService the social activity achievement local service
371             */
372            public void setSocialActivityAchievementLocalService(
373                    com.liferay.portlet.social.service.SocialActivityAchievementLocalService socialActivityAchievementLocalService) {
374                    this.socialActivityAchievementLocalService = socialActivityAchievementLocalService;
375            }
376    
377            /**
378             * Returns the social activity achievement persistence.
379             *
380             * @return the social activity achievement persistence
381             */
382            public SocialActivityAchievementPersistence getSocialActivityAchievementPersistence() {
383                    return socialActivityAchievementPersistence;
384            }
385    
386            /**
387             * Sets the social activity achievement persistence.
388             *
389             * @param socialActivityAchievementPersistence the social activity achievement persistence
390             */
391            public void setSocialActivityAchievementPersistence(
392                    SocialActivityAchievementPersistence socialActivityAchievementPersistence) {
393                    this.socialActivityAchievementPersistence = socialActivityAchievementPersistence;
394            }
395    
396            /**
397             * Returns the social activity counter local service.
398             *
399             * @return the social activity counter local service
400             */
401            public com.liferay.portlet.social.service.SocialActivityCounterLocalService getSocialActivityCounterLocalService() {
402                    return socialActivityCounterLocalService;
403            }
404    
405            /**
406             * Sets the social activity counter local service.
407             *
408             * @param socialActivityCounterLocalService the social activity counter local service
409             */
410            public void setSocialActivityCounterLocalService(
411                    com.liferay.portlet.social.service.SocialActivityCounterLocalService socialActivityCounterLocalService) {
412                    this.socialActivityCounterLocalService = socialActivityCounterLocalService;
413            }
414    
415            /**
416             * Returns the social activity counter persistence.
417             *
418             * @return the social activity counter persistence
419             */
420            public SocialActivityCounterPersistence getSocialActivityCounterPersistence() {
421                    return socialActivityCounterPersistence;
422            }
423    
424            /**
425             * Sets the social activity counter persistence.
426             *
427             * @param socialActivityCounterPersistence the social activity counter persistence
428             */
429            public void setSocialActivityCounterPersistence(
430                    SocialActivityCounterPersistence socialActivityCounterPersistence) {
431                    this.socialActivityCounterPersistence = socialActivityCounterPersistence;
432            }
433    
434            /**
435             * Returns the social activity counter finder.
436             *
437             * @return the social activity counter finder
438             */
439            public SocialActivityCounterFinder getSocialActivityCounterFinder() {
440                    return socialActivityCounterFinder;
441            }
442    
443            /**
444             * Sets the social activity counter finder.
445             *
446             * @param socialActivityCounterFinder the social activity counter finder
447             */
448            public void setSocialActivityCounterFinder(
449                    SocialActivityCounterFinder socialActivityCounterFinder) {
450                    this.socialActivityCounterFinder = socialActivityCounterFinder;
451            }
452    
453            /**
454             * Returns the social activity interpreter local service.
455             *
456             * @return the social activity interpreter local service
457             */
458            public com.liferay.portlet.social.service.SocialActivityInterpreterLocalService getSocialActivityInterpreterLocalService() {
459                    return socialActivityInterpreterLocalService;
460            }
461    
462            /**
463             * Sets the social activity interpreter local service.
464             *
465             * @param socialActivityInterpreterLocalService the social activity interpreter local service
466             */
467            public void setSocialActivityInterpreterLocalService(
468                    com.liferay.portlet.social.service.SocialActivityInterpreterLocalService socialActivityInterpreterLocalService) {
469                    this.socialActivityInterpreterLocalService = socialActivityInterpreterLocalService;
470            }
471    
472            /**
473             * Returns the social activity limit local service.
474             *
475             * @return the social activity limit local service
476             */
477            public com.liferay.portlet.social.service.SocialActivityLimitLocalService getSocialActivityLimitLocalService() {
478                    return socialActivityLimitLocalService;
479            }
480    
481            /**
482             * Sets the social activity limit local service.
483             *
484             * @param socialActivityLimitLocalService the social activity limit local service
485             */
486            public void setSocialActivityLimitLocalService(
487                    com.liferay.portlet.social.service.SocialActivityLimitLocalService socialActivityLimitLocalService) {
488                    this.socialActivityLimitLocalService = socialActivityLimitLocalService;
489            }
490    
491            /**
492             * Returns the social activity limit persistence.
493             *
494             * @return the social activity limit persistence
495             */
496            public SocialActivityLimitPersistence getSocialActivityLimitPersistence() {
497                    return socialActivityLimitPersistence;
498            }
499    
500            /**
501             * Sets the social activity limit persistence.
502             *
503             * @param socialActivityLimitPersistence the social activity limit persistence
504             */
505            public void setSocialActivityLimitPersistence(
506                    SocialActivityLimitPersistence socialActivityLimitPersistence) {
507                    this.socialActivityLimitPersistence = socialActivityLimitPersistence;
508            }
509    
510            /**
511             * Returns the social activity set local service.
512             *
513             * @return the social activity set local service
514             */
515            public com.liferay.portlet.social.service.SocialActivitySetLocalService getSocialActivitySetLocalService() {
516                    return socialActivitySetLocalService;
517            }
518    
519            /**
520             * Sets the social activity set local service.
521             *
522             * @param socialActivitySetLocalService the social activity set local service
523             */
524            public void setSocialActivitySetLocalService(
525                    com.liferay.portlet.social.service.SocialActivitySetLocalService socialActivitySetLocalService) {
526                    this.socialActivitySetLocalService = socialActivitySetLocalService;
527            }
528    
529            /**
530             * Returns the social activity set persistence.
531             *
532             * @return the social activity set persistence
533             */
534            public SocialActivitySetPersistence getSocialActivitySetPersistence() {
535                    return socialActivitySetPersistence;
536            }
537    
538            /**
539             * Sets the social activity set persistence.
540             *
541             * @param socialActivitySetPersistence the social activity set persistence
542             */
543            public void setSocialActivitySetPersistence(
544                    SocialActivitySetPersistence socialActivitySetPersistence) {
545                    this.socialActivitySetPersistence = socialActivitySetPersistence;
546            }
547    
548            /**
549             * Returns the social activity set finder.
550             *
551             * @return the social activity set finder
552             */
553            public SocialActivitySetFinder getSocialActivitySetFinder() {
554                    return socialActivitySetFinder;
555            }
556    
557            /**
558             * Sets the social activity set finder.
559             *
560             * @param socialActivitySetFinder the social activity set finder
561             */
562            public void setSocialActivitySetFinder(
563                    SocialActivitySetFinder socialActivitySetFinder) {
564                    this.socialActivitySetFinder = socialActivitySetFinder;
565            }
566    
567            /**
568             * Returns the social activity setting local service.
569             *
570             * @return the social activity setting local service
571             */
572            public com.liferay.portlet.social.service.SocialActivitySettingLocalService getSocialActivitySettingLocalService() {
573                    return socialActivitySettingLocalService;
574            }
575    
576            /**
577             * Sets the social activity setting local service.
578             *
579             * @param socialActivitySettingLocalService the social activity setting local service
580             */
581            public void setSocialActivitySettingLocalService(
582                    com.liferay.portlet.social.service.SocialActivitySettingLocalService socialActivitySettingLocalService) {
583                    this.socialActivitySettingLocalService = socialActivitySettingLocalService;
584            }
585    
586            /**
587             * Returns the social activity setting remote service.
588             *
589             * @return the social activity setting remote service
590             */
591            public com.liferay.portlet.social.service.SocialActivitySettingService getSocialActivitySettingService() {
592                    return socialActivitySettingService;
593            }
594    
595            /**
596             * Sets the social activity setting remote service.
597             *
598             * @param socialActivitySettingService the social activity setting remote service
599             */
600            public void setSocialActivitySettingService(
601                    com.liferay.portlet.social.service.SocialActivitySettingService socialActivitySettingService) {
602                    this.socialActivitySettingService = socialActivitySettingService;
603            }
604    
605            /**
606             * Returns the social activity setting persistence.
607             *
608             * @return the social activity setting persistence
609             */
610            public SocialActivitySettingPersistence getSocialActivitySettingPersistence() {
611                    return socialActivitySettingPersistence;
612            }
613    
614            /**
615             * Sets the social activity setting persistence.
616             *
617             * @param socialActivitySettingPersistence the social activity setting persistence
618             */
619            public void setSocialActivitySettingPersistence(
620                    SocialActivitySettingPersistence socialActivitySettingPersistence) {
621                    this.socialActivitySettingPersistence = socialActivitySettingPersistence;
622            }
623    
624            /**
625             * Returns the social relation local service.
626             *
627             * @return the social relation local service
628             */
629            public com.liferay.portlet.social.service.SocialRelationLocalService getSocialRelationLocalService() {
630                    return socialRelationLocalService;
631            }
632    
633            /**
634             * Sets the social relation local service.
635             *
636             * @param socialRelationLocalService the social relation local service
637             */
638            public void setSocialRelationLocalService(
639                    com.liferay.portlet.social.service.SocialRelationLocalService socialRelationLocalService) {
640                    this.socialRelationLocalService = socialRelationLocalService;
641            }
642    
643            /**
644             * Returns the social relation persistence.
645             *
646             * @return the social relation persistence
647             */
648            public SocialRelationPersistence getSocialRelationPersistence() {
649                    return socialRelationPersistence;
650            }
651    
652            /**
653             * Sets the social relation persistence.
654             *
655             * @param socialRelationPersistence the social relation persistence
656             */
657            public void setSocialRelationPersistence(
658                    SocialRelationPersistence socialRelationPersistence) {
659                    this.socialRelationPersistence = socialRelationPersistence;
660            }
661    
662            /**
663             * Returns the social request local service.
664             *
665             * @return the social request local service
666             */
667            public com.liferay.portlet.social.service.SocialRequestLocalService getSocialRequestLocalService() {
668                    return socialRequestLocalService;
669            }
670    
671            /**
672             * Sets the social request local service.
673             *
674             * @param socialRequestLocalService the social request local service
675             */
676            public void setSocialRequestLocalService(
677                    com.liferay.portlet.social.service.SocialRequestLocalService socialRequestLocalService) {
678                    this.socialRequestLocalService = socialRequestLocalService;
679            }
680    
681            /**
682             * Returns the social request remote service.
683             *
684             * @return the social request remote service
685             */
686            public com.liferay.portlet.social.service.SocialRequestService getSocialRequestService() {
687                    return socialRequestService;
688            }
689    
690            /**
691             * Sets the social request remote service.
692             *
693             * @param socialRequestService the social request remote service
694             */
695            public void setSocialRequestService(
696                    com.liferay.portlet.social.service.SocialRequestService socialRequestService) {
697                    this.socialRequestService = socialRequestService;
698            }
699    
700            /**
701             * Returns the social request persistence.
702             *
703             * @return the social request persistence
704             */
705            public SocialRequestPersistence getSocialRequestPersistence() {
706                    return socialRequestPersistence;
707            }
708    
709            /**
710             * Sets the social request persistence.
711             *
712             * @param socialRequestPersistence the social request persistence
713             */
714            public void setSocialRequestPersistence(
715                    SocialRequestPersistence socialRequestPersistence) {
716                    this.socialRequestPersistence = socialRequestPersistence;
717            }
718    
719            /**
720             * Returns the social request interpreter local service.
721             *
722             * @return the social request interpreter local service
723             */
724            public com.liferay.portlet.social.service.SocialRequestInterpreterLocalService getSocialRequestInterpreterLocalService() {
725                    return socialRequestInterpreterLocalService;
726            }
727    
728            /**
729             * Sets the social request interpreter local service.
730             *
731             * @param socialRequestInterpreterLocalService the social request interpreter local service
732             */
733            public void setSocialRequestInterpreterLocalService(
734                    com.liferay.portlet.social.service.SocialRequestInterpreterLocalService socialRequestInterpreterLocalService) {
735                    this.socialRequestInterpreterLocalService = socialRequestInterpreterLocalService;
736            }
737    
738            /**
739             * Returns the counter local service.
740             *
741             * @return the counter local service
742             */
743            public com.liferay.counter.service.CounterLocalService getCounterLocalService() {
744                    return counterLocalService;
745            }
746    
747            /**
748             * Sets the counter local service.
749             *
750             * @param counterLocalService the counter local service
751             */
752            public void setCounterLocalService(
753                    com.liferay.counter.service.CounterLocalService counterLocalService) {
754                    this.counterLocalService = counterLocalService;
755            }
756    
757            /**
758             * Returns the group local service.
759             *
760             * @return the group local service
761             */
762            public com.liferay.portal.service.GroupLocalService getGroupLocalService() {
763                    return groupLocalService;
764            }
765    
766            /**
767             * Sets the group local service.
768             *
769             * @param groupLocalService the group local service
770             */
771            public void setGroupLocalService(
772                    com.liferay.portal.service.GroupLocalService groupLocalService) {
773                    this.groupLocalService = groupLocalService;
774            }
775    
776            /**
777             * Returns the group remote service.
778             *
779             * @return the group remote service
780             */
781            public com.liferay.portal.service.GroupService getGroupService() {
782                    return groupService;
783            }
784    
785            /**
786             * Sets the group remote service.
787             *
788             * @param groupService the group remote service
789             */
790            public void setGroupService(
791                    com.liferay.portal.service.GroupService groupService) {
792                    this.groupService = groupService;
793            }
794    
795            /**
796             * Returns the group persistence.
797             *
798             * @return the group persistence
799             */
800            public GroupPersistence getGroupPersistence() {
801                    return groupPersistence;
802            }
803    
804            /**
805             * Sets the group persistence.
806             *
807             * @param groupPersistence the group persistence
808             */
809            public void setGroupPersistence(GroupPersistence groupPersistence) {
810                    this.groupPersistence = groupPersistence;
811            }
812    
813            /**
814             * Returns the group finder.
815             *
816             * @return the group finder
817             */
818            public GroupFinder getGroupFinder() {
819                    return groupFinder;
820            }
821    
822            /**
823             * Sets the group finder.
824             *
825             * @param groupFinder the group finder
826             */
827            public void setGroupFinder(GroupFinder groupFinder) {
828                    this.groupFinder = groupFinder;
829            }
830    
831            /**
832             * Returns the lock local service.
833             *
834             * @return the lock local service
835             */
836            public com.liferay.portal.service.LockLocalService getLockLocalService() {
837                    return lockLocalService;
838            }
839    
840            /**
841             * Sets the lock local service.
842             *
843             * @param lockLocalService the lock local service
844             */
845            public void setLockLocalService(
846                    com.liferay.portal.service.LockLocalService lockLocalService) {
847                    this.lockLocalService = lockLocalService;
848            }
849    
850            /**
851             * Returns the lock persistence.
852             *
853             * @return the lock persistence
854             */
855            public LockPersistence getLockPersistence() {
856                    return lockPersistence;
857            }
858    
859            /**
860             * Sets the lock persistence.
861             *
862             * @param lockPersistence the lock persistence
863             */
864            public void setLockPersistence(LockPersistence lockPersistence) {
865                    this.lockPersistence = lockPersistence;
866            }
867    
868            /**
869             * Returns the lock finder.
870             *
871             * @return the lock finder
872             */
873            public LockFinder getLockFinder() {
874                    return lockFinder;
875            }
876    
877            /**
878             * Sets the lock finder.
879             *
880             * @param lockFinder the lock finder
881             */
882            public void setLockFinder(LockFinder lockFinder) {
883                    this.lockFinder = lockFinder;
884            }
885    
886            /**
887             * Returns the resource local service.
888             *
889             * @return the resource local service
890             */
891            public com.liferay.portal.service.ResourceLocalService getResourceLocalService() {
892                    return resourceLocalService;
893            }
894    
895            /**
896             * Sets the resource local service.
897             *
898             * @param resourceLocalService the resource local service
899             */
900            public void setResourceLocalService(
901                    com.liferay.portal.service.ResourceLocalService resourceLocalService) {
902                    this.resourceLocalService = resourceLocalService;
903            }
904    
905            /**
906             * Returns the user local service.
907             *
908             * @return the user local service
909             */
910            public com.liferay.portal.service.UserLocalService getUserLocalService() {
911                    return userLocalService;
912            }
913    
914            /**
915             * Sets the user local service.
916             *
917             * @param userLocalService the user local service
918             */
919            public void setUserLocalService(
920                    com.liferay.portal.service.UserLocalService userLocalService) {
921                    this.userLocalService = userLocalService;
922            }
923    
924            /**
925             * Returns the user remote service.
926             *
927             * @return the user remote service
928             */
929            public com.liferay.portal.service.UserService getUserService() {
930                    return userService;
931            }
932    
933            /**
934             * Sets the user remote service.
935             *
936             * @param userService the user remote service
937             */
938            public void setUserService(
939                    com.liferay.portal.service.UserService userService) {
940                    this.userService = userService;
941            }
942    
943            /**
944             * Returns the user persistence.
945             *
946             * @return the user persistence
947             */
948            public UserPersistence getUserPersistence() {
949                    return userPersistence;
950            }
951    
952            /**
953             * Sets the user persistence.
954             *
955             * @param userPersistence the user persistence
956             */
957            public void setUserPersistence(UserPersistence userPersistence) {
958                    this.userPersistence = userPersistence;
959            }
960    
961            /**
962             * Returns the user finder.
963             *
964             * @return the user finder
965             */
966            public UserFinder getUserFinder() {
967                    return userFinder;
968            }
969    
970            /**
971             * Sets the user finder.
972             *
973             * @param userFinder the user finder
974             */
975            public void setUserFinder(UserFinder userFinder) {
976                    this.userFinder = userFinder;
977            }
978    
979            /**
980             * Returns the asset entry local service.
981             *
982             * @return the asset entry local service
983             */
984            public com.liferay.portlet.asset.service.AssetEntryLocalService getAssetEntryLocalService() {
985                    return assetEntryLocalService;
986            }
987    
988            /**
989             * Sets the asset entry local service.
990             *
991             * @param assetEntryLocalService the asset entry local service
992             */
993            public void setAssetEntryLocalService(
994                    com.liferay.portlet.asset.service.AssetEntryLocalService assetEntryLocalService) {
995                    this.assetEntryLocalService = assetEntryLocalService;
996            }
997    
998            /**
999             * Returns the asset entry remote service.
1000             *
1001             * @return the asset entry remote service
1002             */
1003            public com.liferay.portlet.asset.service.AssetEntryService getAssetEntryService() {
1004                    return assetEntryService;
1005            }
1006    
1007            /**
1008             * Sets the asset entry remote service.
1009             *
1010             * @param assetEntryService the asset entry remote service
1011             */
1012            public void setAssetEntryService(
1013                    com.liferay.portlet.asset.service.AssetEntryService assetEntryService) {
1014                    this.assetEntryService = assetEntryService;
1015            }
1016    
1017            /**
1018             * Returns the asset entry persistence.
1019             *
1020             * @return the asset entry persistence
1021             */
1022            public AssetEntryPersistence getAssetEntryPersistence() {
1023                    return assetEntryPersistence;
1024            }
1025    
1026            /**
1027             * Sets the asset entry persistence.
1028             *
1029             * @param assetEntryPersistence the asset entry persistence
1030             */
1031            public void setAssetEntryPersistence(
1032                    AssetEntryPersistence assetEntryPersistence) {
1033                    this.assetEntryPersistence = assetEntryPersistence;
1034            }
1035    
1036            /**
1037             * Returns the asset entry finder.
1038             *
1039             * @return the asset entry finder
1040             */
1041            public AssetEntryFinder getAssetEntryFinder() {
1042                    return assetEntryFinder;
1043            }
1044    
1045            /**
1046             * Sets the asset entry finder.
1047             *
1048             * @param assetEntryFinder the asset entry finder
1049             */
1050            public void setAssetEntryFinder(AssetEntryFinder assetEntryFinder) {
1051                    this.assetEntryFinder = assetEntryFinder;
1052            }
1053    
1054            public void afterPropertiesSet() {
1055                    persistedModelLocalServiceRegistry.register("com.liferay.portlet.social.model.SocialActivityCounter",
1056                            socialActivityCounterLocalService);
1057            }
1058    
1059            public void destroy() {
1060                    persistedModelLocalServiceRegistry.unregister(
1061                            "com.liferay.portlet.social.model.SocialActivityCounter");
1062            }
1063    
1064            /**
1065             * Returns the Spring bean ID for this bean.
1066             *
1067             * @return the Spring bean ID for this bean
1068             */
1069            @Override
1070            public String getBeanIdentifier() {
1071                    return _beanIdentifier;
1072            }
1073    
1074            /**
1075             * Sets the Spring bean ID for this bean.
1076             *
1077             * @param beanIdentifier the Spring bean ID for this bean
1078             */
1079            @Override
1080            public void setBeanIdentifier(String beanIdentifier) {
1081                    _beanIdentifier = beanIdentifier;
1082            }
1083    
1084            protected Class<?> getModelClass() {
1085                    return SocialActivityCounter.class;
1086            }
1087    
1088            protected String getModelClassName() {
1089                    return SocialActivityCounter.class.getName();
1090            }
1091    
1092            /**
1093             * Performs an SQL query.
1094             *
1095             * @param sql the sql query
1096             */
1097            protected void runSQL(String sql) throws SystemException {
1098                    try {
1099                            DataSource dataSource = socialActivityCounterPersistence.getDataSource();
1100    
1101                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
1102                                            sql, new int[0]);
1103    
1104                            sqlUpdate.update();
1105                    }
1106                    catch (Exception e) {
1107                            throw new SystemException(e);
1108                    }
1109            }
1110    
1111            @BeanReference(type = com.liferay.portlet.social.service.SocialActivityLocalService.class)
1112            protected com.liferay.portlet.social.service.SocialActivityLocalService socialActivityLocalService;
1113            @BeanReference(type = SocialActivityPersistence.class)
1114            protected SocialActivityPersistence socialActivityPersistence;
1115            @BeanReference(type = SocialActivityFinder.class)
1116            protected SocialActivityFinder socialActivityFinder;
1117            @BeanReference(type = com.liferay.portlet.social.service.SocialActivityAchievementLocalService.class)
1118            protected com.liferay.portlet.social.service.SocialActivityAchievementLocalService socialActivityAchievementLocalService;
1119            @BeanReference(type = SocialActivityAchievementPersistence.class)
1120            protected SocialActivityAchievementPersistence socialActivityAchievementPersistence;
1121            @BeanReference(type = com.liferay.portlet.social.service.SocialActivityCounterLocalService.class)
1122            protected com.liferay.portlet.social.service.SocialActivityCounterLocalService socialActivityCounterLocalService;
1123            @BeanReference(type = SocialActivityCounterPersistence.class)
1124            protected SocialActivityCounterPersistence socialActivityCounterPersistence;
1125            @BeanReference(type = SocialActivityCounterFinder.class)
1126            protected SocialActivityCounterFinder socialActivityCounterFinder;
1127            @BeanReference(type = com.liferay.portlet.social.service.SocialActivityInterpreterLocalService.class)
1128            protected com.liferay.portlet.social.service.SocialActivityInterpreterLocalService socialActivityInterpreterLocalService;
1129            @BeanReference(type = com.liferay.portlet.social.service.SocialActivityLimitLocalService.class)
1130            protected com.liferay.portlet.social.service.SocialActivityLimitLocalService socialActivityLimitLocalService;
1131            @BeanReference(type = SocialActivityLimitPersistence.class)
1132            protected SocialActivityLimitPersistence socialActivityLimitPersistence;
1133            @BeanReference(type = com.liferay.portlet.social.service.SocialActivitySetLocalService.class)
1134            protected com.liferay.portlet.social.service.SocialActivitySetLocalService socialActivitySetLocalService;
1135            @BeanReference(type = SocialActivitySetPersistence.class)
1136            protected SocialActivitySetPersistence socialActivitySetPersistence;
1137            @BeanReference(type = SocialActivitySetFinder.class)
1138            protected SocialActivitySetFinder socialActivitySetFinder;
1139            @BeanReference(type = com.liferay.portlet.social.service.SocialActivitySettingLocalService.class)
1140            protected com.liferay.portlet.social.service.SocialActivitySettingLocalService socialActivitySettingLocalService;
1141            @BeanReference(type = com.liferay.portlet.social.service.SocialActivitySettingService.class)
1142            protected com.liferay.portlet.social.service.SocialActivitySettingService socialActivitySettingService;
1143            @BeanReference(type = SocialActivitySettingPersistence.class)
1144            protected SocialActivitySettingPersistence socialActivitySettingPersistence;
1145            @BeanReference(type = com.liferay.portlet.social.service.SocialRelationLocalService.class)
1146            protected com.liferay.portlet.social.service.SocialRelationLocalService socialRelationLocalService;
1147            @BeanReference(type = SocialRelationPersistence.class)
1148            protected SocialRelationPersistence socialRelationPersistence;
1149            @BeanReference(type = com.liferay.portlet.social.service.SocialRequestLocalService.class)
1150            protected com.liferay.portlet.social.service.SocialRequestLocalService socialRequestLocalService;
1151            @BeanReference(type = com.liferay.portlet.social.service.SocialRequestService.class)
1152            protected com.liferay.portlet.social.service.SocialRequestService socialRequestService;
1153            @BeanReference(type = SocialRequestPersistence.class)
1154            protected SocialRequestPersistence socialRequestPersistence;
1155            @BeanReference(type = com.liferay.portlet.social.service.SocialRequestInterpreterLocalService.class)
1156            protected com.liferay.portlet.social.service.SocialRequestInterpreterLocalService socialRequestInterpreterLocalService;
1157            @BeanReference(type = com.liferay.counter.service.CounterLocalService.class)
1158            protected com.liferay.counter.service.CounterLocalService counterLocalService;
1159            @BeanReference(type = com.liferay.portal.service.GroupLocalService.class)
1160            protected com.liferay.portal.service.GroupLocalService groupLocalService;
1161            @BeanReference(type = com.liferay.portal.service.GroupService.class)
1162            protected com.liferay.portal.service.GroupService groupService;
1163            @BeanReference(type = GroupPersistence.class)
1164            protected GroupPersistence groupPersistence;
1165            @BeanReference(type = GroupFinder.class)
1166            protected GroupFinder groupFinder;
1167            @BeanReference(type = com.liferay.portal.service.LockLocalService.class)
1168            protected com.liferay.portal.service.LockLocalService lockLocalService;
1169            @BeanReference(type = LockPersistence.class)
1170            protected LockPersistence lockPersistence;
1171            @BeanReference(type = LockFinder.class)
1172            protected LockFinder lockFinder;
1173            @BeanReference(type = com.liferay.portal.service.ResourceLocalService.class)
1174            protected com.liferay.portal.service.ResourceLocalService resourceLocalService;
1175            @BeanReference(type = com.liferay.portal.service.UserLocalService.class)
1176            protected com.liferay.portal.service.UserLocalService userLocalService;
1177            @BeanReference(type = com.liferay.portal.service.UserService.class)
1178            protected com.liferay.portal.service.UserService userService;
1179            @BeanReference(type = UserPersistence.class)
1180            protected UserPersistence userPersistence;
1181            @BeanReference(type = UserFinder.class)
1182            protected UserFinder userFinder;
1183            @BeanReference(type = com.liferay.portlet.asset.service.AssetEntryLocalService.class)
1184            protected com.liferay.portlet.asset.service.AssetEntryLocalService assetEntryLocalService;
1185            @BeanReference(type = com.liferay.portlet.asset.service.AssetEntryService.class)
1186            protected com.liferay.portlet.asset.service.AssetEntryService assetEntryService;
1187            @BeanReference(type = AssetEntryPersistence.class)
1188            protected AssetEntryPersistence assetEntryPersistence;
1189            @BeanReference(type = AssetEntryFinder.class)
1190            protected AssetEntryFinder assetEntryFinder;
1191            @BeanReference(type = PersistedModelLocalServiceRegistry.class)
1192            protected PersistedModelLocalServiceRegistry persistedModelLocalServiceRegistry;
1193            private String _beanIdentifier;
1194    }