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