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.journal.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.expando.service.ExpandoValueLocalService;
043    import com.liferay.portlet.expando.service.ExpandoValueService;
044    import com.liferay.portlet.expando.service.persistence.ExpandoValuePersistence;
045    import com.liferay.portlet.journal.model.JournalFeed;
046    import com.liferay.portlet.journal.service.JournalArticleImageLocalService;
047    import com.liferay.portlet.journal.service.JournalArticleLocalService;
048    import com.liferay.portlet.journal.service.JournalArticleResourceLocalService;
049    import com.liferay.portlet.journal.service.JournalArticleService;
050    import com.liferay.portlet.journal.service.JournalContentSearchLocalService;
051    import com.liferay.portlet.journal.service.JournalFeedLocalService;
052    import com.liferay.portlet.journal.service.JournalFeedService;
053    import com.liferay.portlet.journal.service.JournalStructureLocalService;
054    import com.liferay.portlet.journal.service.JournalStructureService;
055    import com.liferay.portlet.journal.service.JournalTemplateLocalService;
056    import com.liferay.portlet.journal.service.JournalTemplateService;
057    import com.liferay.portlet.journal.service.persistence.JournalArticleFinder;
058    import com.liferay.portlet.journal.service.persistence.JournalArticleImagePersistence;
059    import com.liferay.portlet.journal.service.persistence.JournalArticlePersistence;
060    import com.liferay.portlet.journal.service.persistence.JournalArticleResourcePersistence;
061    import com.liferay.portlet.journal.service.persistence.JournalContentSearchPersistence;
062    import com.liferay.portlet.journal.service.persistence.JournalFeedFinder;
063    import com.liferay.portlet.journal.service.persistence.JournalFeedPersistence;
064    import com.liferay.portlet.journal.service.persistence.JournalStructureFinder;
065    import com.liferay.portlet.journal.service.persistence.JournalStructurePersistence;
066    import com.liferay.portlet.journal.service.persistence.JournalTemplateFinder;
067    import com.liferay.portlet.journal.service.persistence.JournalTemplatePersistence;
068    
069    import java.io.Serializable;
070    
071    import java.util.List;
072    
073    import javax.sql.DataSource;
074    
075    /**
076     * The base implementation of the journal feed local service.
077     *
078     * <p>
079     * 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.journal.service.impl.JournalFeedLocalServiceImpl}.
080     * </p>
081     *
082     * @author Brian Wing Shun Chan
083     * @see com.liferay.portlet.journal.service.impl.JournalFeedLocalServiceImpl
084     * @see com.liferay.portlet.journal.service.JournalFeedLocalServiceUtil
085     * @generated
086     */
087    public abstract class JournalFeedLocalServiceBaseImpl
088            extends BaseLocalServiceImpl implements JournalFeedLocalService,
089                    IdentifiableBean {
090            /*
091             * NOTE FOR DEVELOPERS:
092             *
093             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.journal.service.JournalFeedLocalServiceUtil} to access the journal feed local service.
094             */
095    
096            /**
097             * Adds the journal feed to the database. Also notifies the appropriate model listeners.
098             *
099             * @param journalFeed the journal feed
100             * @return the journal feed that was added
101             * @throws SystemException if a system exception occurred
102             */
103            @Indexable(type = IndexableType.REINDEX)
104            public JournalFeed addJournalFeed(JournalFeed journalFeed)
105                    throws SystemException {
106                    journalFeed.setNew(true);
107    
108                    return journalFeedPersistence.update(journalFeed, false);
109            }
110    
111            /**
112             * Creates a new journal feed with the primary key. Does not add the journal feed to the database.
113             *
114             * @param id the primary key for the new journal feed
115             * @return the new journal feed
116             */
117            public JournalFeed createJournalFeed(long id) {
118                    return journalFeedPersistence.create(id);
119            }
120    
121            /**
122             * Deletes the journal feed with the primary key from the database. Also notifies the appropriate model listeners.
123             *
124             * @param id the primary key of the journal feed
125             * @return the journal feed that was removed
126             * @throws PortalException if a journal feed with the primary key could not be found
127             * @throws SystemException if a system exception occurred
128             */
129            @Indexable(type = IndexableType.DELETE)
130            public JournalFeed deleteJournalFeed(long id)
131                    throws PortalException, SystemException {
132                    return journalFeedPersistence.remove(id);
133            }
134    
135            /**
136             * Deletes the journal feed from the database. Also notifies the appropriate model listeners.
137             *
138             * @param journalFeed the journal feed
139             * @return the journal feed that was removed
140             * @throws SystemException if a system exception occurred
141             */
142            @Indexable(type = IndexableType.DELETE)
143            public JournalFeed deleteJournalFeed(JournalFeed journalFeed)
144                    throws SystemException {
145                    return journalFeedPersistence.remove(journalFeed);
146            }
147    
148            public DynamicQuery dynamicQuery() {
149                    Class<?> clazz = getClass();
150    
151                    return DynamicQueryFactoryUtil.forClass(JournalFeed.class,
152                            clazz.getClassLoader());
153            }
154    
155            /**
156             * Performs a dynamic query on the database and returns the matching rows.
157             *
158             * @param dynamicQuery the dynamic query
159             * @return the matching rows
160             * @throws SystemException if a system exception occurred
161             */
162            @SuppressWarnings("rawtypes")
163            public List dynamicQuery(DynamicQuery dynamicQuery)
164                    throws SystemException {
165                    return journalFeedPersistence.findWithDynamicQuery(dynamicQuery);
166            }
167    
168            /**
169             * Performs a dynamic query on the database and returns a range of the matching rows.
170             *
171             * <p>
172             * 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.
173             * </p>
174             *
175             * @param dynamicQuery the dynamic query
176             * @param start the lower bound of the range of model instances
177             * @param end the upper bound of the range of model instances (not inclusive)
178             * @return the range of matching rows
179             * @throws SystemException if a system exception occurred
180             */
181            @SuppressWarnings("rawtypes")
182            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
183                    throws SystemException {
184                    return journalFeedPersistence.findWithDynamicQuery(dynamicQuery, start,
185                            end);
186            }
187    
188            /**
189             * Performs a dynamic query on the database and returns an ordered range of the matching rows.
190             *
191             * <p>
192             * 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.
193             * </p>
194             *
195             * @param dynamicQuery the dynamic query
196             * @param start the lower bound of the range of model instances
197             * @param end the upper bound of the range of model instances (not inclusive)
198             * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
199             * @return the ordered range of matching rows
200             * @throws SystemException if a system exception occurred
201             */
202            @SuppressWarnings("rawtypes")
203            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end,
204                    OrderByComparator orderByComparator) throws SystemException {
205                    return journalFeedPersistence.findWithDynamicQuery(dynamicQuery, start,
206                            end, orderByComparator);
207            }
208    
209            /**
210             * Returns the number of rows that match the dynamic query.
211             *
212             * @param dynamicQuery the dynamic query
213             * @return the number of rows that match the dynamic query
214             * @throws SystemException if a system exception occurred
215             */
216            public long dynamicQueryCount(DynamicQuery dynamicQuery)
217                    throws SystemException {
218                    return journalFeedPersistence.countWithDynamicQuery(dynamicQuery);
219            }
220    
221            public JournalFeed fetchJournalFeed(long id) throws SystemException {
222                    return journalFeedPersistence.fetchByPrimaryKey(id);
223            }
224    
225            /**
226             * Returns the journal feed with the primary key.
227             *
228             * @param id the primary key of the journal feed
229             * @return the journal feed
230             * @throws PortalException if a journal feed with the primary key could not be found
231             * @throws SystemException if a system exception occurred
232             */
233            public JournalFeed getJournalFeed(long id)
234                    throws PortalException, SystemException {
235                    return journalFeedPersistence.findByPrimaryKey(id);
236            }
237    
238            public PersistedModel getPersistedModel(Serializable primaryKeyObj)
239                    throws PortalException, SystemException {
240                    return journalFeedPersistence.findByPrimaryKey(primaryKeyObj);
241            }
242    
243            /**
244             * Returns the journal feed with the UUID in the group.
245             *
246             * @param uuid the UUID of journal feed
247             * @param groupId the group id of the journal feed
248             * @return the journal feed
249             * @throws PortalException if a journal feed with the UUID in the group could not be found
250             * @throws SystemException if a system exception occurred
251             */
252            public JournalFeed getJournalFeedByUuidAndGroupId(String uuid, long groupId)
253                    throws PortalException, SystemException {
254                    return journalFeedPersistence.findByUUID_G(uuid, groupId);
255            }
256    
257            /**
258             * Returns a range of all the journal feeds.
259             *
260             * <p>
261             * 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.
262             * </p>
263             *
264             * @param start the lower bound of the range of journal feeds
265             * @param end the upper bound of the range of journal feeds (not inclusive)
266             * @return the range of journal feeds
267             * @throws SystemException if a system exception occurred
268             */
269            public List<JournalFeed> getJournalFeeds(int start, int end)
270                    throws SystemException {
271                    return journalFeedPersistence.findAll(start, end);
272            }
273    
274            /**
275             * Returns the number of journal feeds.
276             *
277             * @return the number of journal feeds
278             * @throws SystemException if a system exception occurred
279             */
280            public int getJournalFeedsCount() throws SystemException {
281                    return journalFeedPersistence.countAll();
282            }
283    
284            /**
285             * Updates the journal feed in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
286             *
287             * @param journalFeed the journal feed
288             * @return the journal feed that was updated
289             * @throws SystemException if a system exception occurred
290             */
291            @Indexable(type = IndexableType.REINDEX)
292            public JournalFeed updateJournalFeed(JournalFeed journalFeed)
293                    throws SystemException {
294                    return updateJournalFeed(journalFeed, true);
295            }
296    
297            /**
298             * Updates the journal feed in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
299             *
300             * @param journalFeed the journal feed
301             * @param merge whether to merge the journal feed 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.
302             * @return the journal feed that was updated
303             * @throws SystemException if a system exception occurred
304             */
305            @Indexable(type = IndexableType.REINDEX)
306            public JournalFeed updateJournalFeed(JournalFeed journalFeed, boolean merge)
307                    throws SystemException {
308                    journalFeed.setNew(false);
309    
310                    return journalFeedPersistence.update(journalFeed, merge);
311            }
312    
313            /**
314             * Returns the journal article local service.
315             *
316             * @return the journal article local service
317             */
318            public JournalArticleLocalService getJournalArticleLocalService() {
319                    return journalArticleLocalService;
320            }
321    
322            /**
323             * Sets the journal article local service.
324             *
325             * @param journalArticleLocalService the journal article local service
326             */
327            public void setJournalArticleLocalService(
328                    JournalArticleLocalService journalArticleLocalService) {
329                    this.journalArticleLocalService = journalArticleLocalService;
330            }
331    
332            /**
333             * Returns the journal article remote service.
334             *
335             * @return the journal article remote service
336             */
337            public JournalArticleService getJournalArticleService() {
338                    return journalArticleService;
339            }
340    
341            /**
342             * Sets the journal article remote service.
343             *
344             * @param journalArticleService the journal article remote service
345             */
346            public void setJournalArticleService(
347                    JournalArticleService journalArticleService) {
348                    this.journalArticleService = journalArticleService;
349            }
350    
351            /**
352             * Returns the journal article persistence.
353             *
354             * @return the journal article persistence
355             */
356            public JournalArticlePersistence getJournalArticlePersistence() {
357                    return journalArticlePersistence;
358            }
359    
360            /**
361             * Sets the journal article persistence.
362             *
363             * @param journalArticlePersistence the journal article persistence
364             */
365            public void setJournalArticlePersistence(
366                    JournalArticlePersistence journalArticlePersistence) {
367                    this.journalArticlePersistence = journalArticlePersistence;
368            }
369    
370            /**
371             * Returns the journal article finder.
372             *
373             * @return the journal article finder
374             */
375            public JournalArticleFinder getJournalArticleFinder() {
376                    return journalArticleFinder;
377            }
378    
379            /**
380             * Sets the journal article finder.
381             *
382             * @param journalArticleFinder the journal article finder
383             */
384            public void setJournalArticleFinder(
385                    JournalArticleFinder journalArticleFinder) {
386                    this.journalArticleFinder = journalArticleFinder;
387            }
388    
389            /**
390             * Returns the journal article image local service.
391             *
392             * @return the journal article image local service
393             */
394            public JournalArticleImageLocalService getJournalArticleImageLocalService() {
395                    return journalArticleImageLocalService;
396            }
397    
398            /**
399             * Sets the journal article image local service.
400             *
401             * @param journalArticleImageLocalService the journal article image local service
402             */
403            public void setJournalArticleImageLocalService(
404                    JournalArticleImageLocalService journalArticleImageLocalService) {
405                    this.journalArticleImageLocalService = journalArticleImageLocalService;
406            }
407    
408            /**
409             * Returns the journal article image persistence.
410             *
411             * @return the journal article image persistence
412             */
413            public JournalArticleImagePersistence getJournalArticleImagePersistence() {
414                    return journalArticleImagePersistence;
415            }
416    
417            /**
418             * Sets the journal article image persistence.
419             *
420             * @param journalArticleImagePersistence the journal article image persistence
421             */
422            public void setJournalArticleImagePersistence(
423                    JournalArticleImagePersistence journalArticleImagePersistence) {
424                    this.journalArticleImagePersistence = journalArticleImagePersistence;
425            }
426    
427            /**
428             * Returns the journal article resource local service.
429             *
430             * @return the journal article resource local service
431             */
432            public JournalArticleResourceLocalService getJournalArticleResourceLocalService() {
433                    return journalArticleResourceLocalService;
434            }
435    
436            /**
437             * Sets the journal article resource local service.
438             *
439             * @param journalArticleResourceLocalService the journal article resource local service
440             */
441            public void setJournalArticleResourceLocalService(
442                    JournalArticleResourceLocalService journalArticleResourceLocalService) {
443                    this.journalArticleResourceLocalService = journalArticleResourceLocalService;
444            }
445    
446            /**
447             * Returns the journal article resource persistence.
448             *
449             * @return the journal article resource persistence
450             */
451            public JournalArticleResourcePersistence getJournalArticleResourcePersistence() {
452                    return journalArticleResourcePersistence;
453            }
454    
455            /**
456             * Sets the journal article resource persistence.
457             *
458             * @param journalArticleResourcePersistence the journal article resource persistence
459             */
460            public void setJournalArticleResourcePersistence(
461                    JournalArticleResourcePersistence journalArticleResourcePersistence) {
462                    this.journalArticleResourcePersistence = journalArticleResourcePersistence;
463            }
464    
465            /**
466             * Returns the journal content search local service.
467             *
468             * @return the journal content search local service
469             */
470            public JournalContentSearchLocalService getJournalContentSearchLocalService() {
471                    return journalContentSearchLocalService;
472            }
473    
474            /**
475             * Sets the journal content search local service.
476             *
477             * @param journalContentSearchLocalService the journal content search local service
478             */
479            public void setJournalContentSearchLocalService(
480                    JournalContentSearchLocalService journalContentSearchLocalService) {
481                    this.journalContentSearchLocalService = journalContentSearchLocalService;
482            }
483    
484            /**
485             * Returns the journal content search persistence.
486             *
487             * @return the journal content search persistence
488             */
489            public JournalContentSearchPersistence getJournalContentSearchPersistence() {
490                    return journalContentSearchPersistence;
491            }
492    
493            /**
494             * Sets the journal content search persistence.
495             *
496             * @param journalContentSearchPersistence the journal content search persistence
497             */
498            public void setJournalContentSearchPersistence(
499                    JournalContentSearchPersistence journalContentSearchPersistence) {
500                    this.journalContentSearchPersistence = journalContentSearchPersistence;
501            }
502    
503            /**
504             * Returns the journal feed local service.
505             *
506             * @return the journal feed local service
507             */
508            public JournalFeedLocalService getJournalFeedLocalService() {
509                    return journalFeedLocalService;
510            }
511    
512            /**
513             * Sets the journal feed local service.
514             *
515             * @param journalFeedLocalService the journal feed local service
516             */
517            public void setJournalFeedLocalService(
518                    JournalFeedLocalService journalFeedLocalService) {
519                    this.journalFeedLocalService = journalFeedLocalService;
520            }
521    
522            /**
523             * Returns the journal feed remote service.
524             *
525             * @return the journal feed remote service
526             */
527            public JournalFeedService getJournalFeedService() {
528                    return journalFeedService;
529            }
530    
531            /**
532             * Sets the journal feed remote service.
533             *
534             * @param journalFeedService the journal feed remote service
535             */
536            public void setJournalFeedService(JournalFeedService journalFeedService) {
537                    this.journalFeedService = journalFeedService;
538            }
539    
540            /**
541             * Returns the journal feed persistence.
542             *
543             * @return the journal feed persistence
544             */
545            public JournalFeedPersistence getJournalFeedPersistence() {
546                    return journalFeedPersistence;
547            }
548    
549            /**
550             * Sets the journal feed persistence.
551             *
552             * @param journalFeedPersistence the journal feed persistence
553             */
554            public void setJournalFeedPersistence(
555                    JournalFeedPersistence journalFeedPersistence) {
556                    this.journalFeedPersistence = journalFeedPersistence;
557            }
558    
559            /**
560             * Returns the journal feed finder.
561             *
562             * @return the journal feed finder
563             */
564            public JournalFeedFinder getJournalFeedFinder() {
565                    return journalFeedFinder;
566            }
567    
568            /**
569             * Sets the journal feed finder.
570             *
571             * @param journalFeedFinder the journal feed finder
572             */
573            public void setJournalFeedFinder(JournalFeedFinder journalFeedFinder) {
574                    this.journalFeedFinder = journalFeedFinder;
575            }
576    
577            /**
578             * Returns the journal structure local service.
579             *
580             * @return the journal structure local service
581             */
582            public JournalStructureLocalService getJournalStructureLocalService() {
583                    return journalStructureLocalService;
584            }
585    
586            /**
587             * Sets the journal structure local service.
588             *
589             * @param journalStructureLocalService the journal structure local service
590             */
591            public void setJournalStructureLocalService(
592                    JournalStructureLocalService journalStructureLocalService) {
593                    this.journalStructureLocalService = journalStructureLocalService;
594            }
595    
596            /**
597             * Returns the journal structure remote service.
598             *
599             * @return the journal structure remote service
600             */
601            public JournalStructureService getJournalStructureService() {
602                    return journalStructureService;
603            }
604    
605            /**
606             * Sets the journal structure remote service.
607             *
608             * @param journalStructureService the journal structure remote service
609             */
610            public void setJournalStructureService(
611                    JournalStructureService journalStructureService) {
612                    this.journalStructureService = journalStructureService;
613            }
614    
615            /**
616             * Returns the journal structure persistence.
617             *
618             * @return the journal structure persistence
619             */
620            public JournalStructurePersistence getJournalStructurePersistence() {
621                    return journalStructurePersistence;
622            }
623    
624            /**
625             * Sets the journal structure persistence.
626             *
627             * @param journalStructurePersistence the journal structure persistence
628             */
629            public void setJournalStructurePersistence(
630                    JournalStructurePersistence journalStructurePersistence) {
631                    this.journalStructurePersistence = journalStructurePersistence;
632            }
633    
634            /**
635             * Returns the journal structure finder.
636             *
637             * @return the journal structure finder
638             */
639            public JournalStructureFinder getJournalStructureFinder() {
640                    return journalStructureFinder;
641            }
642    
643            /**
644             * Sets the journal structure finder.
645             *
646             * @param journalStructureFinder the journal structure finder
647             */
648            public void setJournalStructureFinder(
649                    JournalStructureFinder journalStructureFinder) {
650                    this.journalStructureFinder = journalStructureFinder;
651            }
652    
653            /**
654             * Returns the journal template local service.
655             *
656             * @return the journal template local service
657             */
658            public JournalTemplateLocalService getJournalTemplateLocalService() {
659                    return journalTemplateLocalService;
660            }
661    
662            /**
663             * Sets the journal template local service.
664             *
665             * @param journalTemplateLocalService the journal template local service
666             */
667            public void setJournalTemplateLocalService(
668                    JournalTemplateLocalService journalTemplateLocalService) {
669                    this.journalTemplateLocalService = journalTemplateLocalService;
670            }
671    
672            /**
673             * Returns the journal template remote service.
674             *
675             * @return the journal template remote service
676             */
677            public JournalTemplateService getJournalTemplateService() {
678                    return journalTemplateService;
679            }
680    
681            /**
682             * Sets the journal template remote service.
683             *
684             * @param journalTemplateService the journal template remote service
685             */
686            public void setJournalTemplateService(
687                    JournalTemplateService journalTemplateService) {
688                    this.journalTemplateService = journalTemplateService;
689            }
690    
691            /**
692             * Returns the journal template persistence.
693             *
694             * @return the journal template persistence
695             */
696            public JournalTemplatePersistence getJournalTemplatePersistence() {
697                    return journalTemplatePersistence;
698            }
699    
700            /**
701             * Sets the journal template persistence.
702             *
703             * @param journalTemplatePersistence the journal template persistence
704             */
705            public void setJournalTemplatePersistence(
706                    JournalTemplatePersistence journalTemplatePersistence) {
707                    this.journalTemplatePersistence = journalTemplatePersistence;
708            }
709    
710            /**
711             * Returns the journal template finder.
712             *
713             * @return the journal template finder
714             */
715            public JournalTemplateFinder getJournalTemplateFinder() {
716                    return journalTemplateFinder;
717            }
718    
719            /**
720             * Sets the journal template finder.
721             *
722             * @param journalTemplateFinder the journal template finder
723             */
724            public void setJournalTemplateFinder(
725                    JournalTemplateFinder journalTemplateFinder) {
726                    this.journalTemplateFinder = journalTemplateFinder;
727            }
728    
729            /**
730             * Returns the counter local service.
731             *
732             * @return the counter local service
733             */
734            public CounterLocalService getCounterLocalService() {
735                    return counterLocalService;
736            }
737    
738            /**
739             * Sets the counter local service.
740             *
741             * @param counterLocalService the counter local service
742             */
743            public void setCounterLocalService(CounterLocalService counterLocalService) {
744                    this.counterLocalService = counterLocalService;
745            }
746    
747            /**
748             * Returns the resource local service.
749             *
750             * @return the resource local service
751             */
752            public ResourceLocalService getResourceLocalService() {
753                    return resourceLocalService;
754            }
755    
756            /**
757             * Sets the resource local service.
758             *
759             * @param resourceLocalService the resource local service
760             */
761            public void setResourceLocalService(
762                    ResourceLocalService resourceLocalService) {
763                    this.resourceLocalService = resourceLocalService;
764            }
765    
766            /**
767             * Returns the resource remote service.
768             *
769             * @return the resource remote service
770             */
771            public ResourceService getResourceService() {
772                    return resourceService;
773            }
774    
775            /**
776             * Sets the resource remote service.
777             *
778             * @param resourceService the resource remote service
779             */
780            public void setResourceService(ResourceService resourceService) {
781                    this.resourceService = resourceService;
782            }
783    
784            /**
785             * Returns the resource persistence.
786             *
787             * @return the resource persistence
788             */
789            public ResourcePersistence getResourcePersistence() {
790                    return resourcePersistence;
791            }
792    
793            /**
794             * Sets the resource persistence.
795             *
796             * @param resourcePersistence the resource persistence
797             */
798            public void setResourcePersistence(ResourcePersistence resourcePersistence) {
799                    this.resourcePersistence = resourcePersistence;
800            }
801    
802            /**
803             * Returns the resource finder.
804             *
805             * @return the resource finder
806             */
807            public ResourceFinder getResourceFinder() {
808                    return resourceFinder;
809            }
810    
811            /**
812             * Sets the resource finder.
813             *
814             * @param resourceFinder the resource finder
815             */
816            public void setResourceFinder(ResourceFinder resourceFinder) {
817                    this.resourceFinder = resourceFinder;
818            }
819    
820            /**
821             * Returns the user local service.
822             *
823             * @return the user local service
824             */
825            public UserLocalService getUserLocalService() {
826                    return userLocalService;
827            }
828    
829            /**
830             * Sets the user local service.
831             *
832             * @param userLocalService the user local service
833             */
834            public void setUserLocalService(UserLocalService userLocalService) {
835                    this.userLocalService = userLocalService;
836            }
837    
838            /**
839             * Returns the user remote service.
840             *
841             * @return the user remote service
842             */
843            public UserService getUserService() {
844                    return userService;
845            }
846    
847            /**
848             * Sets the user remote service.
849             *
850             * @param userService the user remote service
851             */
852            public void setUserService(UserService userService) {
853                    this.userService = userService;
854            }
855    
856            /**
857             * Returns the user persistence.
858             *
859             * @return the user persistence
860             */
861            public UserPersistence getUserPersistence() {
862                    return userPersistence;
863            }
864    
865            /**
866             * Sets the user persistence.
867             *
868             * @param userPersistence the user persistence
869             */
870            public void setUserPersistence(UserPersistence userPersistence) {
871                    this.userPersistence = userPersistence;
872            }
873    
874            /**
875             * Returns the user finder.
876             *
877             * @return the user finder
878             */
879            public UserFinder getUserFinder() {
880                    return userFinder;
881            }
882    
883            /**
884             * Sets the user finder.
885             *
886             * @param userFinder the user finder
887             */
888            public void setUserFinder(UserFinder userFinder) {
889                    this.userFinder = userFinder;
890            }
891    
892            /**
893             * Returns the expando value local service.
894             *
895             * @return the expando value local service
896             */
897            public ExpandoValueLocalService getExpandoValueLocalService() {
898                    return expandoValueLocalService;
899            }
900    
901            /**
902             * Sets the expando value local service.
903             *
904             * @param expandoValueLocalService the expando value local service
905             */
906            public void setExpandoValueLocalService(
907                    ExpandoValueLocalService expandoValueLocalService) {
908                    this.expandoValueLocalService = expandoValueLocalService;
909            }
910    
911            /**
912             * Returns the expando value remote service.
913             *
914             * @return the expando value remote service
915             */
916            public ExpandoValueService getExpandoValueService() {
917                    return expandoValueService;
918            }
919    
920            /**
921             * Sets the expando value remote service.
922             *
923             * @param expandoValueService the expando value remote service
924             */
925            public void setExpandoValueService(ExpandoValueService expandoValueService) {
926                    this.expandoValueService = expandoValueService;
927            }
928    
929            /**
930             * Returns the expando value persistence.
931             *
932             * @return the expando value persistence
933             */
934            public ExpandoValuePersistence getExpandoValuePersistence() {
935                    return expandoValuePersistence;
936            }
937    
938            /**
939             * Sets the expando value persistence.
940             *
941             * @param expandoValuePersistence the expando value persistence
942             */
943            public void setExpandoValuePersistence(
944                    ExpandoValuePersistence expandoValuePersistence) {
945                    this.expandoValuePersistence = expandoValuePersistence;
946            }
947    
948            public void afterPropertiesSet() {
949                    persistedModelLocalServiceRegistry.register("com.liferay.portlet.journal.model.JournalFeed",
950                            journalFeedLocalService);
951            }
952    
953            public void destroy() {
954                    persistedModelLocalServiceRegistry.unregister(
955                            "com.liferay.portlet.journal.model.JournalFeed");
956            }
957    
958            /**
959             * Returns the Spring bean ID for this bean.
960             *
961             * @return the Spring bean ID for this bean
962             */
963            public String getBeanIdentifier() {
964                    return _beanIdentifier;
965            }
966    
967            /**
968             * Sets the Spring bean ID for this bean.
969             *
970             * @param beanIdentifier the Spring bean ID for this bean
971             */
972            public void setBeanIdentifier(String beanIdentifier) {
973                    _beanIdentifier = beanIdentifier;
974            }
975    
976            protected Class<?> getModelClass() {
977                    return JournalFeed.class;
978            }
979    
980            protected String getModelClassName() {
981                    return JournalFeed.class.getName();
982            }
983    
984            /**
985             * Performs an SQL query.
986             *
987             * @param sql the sql query
988             */
989            protected void runSQL(String sql) throws SystemException {
990                    try {
991                            DataSource dataSource = journalFeedPersistence.getDataSource();
992    
993                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
994                                            sql, new int[0]);
995    
996                            sqlUpdate.update();
997                    }
998                    catch (Exception e) {
999                            throw new SystemException(e);
1000                    }
1001            }
1002    
1003            @BeanReference(type = JournalArticleLocalService.class)
1004            protected JournalArticleLocalService journalArticleLocalService;
1005            @BeanReference(type = JournalArticleService.class)
1006            protected JournalArticleService journalArticleService;
1007            @BeanReference(type = JournalArticlePersistence.class)
1008            protected JournalArticlePersistence journalArticlePersistence;
1009            @BeanReference(type = JournalArticleFinder.class)
1010            protected JournalArticleFinder journalArticleFinder;
1011            @BeanReference(type = JournalArticleImageLocalService.class)
1012            protected JournalArticleImageLocalService journalArticleImageLocalService;
1013            @BeanReference(type = JournalArticleImagePersistence.class)
1014            protected JournalArticleImagePersistence journalArticleImagePersistence;
1015            @BeanReference(type = JournalArticleResourceLocalService.class)
1016            protected JournalArticleResourceLocalService journalArticleResourceLocalService;
1017            @BeanReference(type = JournalArticleResourcePersistence.class)
1018            protected JournalArticleResourcePersistence journalArticleResourcePersistence;
1019            @BeanReference(type = JournalContentSearchLocalService.class)
1020            protected JournalContentSearchLocalService journalContentSearchLocalService;
1021            @BeanReference(type = JournalContentSearchPersistence.class)
1022            protected JournalContentSearchPersistence journalContentSearchPersistence;
1023            @BeanReference(type = JournalFeedLocalService.class)
1024            protected JournalFeedLocalService journalFeedLocalService;
1025            @BeanReference(type = JournalFeedService.class)
1026            protected JournalFeedService journalFeedService;
1027            @BeanReference(type = JournalFeedPersistence.class)
1028            protected JournalFeedPersistence journalFeedPersistence;
1029            @BeanReference(type = JournalFeedFinder.class)
1030            protected JournalFeedFinder journalFeedFinder;
1031            @BeanReference(type = JournalStructureLocalService.class)
1032            protected JournalStructureLocalService journalStructureLocalService;
1033            @BeanReference(type = JournalStructureService.class)
1034            protected JournalStructureService journalStructureService;
1035            @BeanReference(type = JournalStructurePersistence.class)
1036            protected JournalStructurePersistence journalStructurePersistence;
1037            @BeanReference(type = JournalStructureFinder.class)
1038            protected JournalStructureFinder journalStructureFinder;
1039            @BeanReference(type = JournalTemplateLocalService.class)
1040            protected JournalTemplateLocalService journalTemplateLocalService;
1041            @BeanReference(type = JournalTemplateService.class)
1042            protected JournalTemplateService journalTemplateService;
1043            @BeanReference(type = JournalTemplatePersistence.class)
1044            protected JournalTemplatePersistence journalTemplatePersistence;
1045            @BeanReference(type = JournalTemplateFinder.class)
1046            protected JournalTemplateFinder journalTemplateFinder;
1047            @BeanReference(type = CounterLocalService.class)
1048            protected CounterLocalService counterLocalService;
1049            @BeanReference(type = ResourceLocalService.class)
1050            protected ResourceLocalService resourceLocalService;
1051            @BeanReference(type = ResourceService.class)
1052            protected ResourceService resourceService;
1053            @BeanReference(type = ResourcePersistence.class)
1054            protected ResourcePersistence resourcePersistence;
1055            @BeanReference(type = ResourceFinder.class)
1056            protected ResourceFinder resourceFinder;
1057            @BeanReference(type = UserLocalService.class)
1058            protected UserLocalService userLocalService;
1059            @BeanReference(type = UserService.class)
1060            protected UserService userService;
1061            @BeanReference(type = UserPersistence.class)
1062            protected UserPersistence userPersistence;
1063            @BeanReference(type = UserFinder.class)
1064            protected UserFinder userFinder;
1065            @BeanReference(type = ExpandoValueLocalService.class)
1066            protected ExpandoValueLocalService expandoValueLocalService;
1067            @BeanReference(type = ExpandoValueService.class)
1068            protected ExpandoValueService expandoValueService;
1069            @BeanReference(type = ExpandoValuePersistence.class)
1070            protected ExpandoValuePersistence expandoValuePersistence;
1071            @BeanReference(type = PersistedModelLocalServiceRegistry.class)
1072            protected PersistedModelLocalServiceRegistry persistedModelLocalServiceRegistry;
1073            private String _beanIdentifier;
1074    }