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