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