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.ratings.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.PersistedModelLocalServiceRegistry;
033    import com.liferay.portal.service.ResourceLocalService;
034    import com.liferay.portal.service.ResourceService;
035    import com.liferay.portal.service.UserLocalService;
036    import com.liferay.portal.service.UserService;
037    import com.liferay.portal.service.persistence.ResourceFinder;
038    import com.liferay.portal.service.persistence.ResourcePersistence;
039    import com.liferay.portal.service.persistence.UserFinder;
040    import com.liferay.portal.service.persistence.UserPersistence;
041    
042    import com.liferay.portlet.asset.service.AssetEntryLocalService;
043    import com.liferay.portlet.asset.service.AssetEntryService;
044    import com.liferay.portlet.asset.service.persistence.AssetEntryFinder;
045    import com.liferay.portlet.asset.service.persistence.AssetEntryPersistence;
046    import com.liferay.portlet.blogs.service.BlogsEntryLocalService;
047    import com.liferay.portlet.blogs.service.BlogsEntryService;
048    import com.liferay.portlet.blogs.service.BlogsStatsUserLocalService;
049    import com.liferay.portlet.blogs.service.persistence.BlogsEntryFinder;
050    import com.liferay.portlet.blogs.service.persistence.BlogsEntryPersistence;
051    import com.liferay.portlet.blogs.service.persistence.BlogsStatsUserFinder;
052    import com.liferay.portlet.blogs.service.persistence.BlogsStatsUserPersistence;
053    import com.liferay.portlet.ratings.model.RatingsEntry;
054    import com.liferay.portlet.ratings.service.RatingsEntryLocalService;
055    import com.liferay.portlet.ratings.service.RatingsEntryService;
056    import com.liferay.portlet.ratings.service.RatingsStatsLocalService;
057    import com.liferay.portlet.ratings.service.persistence.RatingsEntryFinder;
058    import com.liferay.portlet.ratings.service.persistence.RatingsEntryPersistence;
059    import com.liferay.portlet.ratings.service.persistence.RatingsStatsFinder;
060    import com.liferay.portlet.ratings.service.persistence.RatingsStatsPersistence;
061    import com.liferay.portlet.social.service.SocialActivityLocalService;
062    import com.liferay.portlet.social.service.persistence.SocialActivityFinder;
063    import com.liferay.portlet.social.service.persistence.SocialActivityPersistence;
064    
065    import java.io.Serializable;
066    
067    import java.util.List;
068    
069    import javax.sql.DataSource;
070    
071    /**
072     * The base implementation of the ratings entry local service.
073     *
074     * <p>
075     * 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.ratings.service.impl.RatingsEntryLocalServiceImpl}.
076     * </p>
077     *
078     * @author Brian Wing Shun Chan
079     * @see com.liferay.portlet.ratings.service.impl.RatingsEntryLocalServiceImpl
080     * @see com.liferay.portlet.ratings.service.RatingsEntryLocalServiceUtil
081     * @generated
082     */
083    public abstract class RatingsEntryLocalServiceBaseImpl
084            extends BaseLocalServiceImpl implements RatingsEntryLocalService,
085                    IdentifiableBean {
086            /*
087             * NOTE FOR DEVELOPERS:
088             *
089             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.ratings.service.RatingsEntryLocalServiceUtil} to access the ratings entry local service.
090             */
091    
092            /**
093             * Adds the ratings entry to the database. Also notifies the appropriate model listeners.
094             *
095             * @param ratingsEntry the ratings entry
096             * @return the ratings entry that was added
097             * @throws SystemException if a system exception occurred
098             */
099            @Indexable(type = IndexableType.REINDEX)
100            public RatingsEntry addRatingsEntry(RatingsEntry ratingsEntry)
101                    throws SystemException {
102                    ratingsEntry.setNew(true);
103    
104                    return ratingsEntryPersistence.update(ratingsEntry, false);
105            }
106    
107            /**
108             * Creates a new ratings entry with the primary key. Does not add the ratings entry to the database.
109             *
110             * @param entryId the primary key for the new ratings entry
111             * @return the new ratings entry
112             */
113            public RatingsEntry createRatingsEntry(long entryId) {
114                    return ratingsEntryPersistence.create(entryId);
115            }
116    
117            /**
118             * Deletes the ratings entry with the primary key from the database. Also notifies the appropriate model listeners.
119             *
120             * @param entryId the primary key of the ratings entry
121             * @return the ratings entry that was removed
122             * @throws PortalException if a ratings entry with the primary key could not be found
123             * @throws SystemException if a system exception occurred
124             */
125            @Indexable(type = IndexableType.DELETE)
126            public RatingsEntry deleteRatingsEntry(long entryId)
127                    throws PortalException, SystemException {
128                    return ratingsEntryPersistence.remove(entryId);
129            }
130    
131            /**
132             * Deletes the ratings entry from the database. Also notifies the appropriate model listeners.
133             *
134             * @param ratingsEntry the ratings entry
135             * @return the ratings entry that was removed
136             * @throws SystemException if a system exception occurred
137             */
138            @Indexable(type = IndexableType.DELETE)
139            public RatingsEntry deleteRatingsEntry(RatingsEntry ratingsEntry)
140                    throws SystemException {
141                    return ratingsEntryPersistence.remove(ratingsEntry);
142            }
143    
144            public DynamicQuery dynamicQuery() {
145                    Class<?> clazz = getClass();
146    
147                    return DynamicQueryFactoryUtil.forClass(RatingsEntry.class,
148                            clazz.getClassLoader());
149            }
150    
151            /**
152             * Performs a dynamic query on the database and returns the matching rows.
153             *
154             * @param dynamicQuery the dynamic query
155             * @return the matching rows
156             * @throws SystemException if a system exception occurred
157             */
158            @SuppressWarnings("rawtypes")
159            public List dynamicQuery(DynamicQuery dynamicQuery)
160                    throws SystemException {
161                    return ratingsEntryPersistence.findWithDynamicQuery(dynamicQuery);
162            }
163    
164            /**
165             * Performs a dynamic query on the database and returns a range of the matching rows.
166             *
167             * <p>
168             * 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.
169             * </p>
170             *
171             * @param dynamicQuery the dynamic query
172             * @param start the lower bound of the range of model instances
173             * @param end the upper bound of the range of model instances (not inclusive)
174             * @return the range of matching rows
175             * @throws SystemException if a system exception occurred
176             */
177            @SuppressWarnings("rawtypes")
178            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
179                    throws SystemException {
180                    return ratingsEntryPersistence.findWithDynamicQuery(dynamicQuery,
181                            start, end);
182            }
183    
184            /**
185             * Performs a dynamic query on the database and returns an ordered range of the matching rows.
186             *
187             * <p>
188             * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
189             * </p>
190             *
191             * @param dynamicQuery the dynamic query
192             * @param start the lower bound of the range of model instances
193             * @param end the upper bound of the range of model instances (not inclusive)
194             * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
195             * @return the ordered range of matching rows
196             * @throws SystemException if a system exception occurred
197             */
198            @SuppressWarnings("rawtypes")
199            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end,
200                    OrderByComparator orderByComparator) throws SystemException {
201                    return ratingsEntryPersistence.findWithDynamicQuery(dynamicQuery,
202                            start, end, orderByComparator);
203            }
204    
205            /**
206             * Returns the number of rows that match the dynamic query.
207             *
208             * @param dynamicQuery the dynamic query
209             * @return the number of rows that match the dynamic query
210             * @throws SystemException if a system exception occurred
211             */
212            public long dynamicQueryCount(DynamicQuery dynamicQuery)
213                    throws SystemException {
214                    return ratingsEntryPersistence.countWithDynamicQuery(dynamicQuery);
215            }
216    
217            public RatingsEntry fetchRatingsEntry(long entryId)
218                    throws SystemException {
219                    return ratingsEntryPersistence.fetchByPrimaryKey(entryId);
220            }
221    
222            /**
223             * Returns the ratings entry with the primary key.
224             *
225             * @param entryId the primary key of the ratings entry
226             * @return the ratings entry
227             * @throws PortalException if a ratings entry with the primary key could not be found
228             * @throws SystemException if a system exception occurred
229             */
230            public RatingsEntry getRatingsEntry(long entryId)
231                    throws PortalException, SystemException {
232                    return ratingsEntryPersistence.findByPrimaryKey(entryId);
233            }
234    
235            public PersistedModel getPersistedModel(Serializable primaryKeyObj)
236                    throws PortalException, SystemException {
237                    return ratingsEntryPersistence.findByPrimaryKey(primaryKeyObj);
238            }
239    
240            /**
241             * Returns a range of all the ratings entries.
242             *
243             * <p>
244             * 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.
245             * </p>
246             *
247             * @param start the lower bound of the range of ratings entries
248             * @param end the upper bound of the range of ratings entries (not inclusive)
249             * @return the range of ratings entries
250             * @throws SystemException if a system exception occurred
251             */
252            public List<RatingsEntry> getRatingsEntries(int start, int end)
253                    throws SystemException {
254                    return ratingsEntryPersistence.findAll(start, end);
255            }
256    
257            /**
258             * Returns the number of ratings entries.
259             *
260             * @return the number of ratings entries
261             * @throws SystemException if a system exception occurred
262             */
263            public int getRatingsEntriesCount() throws SystemException {
264                    return ratingsEntryPersistence.countAll();
265            }
266    
267            /**
268             * Updates the ratings entry in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
269             *
270             * @param ratingsEntry the ratings entry
271             * @return the ratings entry that was updated
272             * @throws SystemException if a system exception occurred
273             */
274            @Indexable(type = IndexableType.REINDEX)
275            public RatingsEntry updateRatingsEntry(RatingsEntry ratingsEntry)
276                    throws SystemException {
277                    return updateRatingsEntry(ratingsEntry, true);
278            }
279    
280            /**
281             * Updates the ratings entry in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
282             *
283             * @param ratingsEntry the ratings entry
284             * @param merge whether to merge the ratings entry with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
285             * @return the ratings entry that was updated
286             * @throws SystemException if a system exception occurred
287             */
288            @Indexable(type = IndexableType.REINDEX)
289            public RatingsEntry updateRatingsEntry(RatingsEntry ratingsEntry,
290                    boolean merge) throws SystemException {
291                    ratingsEntry.setNew(false);
292    
293                    return ratingsEntryPersistence.update(ratingsEntry, merge);
294            }
295    
296            /**
297             * Returns the ratings entry local service.
298             *
299             * @return the ratings entry local service
300             */
301            public RatingsEntryLocalService getRatingsEntryLocalService() {
302                    return ratingsEntryLocalService;
303            }
304    
305            /**
306             * Sets the ratings entry local service.
307             *
308             * @param ratingsEntryLocalService the ratings entry local service
309             */
310            public void setRatingsEntryLocalService(
311                    RatingsEntryLocalService ratingsEntryLocalService) {
312                    this.ratingsEntryLocalService = ratingsEntryLocalService;
313            }
314    
315            /**
316             * Returns the ratings entry remote service.
317             *
318             * @return the ratings entry remote service
319             */
320            public RatingsEntryService getRatingsEntryService() {
321                    return ratingsEntryService;
322            }
323    
324            /**
325             * Sets the ratings entry remote service.
326             *
327             * @param ratingsEntryService the ratings entry remote service
328             */
329            public void setRatingsEntryService(RatingsEntryService ratingsEntryService) {
330                    this.ratingsEntryService = ratingsEntryService;
331            }
332    
333            /**
334             * Returns the ratings entry persistence.
335             *
336             * @return the ratings entry persistence
337             */
338            public RatingsEntryPersistence getRatingsEntryPersistence() {
339                    return ratingsEntryPersistence;
340            }
341    
342            /**
343             * Sets the ratings entry persistence.
344             *
345             * @param ratingsEntryPersistence the ratings entry persistence
346             */
347            public void setRatingsEntryPersistence(
348                    RatingsEntryPersistence ratingsEntryPersistence) {
349                    this.ratingsEntryPersistence = ratingsEntryPersistence;
350            }
351    
352            /**
353             * Returns the ratings entry finder.
354             *
355             * @return the ratings entry finder
356             */
357            public RatingsEntryFinder getRatingsEntryFinder() {
358                    return ratingsEntryFinder;
359            }
360    
361            /**
362             * Sets the ratings entry finder.
363             *
364             * @param ratingsEntryFinder the ratings entry finder
365             */
366            public void setRatingsEntryFinder(RatingsEntryFinder ratingsEntryFinder) {
367                    this.ratingsEntryFinder = ratingsEntryFinder;
368            }
369    
370            /**
371             * Returns the ratings stats local service.
372             *
373             * @return the ratings stats local service
374             */
375            public RatingsStatsLocalService getRatingsStatsLocalService() {
376                    return ratingsStatsLocalService;
377            }
378    
379            /**
380             * Sets the ratings stats local service.
381             *
382             * @param ratingsStatsLocalService the ratings stats local service
383             */
384            public void setRatingsStatsLocalService(
385                    RatingsStatsLocalService ratingsStatsLocalService) {
386                    this.ratingsStatsLocalService = ratingsStatsLocalService;
387            }
388    
389            /**
390             * Returns the ratings stats persistence.
391             *
392             * @return the ratings stats persistence
393             */
394            public RatingsStatsPersistence getRatingsStatsPersistence() {
395                    return ratingsStatsPersistence;
396            }
397    
398            /**
399             * Sets the ratings stats persistence.
400             *
401             * @param ratingsStatsPersistence the ratings stats persistence
402             */
403            public void setRatingsStatsPersistence(
404                    RatingsStatsPersistence ratingsStatsPersistence) {
405                    this.ratingsStatsPersistence = ratingsStatsPersistence;
406            }
407    
408            /**
409             * Returns the ratings stats finder.
410             *
411             * @return the ratings stats finder
412             */
413            public RatingsStatsFinder getRatingsStatsFinder() {
414                    return ratingsStatsFinder;
415            }
416    
417            /**
418             * Sets the ratings stats finder.
419             *
420             * @param ratingsStatsFinder the ratings stats finder
421             */
422            public void setRatingsStatsFinder(RatingsStatsFinder ratingsStatsFinder) {
423                    this.ratingsStatsFinder = ratingsStatsFinder;
424            }
425    
426            /**
427             * Returns the counter local service.
428             *
429             * @return the counter local service
430             */
431            public CounterLocalService getCounterLocalService() {
432                    return counterLocalService;
433            }
434    
435            /**
436             * Sets the counter local service.
437             *
438             * @param counterLocalService the counter local service
439             */
440            public void setCounterLocalService(CounterLocalService counterLocalService) {
441                    this.counterLocalService = counterLocalService;
442            }
443    
444            /**
445             * Returns the resource local service.
446             *
447             * @return the resource local service
448             */
449            public ResourceLocalService getResourceLocalService() {
450                    return resourceLocalService;
451            }
452    
453            /**
454             * Sets the resource local service.
455             *
456             * @param resourceLocalService the resource local service
457             */
458            public void setResourceLocalService(
459                    ResourceLocalService resourceLocalService) {
460                    this.resourceLocalService = resourceLocalService;
461            }
462    
463            /**
464             * Returns the resource remote service.
465             *
466             * @return the resource remote service
467             */
468            public ResourceService getResourceService() {
469                    return resourceService;
470            }
471    
472            /**
473             * Sets the resource remote service.
474             *
475             * @param resourceService the resource remote service
476             */
477            public void setResourceService(ResourceService resourceService) {
478                    this.resourceService = resourceService;
479            }
480    
481            /**
482             * Returns the resource persistence.
483             *
484             * @return the resource persistence
485             */
486            public ResourcePersistence getResourcePersistence() {
487                    return resourcePersistence;
488            }
489    
490            /**
491             * Sets the resource persistence.
492             *
493             * @param resourcePersistence the resource persistence
494             */
495            public void setResourcePersistence(ResourcePersistence resourcePersistence) {
496                    this.resourcePersistence = resourcePersistence;
497            }
498    
499            /**
500             * Returns the resource finder.
501             *
502             * @return the resource finder
503             */
504            public ResourceFinder getResourceFinder() {
505                    return resourceFinder;
506            }
507    
508            /**
509             * Sets the resource finder.
510             *
511             * @param resourceFinder the resource finder
512             */
513            public void setResourceFinder(ResourceFinder resourceFinder) {
514                    this.resourceFinder = resourceFinder;
515            }
516    
517            /**
518             * Returns the user local service.
519             *
520             * @return the user local service
521             */
522            public UserLocalService getUserLocalService() {
523                    return userLocalService;
524            }
525    
526            /**
527             * Sets the user local service.
528             *
529             * @param userLocalService the user local service
530             */
531            public void setUserLocalService(UserLocalService userLocalService) {
532                    this.userLocalService = userLocalService;
533            }
534    
535            /**
536             * Returns the user remote service.
537             *
538             * @return the user remote service
539             */
540            public UserService getUserService() {
541                    return userService;
542            }
543    
544            /**
545             * Sets the user remote service.
546             *
547             * @param userService the user remote service
548             */
549            public void setUserService(UserService userService) {
550                    this.userService = userService;
551            }
552    
553            /**
554             * Returns the user persistence.
555             *
556             * @return the user persistence
557             */
558            public UserPersistence getUserPersistence() {
559                    return userPersistence;
560            }
561    
562            /**
563             * Sets the user persistence.
564             *
565             * @param userPersistence the user persistence
566             */
567            public void setUserPersistence(UserPersistence userPersistence) {
568                    this.userPersistence = userPersistence;
569            }
570    
571            /**
572             * Returns the user finder.
573             *
574             * @return the user finder
575             */
576            public UserFinder getUserFinder() {
577                    return userFinder;
578            }
579    
580            /**
581             * Sets the user finder.
582             *
583             * @param userFinder the user finder
584             */
585            public void setUserFinder(UserFinder userFinder) {
586                    this.userFinder = userFinder;
587            }
588    
589            /**
590             * Returns the asset entry local service.
591             *
592             * @return the asset entry local service
593             */
594            public AssetEntryLocalService getAssetEntryLocalService() {
595                    return assetEntryLocalService;
596            }
597    
598            /**
599             * Sets the asset entry local service.
600             *
601             * @param assetEntryLocalService the asset entry local service
602             */
603            public void setAssetEntryLocalService(
604                    AssetEntryLocalService assetEntryLocalService) {
605                    this.assetEntryLocalService = assetEntryLocalService;
606            }
607    
608            /**
609             * Returns the asset entry remote service.
610             *
611             * @return the asset entry remote service
612             */
613            public AssetEntryService getAssetEntryService() {
614                    return assetEntryService;
615            }
616    
617            /**
618             * Sets the asset entry remote service.
619             *
620             * @param assetEntryService the asset entry remote service
621             */
622            public void setAssetEntryService(AssetEntryService assetEntryService) {
623                    this.assetEntryService = assetEntryService;
624            }
625    
626            /**
627             * Returns the asset entry persistence.
628             *
629             * @return the asset entry persistence
630             */
631            public AssetEntryPersistence getAssetEntryPersistence() {
632                    return assetEntryPersistence;
633            }
634    
635            /**
636             * Sets the asset entry persistence.
637             *
638             * @param assetEntryPersistence the asset entry persistence
639             */
640            public void setAssetEntryPersistence(
641                    AssetEntryPersistence assetEntryPersistence) {
642                    this.assetEntryPersistence = assetEntryPersistence;
643            }
644    
645            /**
646             * Returns the asset entry finder.
647             *
648             * @return the asset entry finder
649             */
650            public AssetEntryFinder getAssetEntryFinder() {
651                    return assetEntryFinder;
652            }
653    
654            /**
655             * Sets the asset entry finder.
656             *
657             * @param assetEntryFinder the asset entry finder
658             */
659            public void setAssetEntryFinder(AssetEntryFinder assetEntryFinder) {
660                    this.assetEntryFinder = assetEntryFinder;
661            }
662    
663            /**
664             * Returns the blogs entry local service.
665             *
666             * @return the blogs entry local service
667             */
668            public BlogsEntryLocalService getBlogsEntryLocalService() {
669                    return blogsEntryLocalService;
670            }
671    
672            /**
673             * Sets the blogs entry local service.
674             *
675             * @param blogsEntryLocalService the blogs entry local service
676             */
677            public void setBlogsEntryLocalService(
678                    BlogsEntryLocalService blogsEntryLocalService) {
679                    this.blogsEntryLocalService = blogsEntryLocalService;
680            }
681    
682            /**
683             * Returns the blogs entry remote service.
684             *
685             * @return the blogs entry remote service
686             */
687            public BlogsEntryService getBlogsEntryService() {
688                    return blogsEntryService;
689            }
690    
691            /**
692             * Sets the blogs entry remote service.
693             *
694             * @param blogsEntryService the blogs entry remote service
695             */
696            public void setBlogsEntryService(BlogsEntryService blogsEntryService) {
697                    this.blogsEntryService = blogsEntryService;
698            }
699    
700            /**
701             * Returns the blogs entry persistence.
702             *
703             * @return the blogs entry persistence
704             */
705            public BlogsEntryPersistence getBlogsEntryPersistence() {
706                    return blogsEntryPersistence;
707            }
708    
709            /**
710             * Sets the blogs entry persistence.
711             *
712             * @param blogsEntryPersistence the blogs entry persistence
713             */
714            public void setBlogsEntryPersistence(
715                    BlogsEntryPersistence blogsEntryPersistence) {
716                    this.blogsEntryPersistence = blogsEntryPersistence;
717            }
718    
719            /**
720             * Returns the blogs entry finder.
721             *
722             * @return the blogs entry finder
723             */
724            public BlogsEntryFinder getBlogsEntryFinder() {
725                    return blogsEntryFinder;
726            }
727    
728            /**
729             * Sets the blogs entry finder.
730             *
731             * @param blogsEntryFinder the blogs entry finder
732             */
733            public void setBlogsEntryFinder(BlogsEntryFinder blogsEntryFinder) {
734                    this.blogsEntryFinder = blogsEntryFinder;
735            }
736    
737            /**
738             * Returns the blogs stats user local service.
739             *
740             * @return the blogs stats user local service
741             */
742            public BlogsStatsUserLocalService getBlogsStatsUserLocalService() {
743                    return blogsStatsUserLocalService;
744            }
745    
746            /**
747             * Sets the blogs stats user local service.
748             *
749             * @param blogsStatsUserLocalService the blogs stats user local service
750             */
751            public void setBlogsStatsUserLocalService(
752                    BlogsStatsUserLocalService blogsStatsUserLocalService) {
753                    this.blogsStatsUserLocalService = blogsStatsUserLocalService;
754            }
755    
756            /**
757             * Returns the blogs stats user persistence.
758             *
759             * @return the blogs stats user persistence
760             */
761            public BlogsStatsUserPersistence getBlogsStatsUserPersistence() {
762                    return blogsStatsUserPersistence;
763            }
764    
765            /**
766             * Sets the blogs stats user persistence.
767             *
768             * @param blogsStatsUserPersistence the blogs stats user persistence
769             */
770            public void setBlogsStatsUserPersistence(
771                    BlogsStatsUserPersistence blogsStatsUserPersistence) {
772                    this.blogsStatsUserPersistence = blogsStatsUserPersistence;
773            }
774    
775            /**
776             * Returns the blogs stats user finder.
777             *
778             * @return the blogs stats user finder
779             */
780            public BlogsStatsUserFinder getBlogsStatsUserFinder() {
781                    return blogsStatsUserFinder;
782            }
783    
784            /**
785             * Sets the blogs stats user finder.
786             *
787             * @param blogsStatsUserFinder the blogs stats user finder
788             */
789            public void setBlogsStatsUserFinder(
790                    BlogsStatsUserFinder blogsStatsUserFinder) {
791                    this.blogsStatsUserFinder = blogsStatsUserFinder;
792            }
793    
794            /**
795             * Returns the social activity local service.
796             *
797             * @return the social activity local service
798             */
799            public SocialActivityLocalService getSocialActivityLocalService() {
800                    return socialActivityLocalService;
801            }
802    
803            /**
804             * Sets the social activity local service.
805             *
806             * @param socialActivityLocalService the social activity local service
807             */
808            public void setSocialActivityLocalService(
809                    SocialActivityLocalService socialActivityLocalService) {
810                    this.socialActivityLocalService = socialActivityLocalService;
811            }
812    
813            /**
814             * Returns the social activity persistence.
815             *
816             * @return the social activity persistence
817             */
818            public SocialActivityPersistence getSocialActivityPersistence() {
819                    return socialActivityPersistence;
820            }
821    
822            /**
823             * Sets the social activity persistence.
824             *
825             * @param socialActivityPersistence the social activity persistence
826             */
827            public void setSocialActivityPersistence(
828                    SocialActivityPersistence socialActivityPersistence) {
829                    this.socialActivityPersistence = socialActivityPersistence;
830            }
831    
832            /**
833             * Returns the social activity finder.
834             *
835             * @return the social activity finder
836             */
837            public SocialActivityFinder getSocialActivityFinder() {
838                    return socialActivityFinder;
839            }
840    
841            /**
842             * Sets the social activity finder.
843             *
844             * @param socialActivityFinder the social activity finder
845             */
846            public void setSocialActivityFinder(
847                    SocialActivityFinder socialActivityFinder) {
848                    this.socialActivityFinder = socialActivityFinder;
849            }
850    
851            public void afterPropertiesSet() {
852                    persistedModelLocalServiceRegistry.register("com.liferay.portlet.ratings.model.RatingsEntry",
853                            ratingsEntryLocalService);
854            }
855    
856            public void destroy() {
857                    persistedModelLocalServiceRegistry.unregister(
858                            "com.liferay.portlet.ratings.model.RatingsEntry");
859            }
860    
861            /**
862             * Returns the Spring bean ID for this bean.
863             *
864             * @return the Spring bean ID for this bean
865             */
866            public String getBeanIdentifier() {
867                    return _beanIdentifier;
868            }
869    
870            /**
871             * Sets the Spring bean ID for this bean.
872             *
873             * @param beanIdentifier the Spring bean ID for this bean
874             */
875            public void setBeanIdentifier(String beanIdentifier) {
876                    _beanIdentifier = beanIdentifier;
877            }
878    
879            protected Class<?> getModelClass() {
880                    return RatingsEntry.class;
881            }
882    
883            protected String getModelClassName() {
884                    return RatingsEntry.class.getName();
885            }
886    
887            /**
888             * Performs an SQL query.
889             *
890             * @param sql the sql query
891             */
892            protected void runSQL(String sql) throws SystemException {
893                    try {
894                            DataSource dataSource = ratingsEntryPersistence.getDataSource();
895    
896                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
897                                            sql, new int[0]);
898    
899                            sqlUpdate.update();
900                    }
901                    catch (Exception e) {
902                            throw new SystemException(e);
903                    }
904            }
905    
906            @BeanReference(type = RatingsEntryLocalService.class)
907            protected RatingsEntryLocalService ratingsEntryLocalService;
908            @BeanReference(type = RatingsEntryService.class)
909            protected RatingsEntryService ratingsEntryService;
910            @BeanReference(type = RatingsEntryPersistence.class)
911            protected RatingsEntryPersistence ratingsEntryPersistence;
912            @BeanReference(type = RatingsEntryFinder.class)
913            protected RatingsEntryFinder ratingsEntryFinder;
914            @BeanReference(type = RatingsStatsLocalService.class)
915            protected RatingsStatsLocalService ratingsStatsLocalService;
916            @BeanReference(type = RatingsStatsPersistence.class)
917            protected RatingsStatsPersistence ratingsStatsPersistence;
918            @BeanReference(type = RatingsStatsFinder.class)
919            protected RatingsStatsFinder ratingsStatsFinder;
920            @BeanReference(type = CounterLocalService.class)
921            protected CounterLocalService counterLocalService;
922            @BeanReference(type = ResourceLocalService.class)
923            protected ResourceLocalService resourceLocalService;
924            @BeanReference(type = ResourceService.class)
925            protected ResourceService resourceService;
926            @BeanReference(type = ResourcePersistence.class)
927            protected ResourcePersistence resourcePersistence;
928            @BeanReference(type = ResourceFinder.class)
929            protected ResourceFinder resourceFinder;
930            @BeanReference(type = UserLocalService.class)
931            protected UserLocalService userLocalService;
932            @BeanReference(type = UserService.class)
933            protected UserService userService;
934            @BeanReference(type = UserPersistence.class)
935            protected UserPersistence userPersistence;
936            @BeanReference(type = UserFinder.class)
937            protected UserFinder userFinder;
938            @BeanReference(type = AssetEntryLocalService.class)
939            protected AssetEntryLocalService assetEntryLocalService;
940            @BeanReference(type = AssetEntryService.class)
941            protected AssetEntryService assetEntryService;
942            @BeanReference(type = AssetEntryPersistence.class)
943            protected AssetEntryPersistence assetEntryPersistence;
944            @BeanReference(type = AssetEntryFinder.class)
945            protected AssetEntryFinder assetEntryFinder;
946            @BeanReference(type = BlogsEntryLocalService.class)
947            protected BlogsEntryLocalService blogsEntryLocalService;
948            @BeanReference(type = BlogsEntryService.class)
949            protected BlogsEntryService blogsEntryService;
950            @BeanReference(type = BlogsEntryPersistence.class)
951            protected BlogsEntryPersistence blogsEntryPersistence;
952            @BeanReference(type = BlogsEntryFinder.class)
953            protected BlogsEntryFinder blogsEntryFinder;
954            @BeanReference(type = BlogsStatsUserLocalService.class)
955            protected BlogsStatsUserLocalService blogsStatsUserLocalService;
956            @BeanReference(type = BlogsStatsUserPersistence.class)
957            protected BlogsStatsUserPersistence blogsStatsUserPersistence;
958            @BeanReference(type = BlogsStatsUserFinder.class)
959            protected BlogsStatsUserFinder blogsStatsUserFinder;
960            @BeanReference(type = SocialActivityLocalService.class)
961            protected SocialActivityLocalService socialActivityLocalService;
962            @BeanReference(type = SocialActivityPersistence.class)
963            protected SocialActivityPersistence socialActivityPersistence;
964            @BeanReference(type = SocialActivityFinder.class)
965            protected SocialActivityFinder socialActivityFinder;
966            @BeanReference(type = PersistedModelLocalServiceRegistry.class)
967            protected PersistedModelLocalServiceRegistry persistedModelLocalServiceRegistry;
968            private String _beanIdentifier;
969    }