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.wiki.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.exception.PortalException;
025    import com.liferay.portal.kernel.exception.SystemException;
026    import com.liferay.portal.kernel.log.Log;
027    import com.liferay.portal.kernel.log.LogFactoryUtil;
028    import com.liferay.portal.kernel.search.Indexer;
029    import com.liferay.portal.kernel.search.IndexerRegistryUtil;
030    import com.liferay.portal.kernel.search.SearchException;
031    import com.liferay.portal.kernel.util.OrderByComparator;
032    import com.liferay.portal.model.PersistedModel;
033    import com.liferay.portal.service.GroupLocalService;
034    import com.liferay.portal.service.GroupService;
035    import com.liferay.portal.service.PersistedModelLocalServiceRegistry;
036    import com.liferay.portal.service.ResourceLocalService;
037    import com.liferay.portal.service.ResourceService;
038    import com.liferay.portal.service.SubscriptionLocalService;
039    import com.liferay.portal.service.UserLocalService;
040    import com.liferay.portal.service.UserService;
041    import com.liferay.portal.service.persistence.GroupFinder;
042    import com.liferay.portal.service.persistence.GroupPersistence;
043    import com.liferay.portal.service.persistence.ResourceFinder;
044    import com.liferay.portal.service.persistence.ResourcePersistence;
045    import com.liferay.portal.service.persistence.SubscriptionPersistence;
046    import com.liferay.portal.service.persistence.UserFinder;
047    import com.liferay.portal.service.persistence.UserPersistence;
048    
049    import com.liferay.portlet.wiki.model.WikiNode;
050    import com.liferay.portlet.wiki.service.WikiNodeLocalService;
051    import com.liferay.portlet.wiki.service.WikiNodeService;
052    import com.liferay.portlet.wiki.service.WikiPageLocalService;
053    import com.liferay.portlet.wiki.service.WikiPageResourceLocalService;
054    import com.liferay.portlet.wiki.service.WikiPageService;
055    import com.liferay.portlet.wiki.service.persistence.WikiNodePersistence;
056    import com.liferay.portlet.wiki.service.persistence.WikiPageFinder;
057    import com.liferay.portlet.wiki.service.persistence.WikiPagePersistence;
058    import com.liferay.portlet.wiki.service.persistence.WikiPageResourcePersistence;
059    
060    import java.io.Serializable;
061    
062    import java.util.List;
063    
064    import javax.sql.DataSource;
065    
066    /**
067     * The base implementation of the wiki node local service.
068     *
069     * <p>
070     * 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}.
071     * </p>
072     *
073     * @author Brian Wing Shun Chan
074     * @see com.liferay.portlet.wiki.service.impl.WikiNodeLocalServiceImpl
075     * @see com.liferay.portlet.wiki.service.WikiNodeLocalServiceUtil
076     * @generated
077     */
078    public abstract class WikiNodeLocalServiceBaseImpl
079            implements WikiNodeLocalService, IdentifiableBean {
080            /*
081             * NOTE FOR DEVELOPERS:
082             *
083             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.wiki.service.WikiNodeLocalServiceUtil} to access the wiki node local service.
084             */
085    
086            /**
087             * Adds the wiki node to the database. Also notifies the appropriate model listeners.
088             *
089             * @param wikiNode the wiki node
090             * @return the wiki node that was added
091             * @throws SystemException if a system exception occurred
092             */
093            public WikiNode addWikiNode(WikiNode wikiNode) throws SystemException {
094                    wikiNode.setNew(true);
095    
096                    wikiNode = wikiNodePersistence.update(wikiNode, false);
097    
098                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
099    
100                    if (indexer != null) {
101                            try {
102                                    indexer.reindex(wikiNode);
103                            }
104                            catch (SearchException se) {
105                                    if (_log.isWarnEnabled()) {
106                                            _log.warn(se, se);
107                                    }
108                            }
109                    }
110    
111                    return wikiNode;
112            }
113    
114            /**
115             * Creates a new wiki node with the primary key. Does not add the wiki node to the database.
116             *
117             * @param nodeId the primary key for the new wiki node
118             * @return the new wiki node
119             */
120            public WikiNode createWikiNode(long nodeId) {
121                    return wikiNodePersistence.create(nodeId);
122            }
123    
124            /**
125             * Deletes the wiki node with the primary key from the database. Also notifies the appropriate model listeners.
126             *
127             * @param nodeId the primary key of the wiki node
128             * @throws PortalException if a wiki node with the primary key could not be found
129             * @throws SystemException if a system exception occurred
130             */
131            public void deleteWikiNode(long nodeId)
132                    throws PortalException, SystemException {
133                    WikiNode wikiNode = wikiNodePersistence.remove(nodeId);
134    
135                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
136    
137                    if (indexer != null) {
138                            try {
139                                    indexer.delete(wikiNode);
140                            }
141                            catch (SearchException se) {
142                                    if (_log.isWarnEnabled()) {
143                                            _log.warn(se, se);
144                                    }
145                            }
146                    }
147            }
148    
149            /**
150             * Deletes the wiki node from the database. Also notifies the appropriate model listeners.
151             *
152             * @param wikiNode the wiki node
153             * @throws SystemException if a system exception occurred
154             */
155            public void deleteWikiNode(WikiNode wikiNode) throws SystemException {
156                    wikiNodePersistence.remove(wikiNode);
157    
158                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
159    
160                    if (indexer != null) {
161                            try {
162                                    indexer.delete(wikiNode);
163                            }
164                            catch (SearchException se) {
165                                    if (_log.isWarnEnabled()) {
166                                            _log.warn(se, se);
167                                    }
168                            }
169                    }
170            }
171    
172            /**
173             * Performs a dynamic query on the database and returns the matching rows.
174             *
175             * @param dynamicQuery the dynamic query
176             * @return the matching rows
177             * @throws SystemException if a system exception occurred
178             */
179            @SuppressWarnings("rawtypes")
180            public List dynamicQuery(DynamicQuery dynamicQuery)
181                    throws SystemException {
182                    return wikiNodePersistence.findWithDynamicQuery(dynamicQuery);
183            }
184    
185            /**
186             * Performs a dynamic query on the database and returns a range of the matching rows.
187             *
188             * <p>
189             * 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.
190             * </p>
191             *
192             * @param dynamicQuery the dynamic query
193             * @param start the lower bound of the range of model instances
194             * @param end the upper bound of the range of model instances (not inclusive)
195             * @return the range of matching rows
196             * @throws SystemException if a system exception occurred
197             */
198            @SuppressWarnings("rawtypes")
199            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
200                    throws SystemException {
201                    return wikiNodePersistence.findWithDynamicQuery(dynamicQuery, start, end);
202            }
203    
204            /**
205             * Performs a dynamic query on the database and returns an ordered range of the matching rows.
206             *
207             * <p>
208             * 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.
209             * </p>
210             *
211             * @param dynamicQuery the dynamic query
212             * @param start the lower bound of the range of model instances
213             * @param end the upper bound of the range of model instances (not inclusive)
214             * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
215             * @return the ordered range of matching rows
216             * @throws SystemException if a system exception occurred
217             */
218            @SuppressWarnings("rawtypes")
219            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end,
220                    OrderByComparator orderByComparator) throws SystemException {
221                    return wikiNodePersistence.findWithDynamicQuery(dynamicQuery, start,
222                            end, orderByComparator);
223            }
224    
225            /**
226             * Returns the number of rows that match the dynamic query.
227             *
228             * @param dynamicQuery the dynamic query
229             * @return the number of rows that match the dynamic query
230             * @throws SystemException if a system exception occurred
231             */
232            public long dynamicQueryCount(DynamicQuery dynamicQuery)
233                    throws SystemException {
234                    return wikiNodePersistence.countWithDynamicQuery(dynamicQuery);
235            }
236    
237            public WikiNode fetchWikiNode(long nodeId) throws SystemException {
238                    return wikiNodePersistence.fetchByPrimaryKey(nodeId);
239            }
240    
241            /**
242             * Returns the wiki node with the primary key.
243             *
244             * @param nodeId the primary key of the wiki node
245             * @return the wiki node
246             * @throws PortalException if a wiki node with the primary key could not be found
247             * @throws SystemException if a system exception occurred
248             */
249            public WikiNode getWikiNode(long nodeId)
250                    throws PortalException, SystemException {
251                    return wikiNodePersistence.findByPrimaryKey(nodeId);
252            }
253    
254            public PersistedModel getPersistedModel(Serializable primaryKeyObj)
255                    throws PortalException, SystemException {
256                    return wikiNodePersistence.findByPrimaryKey(primaryKeyObj);
257            }
258    
259            /**
260             * Returns the wiki node with the UUID in the group.
261             *
262             * @param uuid the UUID of wiki node
263             * @param groupId the group id of the wiki node
264             * @return the wiki node
265             * @throws PortalException if a wiki node with the UUID in the group could not be found
266             * @throws SystemException if a system exception occurred
267             */
268            public WikiNode getWikiNodeByUuidAndGroupId(String uuid, long groupId)
269                    throws PortalException, SystemException {
270                    return wikiNodePersistence.findByUUID_G(uuid, groupId);
271            }
272    
273            /**
274             * Returns a range of all the wiki nodes.
275             *
276             * <p>
277             * 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.
278             * </p>
279             *
280             * @param start the lower bound of the range of wiki nodes
281             * @param end the upper bound of the range of wiki nodes (not inclusive)
282             * @return the range of wiki nodes
283             * @throws SystemException if a system exception occurred
284             */
285            public List<WikiNode> getWikiNodes(int start, int end)
286                    throws SystemException {
287                    return wikiNodePersistence.findAll(start, end);
288            }
289    
290            /**
291             * Returns the number of wiki nodes.
292             *
293             * @return the number of wiki nodes
294             * @throws SystemException if a system exception occurred
295             */
296            public int getWikiNodesCount() throws SystemException {
297                    return wikiNodePersistence.countAll();
298            }
299    
300            /**
301             * Updates the wiki node in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
302             *
303             * @param wikiNode the wiki node
304             * @return the wiki node that was updated
305             * @throws SystemException if a system exception occurred
306             */
307            public WikiNode updateWikiNode(WikiNode wikiNode) throws SystemException {
308                    return updateWikiNode(wikiNode, true);
309            }
310    
311            /**
312             * Updates the wiki node in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
313             *
314             * @param wikiNode the wiki node
315             * @param merge whether to merge the wiki node with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
316             * @return the wiki node that was updated
317             * @throws SystemException if a system exception occurred
318             */
319            public WikiNode updateWikiNode(WikiNode wikiNode, boolean merge)
320                    throws SystemException {
321                    wikiNode.setNew(false);
322    
323                    wikiNode = wikiNodePersistence.update(wikiNode, merge);
324    
325                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
326    
327                    if (indexer != null) {
328                            try {
329                                    indexer.reindex(wikiNode);
330                            }
331                            catch (SearchException se) {
332                                    if (_log.isWarnEnabled()) {
333                                            _log.warn(se, se);
334                                    }
335                            }
336                    }
337    
338                    return wikiNode;
339            }
340    
341            /**
342             * Returns the wiki node local service.
343             *
344             * @return the wiki node local service
345             */
346            public WikiNodeLocalService getWikiNodeLocalService() {
347                    return wikiNodeLocalService;
348            }
349    
350            /**
351             * Sets the wiki node local service.
352             *
353             * @param wikiNodeLocalService the wiki node local service
354             */
355            public void setWikiNodeLocalService(
356                    WikiNodeLocalService wikiNodeLocalService) {
357                    this.wikiNodeLocalService = wikiNodeLocalService;
358            }
359    
360            /**
361             * Returns the wiki node remote service.
362             *
363             * @return the wiki node remote service
364             */
365            public WikiNodeService getWikiNodeService() {
366                    return wikiNodeService;
367            }
368    
369            /**
370             * Sets the wiki node remote service.
371             *
372             * @param wikiNodeService the wiki node remote service
373             */
374            public void setWikiNodeService(WikiNodeService wikiNodeService) {
375                    this.wikiNodeService = wikiNodeService;
376            }
377    
378            /**
379             * Returns the wiki node persistence.
380             *
381             * @return the wiki node persistence
382             */
383            public WikiNodePersistence getWikiNodePersistence() {
384                    return wikiNodePersistence;
385            }
386    
387            /**
388             * Sets the wiki node persistence.
389             *
390             * @param wikiNodePersistence the wiki node persistence
391             */
392            public void setWikiNodePersistence(WikiNodePersistence wikiNodePersistence) {
393                    this.wikiNodePersistence = wikiNodePersistence;
394            }
395    
396            /**
397             * Returns the wiki page local service.
398             *
399             * @return the wiki page local service
400             */
401            public WikiPageLocalService getWikiPageLocalService() {
402                    return wikiPageLocalService;
403            }
404    
405            /**
406             * Sets the wiki page local service.
407             *
408             * @param wikiPageLocalService the wiki page local service
409             */
410            public void setWikiPageLocalService(
411                    WikiPageLocalService wikiPageLocalService) {
412                    this.wikiPageLocalService = wikiPageLocalService;
413            }
414    
415            /**
416             * Returns the wiki page remote service.
417             *
418             * @return the wiki page remote service
419             */
420            public WikiPageService getWikiPageService() {
421                    return wikiPageService;
422            }
423    
424            /**
425             * Sets the wiki page remote service.
426             *
427             * @param wikiPageService the wiki page remote service
428             */
429            public void setWikiPageService(WikiPageService wikiPageService) {
430                    this.wikiPageService = wikiPageService;
431            }
432    
433            /**
434             * Returns the wiki page persistence.
435             *
436             * @return the wiki page persistence
437             */
438            public WikiPagePersistence getWikiPagePersistence() {
439                    return wikiPagePersistence;
440            }
441    
442            /**
443             * Sets the wiki page persistence.
444             *
445             * @param wikiPagePersistence the wiki page persistence
446             */
447            public void setWikiPagePersistence(WikiPagePersistence wikiPagePersistence) {
448                    this.wikiPagePersistence = wikiPagePersistence;
449            }
450    
451            /**
452             * Returns the wiki page finder.
453             *
454             * @return the wiki page finder
455             */
456            public WikiPageFinder getWikiPageFinder() {
457                    return wikiPageFinder;
458            }
459    
460            /**
461             * Sets the wiki page finder.
462             *
463             * @param wikiPageFinder the wiki page finder
464             */
465            public void setWikiPageFinder(WikiPageFinder wikiPageFinder) {
466                    this.wikiPageFinder = wikiPageFinder;
467            }
468    
469            /**
470             * Returns the wiki page resource local service.
471             *
472             * @return the wiki page resource local service
473             */
474            public WikiPageResourceLocalService getWikiPageResourceLocalService() {
475                    return wikiPageResourceLocalService;
476            }
477    
478            /**
479             * Sets the wiki page resource local service.
480             *
481             * @param wikiPageResourceLocalService the wiki page resource local service
482             */
483            public void setWikiPageResourceLocalService(
484                    WikiPageResourceLocalService wikiPageResourceLocalService) {
485                    this.wikiPageResourceLocalService = wikiPageResourceLocalService;
486            }
487    
488            /**
489             * Returns the wiki page resource persistence.
490             *
491             * @return the wiki page resource persistence
492             */
493            public WikiPageResourcePersistence getWikiPageResourcePersistence() {
494                    return wikiPageResourcePersistence;
495            }
496    
497            /**
498             * Sets the wiki page resource persistence.
499             *
500             * @param wikiPageResourcePersistence the wiki page resource persistence
501             */
502            public void setWikiPageResourcePersistence(
503                    WikiPageResourcePersistence wikiPageResourcePersistence) {
504                    this.wikiPageResourcePersistence = wikiPageResourcePersistence;
505            }
506    
507            /**
508             * Returns the counter local service.
509             *
510             * @return the counter local service
511             */
512            public CounterLocalService getCounterLocalService() {
513                    return counterLocalService;
514            }
515    
516            /**
517             * Sets the counter local service.
518             *
519             * @param counterLocalService the counter local service
520             */
521            public void setCounterLocalService(CounterLocalService counterLocalService) {
522                    this.counterLocalService = counterLocalService;
523            }
524    
525            /**
526             * Returns the group local service.
527             *
528             * @return the group local service
529             */
530            public GroupLocalService getGroupLocalService() {
531                    return groupLocalService;
532            }
533    
534            /**
535             * Sets the group local service.
536             *
537             * @param groupLocalService the group local service
538             */
539            public void setGroupLocalService(GroupLocalService groupLocalService) {
540                    this.groupLocalService = groupLocalService;
541            }
542    
543            /**
544             * Returns the group remote service.
545             *
546             * @return the group remote service
547             */
548            public GroupService getGroupService() {
549                    return groupService;
550            }
551    
552            /**
553             * Sets the group remote service.
554             *
555             * @param groupService the group remote service
556             */
557            public void setGroupService(GroupService groupService) {
558                    this.groupService = groupService;
559            }
560    
561            /**
562             * Returns the group persistence.
563             *
564             * @return the group persistence
565             */
566            public GroupPersistence getGroupPersistence() {
567                    return groupPersistence;
568            }
569    
570            /**
571             * Sets the group persistence.
572             *
573             * @param groupPersistence the group persistence
574             */
575            public void setGroupPersistence(GroupPersistence groupPersistence) {
576                    this.groupPersistence = groupPersistence;
577            }
578    
579            /**
580             * Returns the group finder.
581             *
582             * @return the group finder
583             */
584            public GroupFinder getGroupFinder() {
585                    return groupFinder;
586            }
587    
588            /**
589             * Sets the group finder.
590             *
591             * @param groupFinder the group finder
592             */
593            public void setGroupFinder(GroupFinder groupFinder) {
594                    this.groupFinder = groupFinder;
595            }
596    
597            /**
598             * Returns the resource local service.
599             *
600             * @return the resource local service
601             */
602            public ResourceLocalService getResourceLocalService() {
603                    return resourceLocalService;
604            }
605    
606            /**
607             * Sets the resource local service.
608             *
609             * @param resourceLocalService the resource local service
610             */
611            public void setResourceLocalService(
612                    ResourceLocalService resourceLocalService) {
613                    this.resourceLocalService = resourceLocalService;
614            }
615    
616            /**
617             * Returns the resource remote service.
618             *
619             * @return the resource remote service
620             */
621            public ResourceService getResourceService() {
622                    return resourceService;
623            }
624    
625            /**
626             * Sets the resource remote service.
627             *
628             * @param resourceService the resource remote service
629             */
630            public void setResourceService(ResourceService resourceService) {
631                    this.resourceService = resourceService;
632            }
633    
634            /**
635             * Returns the resource persistence.
636             *
637             * @return the resource persistence
638             */
639            public ResourcePersistence getResourcePersistence() {
640                    return resourcePersistence;
641            }
642    
643            /**
644             * Sets the resource persistence.
645             *
646             * @param resourcePersistence the resource persistence
647             */
648            public void setResourcePersistence(ResourcePersistence resourcePersistence) {
649                    this.resourcePersistence = resourcePersistence;
650            }
651    
652            /**
653             * Returns the resource finder.
654             *
655             * @return the resource finder
656             */
657            public ResourceFinder getResourceFinder() {
658                    return resourceFinder;
659            }
660    
661            /**
662             * Sets the resource finder.
663             *
664             * @param resourceFinder the resource finder
665             */
666            public void setResourceFinder(ResourceFinder resourceFinder) {
667                    this.resourceFinder = resourceFinder;
668            }
669    
670            /**
671             * Returns the subscription local service.
672             *
673             * @return the subscription local service
674             */
675            public SubscriptionLocalService getSubscriptionLocalService() {
676                    return subscriptionLocalService;
677            }
678    
679            /**
680             * Sets the subscription local service.
681             *
682             * @param subscriptionLocalService the subscription local service
683             */
684            public void setSubscriptionLocalService(
685                    SubscriptionLocalService subscriptionLocalService) {
686                    this.subscriptionLocalService = subscriptionLocalService;
687            }
688    
689            /**
690             * Returns the subscription persistence.
691             *
692             * @return the subscription persistence
693             */
694            public SubscriptionPersistence getSubscriptionPersistence() {
695                    return subscriptionPersistence;
696            }
697    
698            /**
699             * Sets the subscription persistence.
700             *
701             * @param subscriptionPersistence the subscription persistence
702             */
703            public void setSubscriptionPersistence(
704                    SubscriptionPersistence subscriptionPersistence) {
705                    this.subscriptionPersistence = subscriptionPersistence;
706            }
707    
708            /**
709             * Returns the user local service.
710             *
711             * @return the user local service
712             */
713            public UserLocalService getUserLocalService() {
714                    return userLocalService;
715            }
716    
717            /**
718             * Sets the user local service.
719             *
720             * @param userLocalService the user local service
721             */
722            public void setUserLocalService(UserLocalService userLocalService) {
723                    this.userLocalService = userLocalService;
724            }
725    
726            /**
727             * Returns the user remote service.
728             *
729             * @return the user remote service
730             */
731            public UserService getUserService() {
732                    return userService;
733            }
734    
735            /**
736             * Sets the user remote service.
737             *
738             * @param userService the user remote service
739             */
740            public void setUserService(UserService userService) {
741                    this.userService = userService;
742            }
743    
744            /**
745             * Returns the user persistence.
746             *
747             * @return the user persistence
748             */
749            public UserPersistence getUserPersistence() {
750                    return userPersistence;
751            }
752    
753            /**
754             * Sets the user persistence.
755             *
756             * @param userPersistence the user persistence
757             */
758            public void setUserPersistence(UserPersistence userPersistence) {
759                    this.userPersistence = userPersistence;
760            }
761    
762            /**
763             * Returns the user finder.
764             *
765             * @return the user finder
766             */
767            public UserFinder getUserFinder() {
768                    return userFinder;
769            }
770    
771            /**
772             * Sets the user finder.
773             *
774             * @param userFinder the user finder
775             */
776            public void setUserFinder(UserFinder userFinder) {
777                    this.userFinder = userFinder;
778            }
779    
780            public void afterPropertiesSet() {
781                    persistedModelLocalServiceRegistry.register("com.liferay.portlet.wiki.model.WikiNode",
782                            wikiNodeLocalService);
783            }
784    
785            public void destroy() {
786                    persistedModelLocalServiceRegistry.unregister(
787                            "com.liferay.portlet.wiki.model.WikiNode");
788            }
789    
790            /**
791             * Returns the Spring bean ID for this bean.
792             *
793             * @return the Spring bean ID for this bean
794             */
795            public String getBeanIdentifier() {
796                    return _beanIdentifier;
797            }
798    
799            /**
800             * Sets the Spring bean ID for this bean.
801             *
802             * @param beanIdentifier the Spring bean ID for this bean
803             */
804            public void setBeanIdentifier(String beanIdentifier) {
805                    _beanIdentifier = beanIdentifier;
806            }
807    
808            protected ClassLoader getClassLoader() {
809                    Class<?> clazz = getClass();
810    
811                    return clazz.getClassLoader();
812            }
813    
814            protected Class<?> getModelClass() {
815                    return WikiNode.class;
816            }
817    
818            protected String getModelClassName() {
819                    return WikiNode.class.getName();
820            }
821    
822            /**
823             * Performs an SQL query.
824             *
825             * @param sql the sql query
826             */
827            protected void runSQL(String sql) throws SystemException {
828                    try {
829                            DataSource dataSource = wikiNodePersistence.getDataSource();
830    
831                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
832                                            sql, new int[0]);
833    
834                            sqlUpdate.update();
835                    }
836                    catch (Exception e) {
837                            throw new SystemException(e);
838                    }
839            }
840    
841            @BeanReference(type = WikiNodeLocalService.class)
842            protected WikiNodeLocalService wikiNodeLocalService;
843            @BeanReference(type = WikiNodeService.class)
844            protected WikiNodeService wikiNodeService;
845            @BeanReference(type = WikiNodePersistence.class)
846            protected WikiNodePersistence wikiNodePersistence;
847            @BeanReference(type = WikiPageLocalService.class)
848            protected WikiPageLocalService wikiPageLocalService;
849            @BeanReference(type = WikiPageService.class)
850            protected WikiPageService wikiPageService;
851            @BeanReference(type = WikiPagePersistence.class)
852            protected WikiPagePersistence wikiPagePersistence;
853            @BeanReference(type = WikiPageFinder.class)
854            protected WikiPageFinder wikiPageFinder;
855            @BeanReference(type = WikiPageResourceLocalService.class)
856            protected WikiPageResourceLocalService wikiPageResourceLocalService;
857            @BeanReference(type = WikiPageResourcePersistence.class)
858            protected WikiPageResourcePersistence wikiPageResourcePersistence;
859            @BeanReference(type = CounterLocalService.class)
860            protected CounterLocalService counterLocalService;
861            @BeanReference(type = GroupLocalService.class)
862            protected GroupLocalService groupLocalService;
863            @BeanReference(type = GroupService.class)
864            protected GroupService groupService;
865            @BeanReference(type = GroupPersistence.class)
866            protected GroupPersistence groupPersistence;
867            @BeanReference(type = GroupFinder.class)
868            protected GroupFinder groupFinder;
869            @BeanReference(type = ResourceLocalService.class)
870            protected ResourceLocalService resourceLocalService;
871            @BeanReference(type = ResourceService.class)
872            protected ResourceService resourceService;
873            @BeanReference(type = ResourcePersistence.class)
874            protected ResourcePersistence resourcePersistence;
875            @BeanReference(type = ResourceFinder.class)
876            protected ResourceFinder resourceFinder;
877            @BeanReference(type = SubscriptionLocalService.class)
878            protected SubscriptionLocalService subscriptionLocalService;
879            @BeanReference(type = SubscriptionPersistence.class)
880            protected SubscriptionPersistence subscriptionPersistence;
881            @BeanReference(type = UserLocalService.class)
882            protected UserLocalService userLocalService;
883            @BeanReference(type = UserService.class)
884            protected UserService userService;
885            @BeanReference(type = UserPersistence.class)
886            protected UserPersistence userPersistence;
887            @BeanReference(type = UserFinder.class)
888            protected UserFinder userFinder;
889            @BeanReference(type = PersistedModelLocalServiceRegistry.class)
890            protected PersistedModelLocalServiceRegistry persistedModelLocalServiceRegistry;
891            private static Log _log = LogFactoryUtil.getLog(WikiNodeLocalServiceBaseImpl.class);
892            private String _beanIdentifier;
893    }