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.asset.service.base;
016    
017    import com.liferay.counter.service.CounterLocalService;
018    
019    import com.liferay.portal.kernel.bean.BeanReference;
020    import com.liferay.portal.kernel.bean.IdentifiableBean;
021    import com.liferay.portal.kernel.dao.jdbc.SqlUpdate;
022    import com.liferay.portal.kernel.dao.jdbc.SqlUpdateFactoryUtil;
023    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
024    import com.liferay.portal.kernel.exception.PortalException;
025    import com.liferay.portal.kernel.exception.SystemException;
026    import com.liferay.portal.kernel.log.Log;
027    import com.liferay.portal.kernel.log.LogFactoryUtil;
028    import com.liferay.portal.kernel.search.Indexer;
029    import com.liferay.portal.kernel.search.IndexerRegistryUtil;
030    import com.liferay.portal.kernel.search.SearchException;
031    import com.liferay.portal.kernel.util.OrderByComparator;
032    import com.liferay.portal.model.PersistedModel;
033    import com.liferay.portal.service.PersistedModelLocalServiceRegistry;
034    import com.liferay.portal.service.ResourceLocalService;
035    import com.liferay.portal.service.ResourceService;
036    import com.liferay.portal.service.UserLocalService;
037    import com.liferay.portal.service.UserService;
038    import com.liferay.portal.service.persistence.ResourceFinder;
039    import com.liferay.portal.service.persistence.ResourcePersistence;
040    import com.liferay.portal.service.persistence.UserFinder;
041    import com.liferay.portal.service.persistence.UserPersistence;
042    
043    import com.liferay.portlet.asset.model.AssetLink;
044    import com.liferay.portlet.asset.service.AssetCategoryLocalService;
045    import com.liferay.portlet.asset.service.AssetCategoryPropertyLocalService;
046    import com.liferay.portlet.asset.service.AssetCategoryPropertyService;
047    import com.liferay.portlet.asset.service.AssetCategoryService;
048    import com.liferay.portlet.asset.service.AssetEntryLocalService;
049    import com.liferay.portlet.asset.service.AssetEntryService;
050    import com.liferay.portlet.asset.service.AssetLinkLocalService;
051    import com.liferay.portlet.asset.service.AssetTagLocalService;
052    import com.liferay.portlet.asset.service.AssetTagPropertyLocalService;
053    import com.liferay.portlet.asset.service.AssetTagPropertyService;
054    import com.liferay.portlet.asset.service.AssetTagService;
055    import com.liferay.portlet.asset.service.AssetTagStatsLocalService;
056    import com.liferay.portlet.asset.service.AssetVocabularyLocalService;
057    import com.liferay.portlet.asset.service.AssetVocabularyService;
058    import com.liferay.portlet.asset.service.persistence.AssetCategoryFinder;
059    import com.liferay.portlet.asset.service.persistence.AssetCategoryPersistence;
060    import com.liferay.portlet.asset.service.persistence.AssetCategoryPropertyFinder;
061    import com.liferay.portlet.asset.service.persistence.AssetCategoryPropertyPersistence;
062    import com.liferay.portlet.asset.service.persistence.AssetEntryFinder;
063    import com.liferay.portlet.asset.service.persistence.AssetEntryPersistence;
064    import com.liferay.portlet.asset.service.persistence.AssetLinkPersistence;
065    import com.liferay.portlet.asset.service.persistence.AssetTagFinder;
066    import com.liferay.portlet.asset.service.persistence.AssetTagPersistence;
067    import com.liferay.portlet.asset.service.persistence.AssetTagPropertyFinder;
068    import com.liferay.portlet.asset.service.persistence.AssetTagPropertyKeyFinder;
069    import com.liferay.portlet.asset.service.persistence.AssetTagPropertyPersistence;
070    import com.liferay.portlet.asset.service.persistence.AssetTagStatsPersistence;
071    import com.liferay.portlet.asset.service.persistence.AssetVocabularyFinder;
072    import com.liferay.portlet.asset.service.persistence.AssetVocabularyPersistence;
073    
074    import java.io.Serializable;
075    
076    import java.util.List;
077    
078    import javax.sql.DataSource;
079    
080    /**
081     * The base implementation of the asset link local service.
082     *
083     * <p>
084     * 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.asset.service.impl.AssetLinkLocalServiceImpl}.
085     * </p>
086     *
087     * @author Brian Wing Shun Chan
088     * @see com.liferay.portlet.asset.service.impl.AssetLinkLocalServiceImpl
089     * @see com.liferay.portlet.asset.service.AssetLinkLocalServiceUtil
090     * @generated
091     */
092    public abstract class AssetLinkLocalServiceBaseImpl
093            implements AssetLinkLocalService, IdentifiableBean {
094            /*
095             * NOTE FOR DEVELOPERS:
096             *
097             * Never modify or reference this class directly. Always use {@link com.liferay.portlet.asset.service.AssetLinkLocalServiceUtil} to access the asset link local service.
098             */
099    
100            /**
101             * Adds the asset link to the database. Also notifies the appropriate model listeners.
102             *
103             * @param assetLink the asset link
104             * @return the asset link that was added
105             * @throws SystemException if a system exception occurred
106             */
107            public AssetLink addAssetLink(AssetLink assetLink)
108                    throws SystemException {
109                    assetLink.setNew(true);
110    
111                    assetLink = assetLinkPersistence.update(assetLink, false);
112    
113                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
114    
115                    if (indexer != null) {
116                            try {
117                                    indexer.reindex(assetLink);
118                            }
119                            catch (SearchException se) {
120                                    if (_log.isWarnEnabled()) {
121                                            _log.warn(se, se);
122                                    }
123                            }
124                    }
125    
126                    return assetLink;
127            }
128    
129            /**
130             * Creates a new asset link with the primary key. Does not add the asset link to the database.
131             *
132             * @param linkId the primary key for the new asset link
133             * @return the new asset link
134             */
135            public AssetLink createAssetLink(long linkId) {
136                    return assetLinkPersistence.create(linkId);
137            }
138    
139            /**
140             * Deletes the asset link with the primary key from the database. Also notifies the appropriate model listeners.
141             *
142             * @param linkId the primary key of the asset link
143             * @throws PortalException if a asset link with the primary key could not be found
144             * @throws SystemException if a system exception occurred
145             */
146            public void deleteAssetLink(long linkId)
147                    throws PortalException, SystemException {
148                    AssetLink assetLink = assetLinkPersistence.remove(linkId);
149    
150                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
151    
152                    if (indexer != null) {
153                            try {
154                                    indexer.delete(assetLink);
155                            }
156                            catch (SearchException se) {
157                                    if (_log.isWarnEnabled()) {
158                                            _log.warn(se, se);
159                                    }
160                            }
161                    }
162            }
163    
164            /**
165             * Deletes the asset link from the database. Also notifies the appropriate model listeners.
166             *
167             * @param assetLink the asset link
168             * @throws SystemException if a system exception occurred
169             */
170            public void deleteAssetLink(AssetLink assetLink) throws SystemException {
171                    assetLinkPersistence.remove(assetLink);
172    
173                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
174    
175                    if (indexer != null) {
176                            try {
177                                    indexer.delete(assetLink);
178                            }
179                            catch (SearchException se) {
180                                    if (_log.isWarnEnabled()) {
181                                            _log.warn(se, se);
182                                    }
183                            }
184                    }
185            }
186    
187            /**
188             * Performs a dynamic query on the database and returns the matching rows.
189             *
190             * @param dynamicQuery the dynamic query
191             * @return the matching rows
192             * @throws SystemException if a system exception occurred
193             */
194            @SuppressWarnings("rawtypes")
195            public List dynamicQuery(DynamicQuery dynamicQuery)
196                    throws SystemException {
197                    return assetLinkPersistence.findWithDynamicQuery(dynamicQuery);
198            }
199    
200            /**
201             * Performs a dynamic query on the database and returns a range of the matching rows.
202             *
203             * <p>
204             * 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.
205             * </p>
206             *
207             * @param dynamicQuery the dynamic query
208             * @param start the lower bound of the range of model instances
209             * @param end the upper bound of the range of model instances (not inclusive)
210             * @return the range of matching rows
211             * @throws SystemException if a system exception occurred
212             */
213            @SuppressWarnings("rawtypes")
214            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
215                    throws SystemException {
216                    return assetLinkPersistence.findWithDynamicQuery(dynamicQuery, start,
217                            end);
218            }
219    
220            /**
221             * Performs a dynamic query on the database and returns an ordered range of the matching rows.
222             *
223             * <p>
224             * 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.
225             * </p>
226             *
227             * @param dynamicQuery the dynamic query
228             * @param start the lower bound of the range of model instances
229             * @param end the upper bound of the range of model instances (not inclusive)
230             * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
231             * @return the ordered range of matching rows
232             * @throws SystemException if a system exception occurred
233             */
234            @SuppressWarnings("rawtypes")
235            public List dynamicQuery(DynamicQuery dynamicQuery, int start, int end,
236                    OrderByComparator orderByComparator) throws SystemException {
237                    return assetLinkPersistence.findWithDynamicQuery(dynamicQuery, start,
238                            end, orderByComparator);
239            }
240    
241            /**
242             * Returns the number of rows that match the dynamic query.
243             *
244             * @param dynamicQuery the dynamic query
245             * @return the number of rows that match the dynamic query
246             * @throws SystemException if a system exception occurred
247             */
248            public long dynamicQueryCount(DynamicQuery dynamicQuery)
249                    throws SystemException {
250                    return assetLinkPersistence.countWithDynamicQuery(dynamicQuery);
251            }
252    
253            public AssetLink fetchAssetLink(long linkId) throws SystemException {
254                    return assetLinkPersistence.fetchByPrimaryKey(linkId);
255            }
256    
257            /**
258             * Returns the asset link with the primary key.
259             *
260             * @param linkId the primary key of the asset link
261             * @return the asset link
262             * @throws PortalException if a asset link with the primary key could not be found
263             * @throws SystemException if a system exception occurred
264             */
265            public AssetLink getAssetLink(long linkId)
266                    throws PortalException, SystemException {
267                    return assetLinkPersistence.findByPrimaryKey(linkId);
268            }
269    
270            public PersistedModel getPersistedModel(Serializable primaryKeyObj)
271                    throws PortalException, SystemException {
272                    return assetLinkPersistence.findByPrimaryKey(primaryKeyObj);
273            }
274    
275            /**
276             * Returns a range of all the asset links.
277             *
278             * <p>
279             * 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.
280             * </p>
281             *
282             * @param start the lower bound of the range of asset links
283             * @param end the upper bound of the range of asset links (not inclusive)
284             * @return the range of asset links
285             * @throws SystemException if a system exception occurred
286             */
287            public List<AssetLink> getAssetLinks(int start, int end)
288                    throws SystemException {
289                    return assetLinkPersistence.findAll(start, end);
290            }
291    
292            /**
293             * Returns the number of asset links.
294             *
295             * @return the number of asset links
296             * @throws SystemException if a system exception occurred
297             */
298            public int getAssetLinksCount() throws SystemException {
299                    return assetLinkPersistence.countAll();
300            }
301    
302            /**
303             * Updates the asset link in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
304             *
305             * @param assetLink the asset link
306             * @return the asset link that was updated
307             * @throws SystemException if a system exception occurred
308             */
309            public AssetLink updateAssetLink(AssetLink assetLink)
310                    throws SystemException {
311                    return updateAssetLink(assetLink, true);
312            }
313    
314            /**
315             * Updates the asset link in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
316             *
317             * @param assetLink the asset link
318             * @param merge whether to merge the asset link with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
319             * @return the asset link that was updated
320             * @throws SystemException if a system exception occurred
321             */
322            public AssetLink updateAssetLink(AssetLink assetLink, boolean merge)
323                    throws SystemException {
324                    assetLink.setNew(false);
325    
326                    assetLink = assetLinkPersistence.update(assetLink, merge);
327    
328                    Indexer indexer = IndexerRegistryUtil.getIndexer(getModelClassName());
329    
330                    if (indexer != null) {
331                            try {
332                                    indexer.reindex(assetLink);
333                            }
334                            catch (SearchException se) {
335                                    if (_log.isWarnEnabled()) {
336                                            _log.warn(se, se);
337                                    }
338                            }
339                    }
340    
341                    return assetLink;
342            }
343    
344            /**
345             * Returns the asset category local service.
346             *
347             * @return the asset category local service
348             */
349            public AssetCategoryLocalService getAssetCategoryLocalService() {
350                    return assetCategoryLocalService;
351            }
352    
353            /**
354             * Sets the asset category local service.
355             *
356             * @param assetCategoryLocalService the asset category local service
357             */
358            public void setAssetCategoryLocalService(
359                    AssetCategoryLocalService assetCategoryLocalService) {
360                    this.assetCategoryLocalService = assetCategoryLocalService;
361            }
362    
363            /**
364             * Returns the asset category remote service.
365             *
366             * @return the asset category remote service
367             */
368            public AssetCategoryService getAssetCategoryService() {
369                    return assetCategoryService;
370            }
371    
372            /**
373             * Sets the asset category remote service.
374             *
375             * @param assetCategoryService the asset category remote service
376             */
377            public void setAssetCategoryService(
378                    AssetCategoryService assetCategoryService) {
379                    this.assetCategoryService = assetCategoryService;
380            }
381    
382            /**
383             * Returns the asset category persistence.
384             *
385             * @return the asset category persistence
386             */
387            public AssetCategoryPersistence getAssetCategoryPersistence() {
388                    return assetCategoryPersistence;
389            }
390    
391            /**
392             * Sets the asset category persistence.
393             *
394             * @param assetCategoryPersistence the asset category persistence
395             */
396            public void setAssetCategoryPersistence(
397                    AssetCategoryPersistence assetCategoryPersistence) {
398                    this.assetCategoryPersistence = assetCategoryPersistence;
399            }
400    
401            /**
402             * Returns the asset category finder.
403             *
404             * @return the asset category finder
405             */
406            public AssetCategoryFinder getAssetCategoryFinder() {
407                    return assetCategoryFinder;
408            }
409    
410            /**
411             * Sets the asset category finder.
412             *
413             * @param assetCategoryFinder the asset category finder
414             */
415            public void setAssetCategoryFinder(AssetCategoryFinder assetCategoryFinder) {
416                    this.assetCategoryFinder = assetCategoryFinder;
417            }
418    
419            /**
420             * Returns the asset category property local service.
421             *
422             * @return the asset category property local service
423             */
424            public AssetCategoryPropertyLocalService getAssetCategoryPropertyLocalService() {
425                    return assetCategoryPropertyLocalService;
426            }
427    
428            /**
429             * Sets the asset category property local service.
430             *
431             * @param assetCategoryPropertyLocalService the asset category property local service
432             */
433            public void setAssetCategoryPropertyLocalService(
434                    AssetCategoryPropertyLocalService assetCategoryPropertyLocalService) {
435                    this.assetCategoryPropertyLocalService = assetCategoryPropertyLocalService;
436            }
437    
438            /**
439             * Returns the asset category property remote service.
440             *
441             * @return the asset category property remote service
442             */
443            public AssetCategoryPropertyService getAssetCategoryPropertyService() {
444                    return assetCategoryPropertyService;
445            }
446    
447            /**
448             * Sets the asset category property remote service.
449             *
450             * @param assetCategoryPropertyService the asset category property remote service
451             */
452            public void setAssetCategoryPropertyService(
453                    AssetCategoryPropertyService assetCategoryPropertyService) {
454                    this.assetCategoryPropertyService = assetCategoryPropertyService;
455            }
456    
457            /**
458             * Returns the asset category property persistence.
459             *
460             * @return the asset category property persistence
461             */
462            public AssetCategoryPropertyPersistence getAssetCategoryPropertyPersistence() {
463                    return assetCategoryPropertyPersistence;
464            }
465    
466            /**
467             * Sets the asset category property persistence.
468             *
469             * @param assetCategoryPropertyPersistence the asset category property persistence
470             */
471            public void setAssetCategoryPropertyPersistence(
472                    AssetCategoryPropertyPersistence assetCategoryPropertyPersistence) {
473                    this.assetCategoryPropertyPersistence = assetCategoryPropertyPersistence;
474            }
475    
476            /**
477             * Returns the asset category property finder.
478             *
479             * @return the asset category property finder
480             */
481            public AssetCategoryPropertyFinder getAssetCategoryPropertyFinder() {
482                    return assetCategoryPropertyFinder;
483            }
484    
485            /**
486             * Sets the asset category property finder.
487             *
488             * @param assetCategoryPropertyFinder the asset category property finder
489             */
490            public void setAssetCategoryPropertyFinder(
491                    AssetCategoryPropertyFinder assetCategoryPropertyFinder) {
492                    this.assetCategoryPropertyFinder = assetCategoryPropertyFinder;
493            }
494    
495            /**
496             * Returns the asset entry local service.
497             *
498             * @return the asset entry local service
499             */
500            public AssetEntryLocalService getAssetEntryLocalService() {
501                    return assetEntryLocalService;
502            }
503    
504            /**
505             * Sets the asset entry local service.
506             *
507             * @param assetEntryLocalService the asset entry local service
508             */
509            public void setAssetEntryLocalService(
510                    AssetEntryLocalService assetEntryLocalService) {
511                    this.assetEntryLocalService = assetEntryLocalService;
512            }
513    
514            /**
515             * Returns the asset entry remote service.
516             *
517             * @return the asset entry remote service
518             */
519            public AssetEntryService getAssetEntryService() {
520                    return assetEntryService;
521            }
522    
523            /**
524             * Sets the asset entry remote service.
525             *
526             * @param assetEntryService the asset entry remote service
527             */
528            public void setAssetEntryService(AssetEntryService assetEntryService) {
529                    this.assetEntryService = assetEntryService;
530            }
531    
532            /**
533             * Returns the asset entry persistence.
534             *
535             * @return the asset entry persistence
536             */
537            public AssetEntryPersistence getAssetEntryPersistence() {
538                    return assetEntryPersistence;
539            }
540    
541            /**
542             * Sets the asset entry persistence.
543             *
544             * @param assetEntryPersistence the asset entry persistence
545             */
546            public void setAssetEntryPersistence(
547                    AssetEntryPersistence assetEntryPersistence) {
548                    this.assetEntryPersistence = assetEntryPersistence;
549            }
550    
551            /**
552             * Returns the asset entry finder.
553             *
554             * @return the asset entry finder
555             */
556            public AssetEntryFinder getAssetEntryFinder() {
557                    return assetEntryFinder;
558            }
559    
560            /**
561             * Sets the asset entry finder.
562             *
563             * @param assetEntryFinder the asset entry finder
564             */
565            public void setAssetEntryFinder(AssetEntryFinder assetEntryFinder) {
566                    this.assetEntryFinder = assetEntryFinder;
567            }
568    
569            /**
570             * Returns the asset link local service.
571             *
572             * @return the asset link local service
573             */
574            public AssetLinkLocalService getAssetLinkLocalService() {
575                    return assetLinkLocalService;
576            }
577    
578            /**
579             * Sets the asset link local service.
580             *
581             * @param assetLinkLocalService the asset link local service
582             */
583            public void setAssetLinkLocalService(
584                    AssetLinkLocalService assetLinkLocalService) {
585                    this.assetLinkLocalService = assetLinkLocalService;
586            }
587    
588            /**
589             * Returns the asset link persistence.
590             *
591             * @return the asset link persistence
592             */
593            public AssetLinkPersistence getAssetLinkPersistence() {
594                    return assetLinkPersistence;
595            }
596    
597            /**
598             * Sets the asset link persistence.
599             *
600             * @param assetLinkPersistence the asset link persistence
601             */
602            public void setAssetLinkPersistence(
603                    AssetLinkPersistence assetLinkPersistence) {
604                    this.assetLinkPersistence = assetLinkPersistence;
605            }
606    
607            /**
608             * Returns the asset tag local service.
609             *
610             * @return the asset tag local service
611             */
612            public AssetTagLocalService getAssetTagLocalService() {
613                    return assetTagLocalService;
614            }
615    
616            /**
617             * Sets the asset tag local service.
618             *
619             * @param assetTagLocalService the asset tag local service
620             */
621            public void setAssetTagLocalService(
622                    AssetTagLocalService assetTagLocalService) {
623                    this.assetTagLocalService = assetTagLocalService;
624            }
625    
626            /**
627             * Returns the asset tag remote service.
628             *
629             * @return the asset tag remote service
630             */
631            public AssetTagService getAssetTagService() {
632                    return assetTagService;
633            }
634    
635            /**
636             * Sets the asset tag remote service.
637             *
638             * @param assetTagService the asset tag remote service
639             */
640            public void setAssetTagService(AssetTagService assetTagService) {
641                    this.assetTagService = assetTagService;
642            }
643    
644            /**
645             * Returns the asset tag persistence.
646             *
647             * @return the asset tag persistence
648             */
649            public AssetTagPersistence getAssetTagPersistence() {
650                    return assetTagPersistence;
651            }
652    
653            /**
654             * Sets the asset tag persistence.
655             *
656             * @param assetTagPersistence the asset tag persistence
657             */
658            public void setAssetTagPersistence(AssetTagPersistence assetTagPersistence) {
659                    this.assetTagPersistence = assetTagPersistence;
660            }
661    
662            /**
663             * Returns the asset tag finder.
664             *
665             * @return the asset tag finder
666             */
667            public AssetTagFinder getAssetTagFinder() {
668                    return assetTagFinder;
669            }
670    
671            /**
672             * Sets the asset tag finder.
673             *
674             * @param assetTagFinder the asset tag finder
675             */
676            public void setAssetTagFinder(AssetTagFinder assetTagFinder) {
677                    this.assetTagFinder = assetTagFinder;
678            }
679    
680            /**
681             * Returns the asset tag property local service.
682             *
683             * @return the asset tag property local service
684             */
685            public AssetTagPropertyLocalService getAssetTagPropertyLocalService() {
686                    return assetTagPropertyLocalService;
687            }
688    
689            /**
690             * Sets the asset tag property local service.
691             *
692             * @param assetTagPropertyLocalService the asset tag property local service
693             */
694            public void setAssetTagPropertyLocalService(
695                    AssetTagPropertyLocalService assetTagPropertyLocalService) {
696                    this.assetTagPropertyLocalService = assetTagPropertyLocalService;
697            }
698    
699            /**
700             * Returns the asset tag property remote service.
701             *
702             * @return the asset tag property remote service
703             */
704            public AssetTagPropertyService getAssetTagPropertyService() {
705                    return assetTagPropertyService;
706            }
707    
708            /**
709             * Sets the asset tag property remote service.
710             *
711             * @param assetTagPropertyService the asset tag property remote service
712             */
713            public void setAssetTagPropertyService(
714                    AssetTagPropertyService assetTagPropertyService) {
715                    this.assetTagPropertyService = assetTagPropertyService;
716            }
717    
718            /**
719             * Returns the asset tag property persistence.
720             *
721             * @return the asset tag property persistence
722             */
723            public AssetTagPropertyPersistence getAssetTagPropertyPersistence() {
724                    return assetTagPropertyPersistence;
725            }
726    
727            /**
728             * Sets the asset tag property persistence.
729             *
730             * @param assetTagPropertyPersistence the asset tag property persistence
731             */
732            public void setAssetTagPropertyPersistence(
733                    AssetTagPropertyPersistence assetTagPropertyPersistence) {
734                    this.assetTagPropertyPersistence = assetTagPropertyPersistence;
735            }
736    
737            /**
738             * Returns the asset tag property finder.
739             *
740             * @return the asset tag property finder
741             */
742            public AssetTagPropertyFinder getAssetTagPropertyFinder() {
743                    return assetTagPropertyFinder;
744            }
745    
746            /**
747             * Sets the asset tag property finder.
748             *
749             * @param assetTagPropertyFinder the asset tag property finder
750             */
751            public void setAssetTagPropertyFinder(
752                    AssetTagPropertyFinder assetTagPropertyFinder) {
753                    this.assetTagPropertyFinder = assetTagPropertyFinder;
754            }
755    
756            /**
757             * Returns the asset tag property key finder.
758             *
759             * @return the asset tag property key finder
760             */
761            public AssetTagPropertyKeyFinder getAssetTagPropertyKeyFinder() {
762                    return assetTagPropertyKeyFinder;
763            }
764    
765            /**
766             * Sets the asset tag property key finder.
767             *
768             * @param assetTagPropertyKeyFinder the asset tag property key finder
769             */
770            public void setAssetTagPropertyKeyFinder(
771                    AssetTagPropertyKeyFinder assetTagPropertyKeyFinder) {
772                    this.assetTagPropertyKeyFinder = assetTagPropertyKeyFinder;
773            }
774    
775            /**
776             * Returns the asset tag stats local service.
777             *
778             * @return the asset tag stats local service
779             */
780            public AssetTagStatsLocalService getAssetTagStatsLocalService() {
781                    return assetTagStatsLocalService;
782            }
783    
784            /**
785             * Sets the asset tag stats local service.
786             *
787             * @param assetTagStatsLocalService the asset tag stats local service
788             */
789            public void setAssetTagStatsLocalService(
790                    AssetTagStatsLocalService assetTagStatsLocalService) {
791                    this.assetTagStatsLocalService = assetTagStatsLocalService;
792            }
793    
794            /**
795             * Returns the asset tag stats persistence.
796             *
797             * @return the asset tag stats persistence
798             */
799            public AssetTagStatsPersistence getAssetTagStatsPersistence() {
800                    return assetTagStatsPersistence;
801            }
802    
803            /**
804             * Sets the asset tag stats persistence.
805             *
806             * @param assetTagStatsPersistence the asset tag stats persistence
807             */
808            public void setAssetTagStatsPersistence(
809                    AssetTagStatsPersistence assetTagStatsPersistence) {
810                    this.assetTagStatsPersistence = assetTagStatsPersistence;
811            }
812    
813            /**
814             * Returns the asset vocabulary local service.
815             *
816             * @return the asset vocabulary local service
817             */
818            public AssetVocabularyLocalService getAssetVocabularyLocalService() {
819                    return assetVocabularyLocalService;
820            }
821    
822            /**
823             * Sets the asset vocabulary local service.
824             *
825             * @param assetVocabularyLocalService the asset vocabulary local service
826             */
827            public void setAssetVocabularyLocalService(
828                    AssetVocabularyLocalService assetVocabularyLocalService) {
829                    this.assetVocabularyLocalService = assetVocabularyLocalService;
830            }
831    
832            /**
833             * Returns the asset vocabulary remote service.
834             *
835             * @return the asset vocabulary remote service
836             */
837            public AssetVocabularyService getAssetVocabularyService() {
838                    return assetVocabularyService;
839            }
840    
841            /**
842             * Sets the asset vocabulary remote service.
843             *
844             * @param assetVocabularyService the asset vocabulary remote service
845             */
846            public void setAssetVocabularyService(
847                    AssetVocabularyService assetVocabularyService) {
848                    this.assetVocabularyService = assetVocabularyService;
849            }
850    
851            /**
852             * Returns the asset vocabulary persistence.
853             *
854             * @return the asset vocabulary persistence
855             */
856            public AssetVocabularyPersistence getAssetVocabularyPersistence() {
857                    return assetVocabularyPersistence;
858            }
859    
860            /**
861             * Sets the asset vocabulary persistence.
862             *
863             * @param assetVocabularyPersistence the asset vocabulary persistence
864             */
865            public void setAssetVocabularyPersistence(
866                    AssetVocabularyPersistence assetVocabularyPersistence) {
867                    this.assetVocabularyPersistence = assetVocabularyPersistence;
868            }
869    
870            /**
871             * Returns the asset vocabulary finder.
872             *
873             * @return the asset vocabulary finder
874             */
875            public AssetVocabularyFinder getAssetVocabularyFinder() {
876                    return assetVocabularyFinder;
877            }
878    
879            /**
880             * Sets the asset vocabulary finder.
881             *
882             * @param assetVocabularyFinder the asset vocabulary finder
883             */
884            public void setAssetVocabularyFinder(
885                    AssetVocabularyFinder assetVocabularyFinder) {
886                    this.assetVocabularyFinder = assetVocabularyFinder;
887            }
888    
889            /**
890             * Returns the counter local service.
891             *
892             * @return the counter local service
893             */
894            public CounterLocalService getCounterLocalService() {
895                    return counterLocalService;
896            }
897    
898            /**
899             * Sets the counter local service.
900             *
901             * @param counterLocalService the counter local service
902             */
903            public void setCounterLocalService(CounterLocalService counterLocalService) {
904                    this.counterLocalService = counterLocalService;
905            }
906    
907            /**
908             * Returns the resource local service.
909             *
910             * @return the resource local service
911             */
912            public ResourceLocalService getResourceLocalService() {
913                    return resourceLocalService;
914            }
915    
916            /**
917             * Sets the resource local service.
918             *
919             * @param resourceLocalService the resource local service
920             */
921            public void setResourceLocalService(
922                    ResourceLocalService resourceLocalService) {
923                    this.resourceLocalService = resourceLocalService;
924            }
925    
926            /**
927             * Returns the resource remote service.
928             *
929             * @return the resource remote service
930             */
931            public ResourceService getResourceService() {
932                    return resourceService;
933            }
934    
935            /**
936             * Sets the resource remote service.
937             *
938             * @param resourceService the resource remote service
939             */
940            public void setResourceService(ResourceService resourceService) {
941                    this.resourceService = resourceService;
942            }
943    
944            /**
945             * Returns the resource persistence.
946             *
947             * @return the resource persistence
948             */
949            public ResourcePersistence getResourcePersistence() {
950                    return resourcePersistence;
951            }
952    
953            /**
954             * Sets the resource persistence.
955             *
956             * @param resourcePersistence the resource persistence
957             */
958            public void setResourcePersistence(ResourcePersistence resourcePersistence) {
959                    this.resourcePersistence = resourcePersistence;
960            }
961    
962            /**
963             * Returns the resource finder.
964             *
965             * @return the resource finder
966             */
967            public ResourceFinder getResourceFinder() {
968                    return resourceFinder;
969            }
970    
971            /**
972             * Sets the resource finder.
973             *
974             * @param resourceFinder the resource finder
975             */
976            public void setResourceFinder(ResourceFinder resourceFinder) {
977                    this.resourceFinder = resourceFinder;
978            }
979    
980            /**
981             * Returns the user local service.
982             *
983             * @return the user local service
984             */
985            public UserLocalService getUserLocalService() {
986                    return userLocalService;
987            }
988    
989            /**
990             * Sets the user local service.
991             *
992             * @param userLocalService the user local service
993             */
994            public void setUserLocalService(UserLocalService userLocalService) {
995                    this.userLocalService = userLocalService;
996            }
997    
998            /**
999             * Returns the user remote service.
1000             *
1001             * @return the user remote service
1002             */
1003            public UserService getUserService() {
1004                    return userService;
1005            }
1006    
1007            /**
1008             * Sets the user remote service.
1009             *
1010             * @param userService the user remote service
1011             */
1012            public void setUserService(UserService userService) {
1013                    this.userService = userService;
1014            }
1015    
1016            /**
1017             * Returns the user persistence.
1018             *
1019             * @return the user persistence
1020             */
1021            public UserPersistence getUserPersistence() {
1022                    return userPersistence;
1023            }
1024    
1025            /**
1026             * Sets the user persistence.
1027             *
1028             * @param userPersistence the user persistence
1029             */
1030            public void setUserPersistence(UserPersistence userPersistence) {
1031                    this.userPersistence = userPersistence;
1032            }
1033    
1034            /**
1035             * Returns the user finder.
1036             *
1037             * @return the user finder
1038             */
1039            public UserFinder getUserFinder() {
1040                    return userFinder;
1041            }
1042    
1043            /**
1044             * Sets the user finder.
1045             *
1046             * @param userFinder the user finder
1047             */
1048            public void setUserFinder(UserFinder userFinder) {
1049                    this.userFinder = userFinder;
1050            }
1051    
1052            public void afterPropertiesSet() {
1053                    persistedModelLocalServiceRegistry.register("com.liferay.portlet.asset.model.AssetLink",
1054                            assetLinkLocalService);
1055            }
1056    
1057            public void destroy() {
1058                    persistedModelLocalServiceRegistry.unregister(
1059                            "com.liferay.portlet.asset.model.AssetLink");
1060            }
1061    
1062            /**
1063             * Returns the Spring bean ID for this bean.
1064             *
1065             * @return the Spring bean ID for this bean
1066             */
1067            public String getBeanIdentifier() {
1068                    return _beanIdentifier;
1069            }
1070    
1071            /**
1072             * Sets the Spring bean ID for this bean.
1073             *
1074             * @param beanIdentifier the Spring bean ID for this bean
1075             */
1076            public void setBeanIdentifier(String beanIdentifier) {
1077                    _beanIdentifier = beanIdentifier;
1078            }
1079    
1080            protected ClassLoader getClassLoader() {
1081                    Class<?> clazz = getClass();
1082    
1083                    return clazz.getClassLoader();
1084            }
1085    
1086            protected Class<?> getModelClass() {
1087                    return AssetLink.class;
1088            }
1089    
1090            protected String getModelClassName() {
1091                    return AssetLink.class.getName();
1092            }
1093    
1094            /**
1095             * Performs an SQL query.
1096             *
1097             * @param sql the sql query
1098             */
1099            protected void runSQL(String sql) throws SystemException {
1100                    try {
1101                            DataSource dataSource = assetLinkPersistence.getDataSource();
1102    
1103                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
1104                                            sql, new int[0]);
1105    
1106                            sqlUpdate.update();
1107                    }
1108                    catch (Exception e) {
1109                            throw new SystemException(e);
1110                    }
1111            }
1112    
1113            @BeanReference(type = AssetCategoryLocalService.class)
1114            protected AssetCategoryLocalService assetCategoryLocalService;
1115            @BeanReference(type = AssetCategoryService.class)
1116            protected AssetCategoryService assetCategoryService;
1117            @BeanReference(type = AssetCategoryPersistence.class)
1118            protected AssetCategoryPersistence assetCategoryPersistence;
1119            @BeanReference(type = AssetCategoryFinder.class)
1120            protected AssetCategoryFinder assetCategoryFinder;
1121            @BeanReference(type = AssetCategoryPropertyLocalService.class)
1122            protected AssetCategoryPropertyLocalService assetCategoryPropertyLocalService;
1123            @BeanReference(type = AssetCategoryPropertyService.class)
1124            protected AssetCategoryPropertyService assetCategoryPropertyService;
1125            @BeanReference(type = AssetCategoryPropertyPersistence.class)
1126            protected AssetCategoryPropertyPersistence assetCategoryPropertyPersistence;
1127            @BeanReference(type = AssetCategoryPropertyFinder.class)
1128            protected AssetCategoryPropertyFinder assetCategoryPropertyFinder;
1129            @BeanReference(type = AssetEntryLocalService.class)
1130            protected AssetEntryLocalService assetEntryLocalService;
1131            @BeanReference(type = AssetEntryService.class)
1132            protected AssetEntryService assetEntryService;
1133            @BeanReference(type = AssetEntryPersistence.class)
1134            protected AssetEntryPersistence assetEntryPersistence;
1135            @BeanReference(type = AssetEntryFinder.class)
1136            protected AssetEntryFinder assetEntryFinder;
1137            @BeanReference(type = AssetLinkLocalService.class)
1138            protected AssetLinkLocalService assetLinkLocalService;
1139            @BeanReference(type = AssetLinkPersistence.class)
1140            protected AssetLinkPersistence assetLinkPersistence;
1141            @BeanReference(type = AssetTagLocalService.class)
1142            protected AssetTagLocalService assetTagLocalService;
1143            @BeanReference(type = AssetTagService.class)
1144            protected AssetTagService assetTagService;
1145            @BeanReference(type = AssetTagPersistence.class)
1146            protected AssetTagPersistence assetTagPersistence;
1147            @BeanReference(type = AssetTagFinder.class)
1148            protected AssetTagFinder assetTagFinder;
1149            @BeanReference(type = AssetTagPropertyLocalService.class)
1150            protected AssetTagPropertyLocalService assetTagPropertyLocalService;
1151            @BeanReference(type = AssetTagPropertyService.class)
1152            protected AssetTagPropertyService assetTagPropertyService;
1153            @BeanReference(type = AssetTagPropertyPersistence.class)
1154            protected AssetTagPropertyPersistence assetTagPropertyPersistence;
1155            @BeanReference(type = AssetTagPropertyFinder.class)
1156            protected AssetTagPropertyFinder assetTagPropertyFinder;
1157            @BeanReference(type = AssetTagPropertyKeyFinder.class)
1158            protected AssetTagPropertyKeyFinder assetTagPropertyKeyFinder;
1159            @BeanReference(type = AssetTagStatsLocalService.class)
1160            protected AssetTagStatsLocalService assetTagStatsLocalService;
1161            @BeanReference(type = AssetTagStatsPersistence.class)
1162            protected AssetTagStatsPersistence assetTagStatsPersistence;
1163            @BeanReference(type = AssetVocabularyLocalService.class)
1164            protected AssetVocabularyLocalService assetVocabularyLocalService;
1165            @BeanReference(type = AssetVocabularyService.class)
1166            protected AssetVocabularyService assetVocabularyService;
1167            @BeanReference(type = AssetVocabularyPersistence.class)
1168            protected AssetVocabularyPersistence assetVocabularyPersistence;
1169            @BeanReference(type = AssetVocabularyFinder.class)
1170            protected AssetVocabularyFinder assetVocabularyFinder;
1171            @BeanReference(type = CounterLocalService.class)
1172            protected CounterLocalService counterLocalService;
1173            @BeanReference(type = ResourceLocalService.class)
1174            protected ResourceLocalService resourceLocalService;
1175            @BeanReference(type = ResourceService.class)
1176            protected ResourceService resourceService;
1177            @BeanReference(type = ResourcePersistence.class)
1178            protected ResourcePersistence resourcePersistence;
1179            @BeanReference(type = ResourceFinder.class)
1180            protected ResourceFinder resourceFinder;
1181            @BeanReference(type = UserLocalService.class)
1182            protected UserLocalService userLocalService;
1183            @BeanReference(type = UserService.class)
1184            protected UserService userService;
1185            @BeanReference(type = UserPersistence.class)
1186            protected UserPersistence userPersistence;
1187            @BeanReference(type = UserFinder.class)
1188            protected UserFinder userFinder;
1189            @BeanReference(type = PersistedModelLocalServiceRegistry.class)
1190            protected PersistedModelLocalServiceRegistry persistedModelLocalServiceRegistry;
1191            private static Log _log = LogFactoryUtil.getLog(AssetLinkLocalServiceBaseImpl.class);
1192            private String _beanIdentifier;
1193    }