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