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