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