001    /**
002     * Copyright (c) 2000-present 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;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020    import com.liferay.portal.kernel.util.ReferenceRegistry;
021    
022    /**
023     * Provides the local service utility for AssetTagStats. This utility wraps
024     * {@link com.liferay.portlet.asset.service.impl.AssetTagStatsLocalServiceImpl} and is the
025     * primary access point for service operations in application layer code running
026     * on the local server. Methods of this service will not have security checks
027     * based on the propagated JAAS credentials because this service can only be
028     * accessed from within the same VM.
029     *
030     * @author Brian Wing Shun Chan
031     * @see AssetTagStatsLocalService
032     * @see com.liferay.portlet.asset.service.base.AssetTagStatsLocalServiceBaseImpl
033     * @see com.liferay.portlet.asset.service.impl.AssetTagStatsLocalServiceImpl
034     * @generated
035     */
036    @ProviderType
037    public class AssetTagStatsLocalServiceUtil {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.asset.service.impl.AssetTagStatsLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
042             */
043    
044            /**
045            * Adds the asset tag stats to the database. Also notifies the appropriate model listeners.
046            *
047            * @param assetTagStats the asset tag stats
048            * @return the asset tag stats that was added
049            */
050            public static com.liferay.portlet.asset.model.AssetTagStats addAssetTagStats(
051                    com.liferay.portlet.asset.model.AssetTagStats assetTagStats) {
052                    return getService().addAssetTagStats(assetTagStats);
053            }
054    
055            /**
056            * Adds an asset tag statistics instance.
057            *
058            * @param tagId the primary key of the tag
059            * @param classNameId the asset entry's class name ID
060            * @return the asset tag statistics instance
061            */
062            public static com.liferay.portlet.asset.model.AssetTagStats addTagStats(
063                    long tagId, long classNameId) {
064                    return getService().addTagStats(tagId, classNameId);
065            }
066    
067            /**
068            * Creates a new asset tag stats with the primary key. Does not add the asset tag stats to the database.
069            *
070            * @param tagStatsId the primary key for the new asset tag stats
071            * @return the new asset tag stats
072            */
073            public static com.liferay.portlet.asset.model.AssetTagStats createAssetTagStats(
074                    long tagStatsId) {
075                    return getService().createAssetTagStats(tagStatsId);
076            }
077    
078            /**
079            * Deletes the asset tag stats from the database. Also notifies the appropriate model listeners.
080            *
081            * @param assetTagStats the asset tag stats
082            * @return the asset tag stats that was removed
083            */
084            public static com.liferay.portlet.asset.model.AssetTagStats deleteAssetTagStats(
085                    com.liferay.portlet.asset.model.AssetTagStats assetTagStats) {
086                    return getService().deleteAssetTagStats(assetTagStats);
087            }
088    
089            /**
090            * Deletes the asset tag stats with the primary key from the database. Also notifies the appropriate model listeners.
091            *
092            * @param tagStatsId the primary key of the asset tag stats
093            * @return the asset tag stats that was removed
094            * @throws PortalException if a asset tag stats with the primary key could not be found
095            */
096            public static com.liferay.portlet.asset.model.AssetTagStats deleteAssetTagStats(
097                    long tagStatsId)
098                    throws com.liferay.portal.kernel.exception.PortalException {
099                    return getService().deleteAssetTagStats(tagStatsId);
100            }
101    
102            /**
103            * @throws PortalException
104            */
105            public static com.liferay.portal.model.PersistedModel deletePersistedModel(
106                    com.liferay.portal.model.PersistedModel persistedModel)
107                    throws com.liferay.portal.kernel.exception.PortalException {
108                    return getService().deletePersistedModel(persistedModel);
109            }
110    
111            /**
112            * Deletes the asset tag statistics instance.
113            *
114            * @param tagStats the asset tag statistics instance
115            */
116            public static void deleteTagStats(
117                    com.liferay.portlet.asset.model.AssetTagStats tagStats) {
118                    getService().deleteTagStats(tagStats);
119            }
120    
121            /**
122            * Deletes the asset tag statistics instance matching the tag statistics ID.
123            *
124            * @param tagStatsId the primary key of the asset tag statistics instance
125            * @throws PortalException if the assetTagStats with the primary key could
126            not be found
127            */
128            public static void deleteTagStats(long tagStatsId)
129                    throws com.liferay.portal.kernel.exception.PortalException {
130                    getService().deleteTagStats(tagStatsId);
131            }
132    
133            /**
134            * Deletes all asset tag statistics instances associated with the asset
135            * entry matching the class name ID.
136            *
137            * @param classNameId the asset entry's class name ID
138            */
139            public static void deleteTagStatsByClassNameId(long classNameId) {
140                    getService().deleteTagStatsByClassNameId(classNameId);
141            }
142    
143            /**
144            * Deletes all asset tag statistics instances associated with the tag.
145            *
146            * @param tagId the primary key of the tag
147            */
148            public static void deleteTagStatsByTagId(long tagId) {
149                    getService().deleteTagStatsByTagId(tagId);
150            }
151    
152            public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() {
153                    return getService().dynamicQuery();
154            }
155    
156            /**
157            * Performs a dynamic query on the database and returns the matching rows.
158            *
159            * @param dynamicQuery the dynamic query
160            * @return the matching rows
161            */
162            public static <T> java.util.List<T> dynamicQuery(
163                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) {
164                    return getService().dynamicQuery(dynamicQuery);
165            }
166    
167            /**
168            * Performs a dynamic query on the database and returns a range of the matching rows.
169            *
170            * <p>
171            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.asset.model.impl.AssetTagStatsModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
172            * </p>
173            *
174            * @param dynamicQuery the dynamic query
175            * @param start the lower bound of the range of model instances
176            * @param end the upper bound of the range of model instances (not inclusive)
177            * @return the range of matching rows
178            */
179            public static <T> java.util.List<T> dynamicQuery(
180                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
181                    int end) {
182                    return getService().dynamicQuery(dynamicQuery, start, end);
183            }
184    
185            /**
186            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
187            *
188            * <p>
189            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.asset.model.impl.AssetTagStatsModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
190            * </p>
191            *
192            * @param dynamicQuery the dynamic query
193            * @param start the lower bound of the range of model instances
194            * @param end the upper bound of the range of model instances (not inclusive)
195            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
196            * @return the ordered range of matching rows
197            */
198            public static <T> java.util.List<T> dynamicQuery(
199                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
200                    int end,
201                    com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) {
202                    return getService()
203                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
204            }
205    
206            /**
207            * Returns the number of rows matching the dynamic query.
208            *
209            * @param dynamicQuery the dynamic query
210            * @return the number of rows matching the dynamic query
211            */
212            public static long dynamicQueryCount(
213                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) {
214                    return getService().dynamicQueryCount(dynamicQuery);
215            }
216    
217            /**
218            * Returns the number of rows matching the dynamic query.
219            *
220            * @param dynamicQuery the dynamic query
221            * @param projection the projection to apply to the query
222            * @return the number of rows matching the dynamic query
223            */
224            public static long dynamicQueryCount(
225                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery,
226                    com.liferay.portal.kernel.dao.orm.Projection projection) {
227                    return getService().dynamicQueryCount(dynamicQuery, projection);
228            }
229    
230            public static com.liferay.portlet.asset.model.AssetTagStats fetchAssetTagStats(
231                    long tagStatsId) {
232                    return getService().fetchAssetTagStats(tagStatsId);
233            }
234    
235            public static com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery() {
236                    return getService().getActionableDynamicQuery();
237            }
238    
239            /**
240            * Returns the asset tag stats with the primary key.
241            *
242            * @param tagStatsId the primary key of the asset tag stats
243            * @return the asset tag stats
244            * @throws PortalException if a asset tag stats with the primary key could not be found
245            */
246            public static com.liferay.portlet.asset.model.AssetTagStats getAssetTagStats(
247                    long tagStatsId)
248                    throws com.liferay.portal.kernel.exception.PortalException {
249                    return getService().getAssetTagStats(tagStatsId);
250            }
251    
252            /**
253            * Returns a range of all the asset tag statses.
254            *
255            * <p>
256            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.asset.model.impl.AssetTagStatsModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
257            * </p>
258            *
259            * @param start the lower bound of the range of asset tag statses
260            * @param end the upper bound of the range of asset tag statses (not inclusive)
261            * @return the range of asset tag statses
262            */
263            public static java.util.List<com.liferay.portlet.asset.model.AssetTagStats> getAssetTagStatses(
264                    int start, int end) {
265                    return getService().getAssetTagStatses(start, end);
266            }
267    
268            /**
269            * Returns the number of asset tag statses.
270            *
271            * @return the number of asset tag statses
272            */
273            public static int getAssetTagStatsesCount() {
274                    return getService().getAssetTagStatsesCount();
275            }
276    
277            /**
278            * Returns the Spring bean ID for this bean.
279            *
280            * @return the Spring bean ID for this bean
281            */
282            public static java.lang.String getBeanIdentifier() {
283                    return getService().getBeanIdentifier();
284            }
285    
286            public static com.liferay.portal.model.PersistedModel getPersistedModel(
287                    java.io.Serializable primaryKeyObj)
288                    throws com.liferay.portal.kernel.exception.PortalException {
289                    return getService().getPersistedModel(primaryKeyObj);
290            }
291    
292            /**
293            * Returns a range of all the asset tag statistics instances associated with
294            * the asset entry matching the class name ID.
295            *
296            * <p>
297            * Useful when paginating results. Returns a maximum of <code>end -
298            * start</code> instances. <code>start</code> and <code>end</code> are not
299            * primary keys, they are indexes in the result set. Thus, <code>0</code>
300            * refers to the first result in the set. Setting both <code>start</code>
301            * and <code>end</code> to {@link
302            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
303            * result set.
304            * </p>
305            *
306            * @param classNameId the asset entry's class name ID
307            * @param start the lower bound of the range of results
308            * @param end the upper bound of the range of results (not inclusive)
309            * @return the range of asset tag statistics associated with the asset entry
310            matching the class name ID
311            */
312            public static java.util.List<com.liferay.portlet.asset.model.AssetTagStats> getTagStats(
313                    long classNameId, int start, int end) {
314                    return getService().getTagStats(classNameId, start, end);
315            }
316    
317            /**
318            * Returns the asset tag statistics instance with the tag and asset entry
319            * matching the class name ID
320            *
321            * @param tagId the primary key of the tag
322            * @param classNameId the asset entry's class name ID
323            * @return Returns the asset tag statistics instance with the tag and asset
324            entry  matching the class name ID
325            */
326            public static com.liferay.portlet.asset.model.AssetTagStats getTagStats(
327                    long tagId, long classNameId) {
328                    return getService().getTagStats(tagId, classNameId);
329            }
330    
331            /**
332            * Sets the Spring bean ID for this bean.
333            *
334            * @param beanIdentifier the Spring bean ID for this bean
335            */
336            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
337                    getService().setBeanIdentifier(beanIdentifier);
338            }
339    
340            /**
341            * Updates the asset tag stats in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
342            *
343            * @param assetTagStats the asset tag stats
344            * @return the asset tag stats that was updated
345            */
346            public static com.liferay.portlet.asset.model.AssetTagStats updateAssetTagStats(
347                    com.liferay.portlet.asset.model.AssetTagStats assetTagStats) {
348                    return getService().updateAssetTagStats(assetTagStats);
349            }
350    
351            /**
352            * Updates the asset tag statistics instance.
353            *
354            * @param tagId the primary key of the tag
355            * @param classNameId the asset entry's class name ID
356            * @return the updated asset tag statistics instance
357            * @throws PortalException if an asset tag with the tag ID could not be
358            found
359            */
360            public static com.liferay.portlet.asset.model.AssetTagStats updateTagStats(
361                    long tagId, long classNameId)
362                    throws com.liferay.portal.kernel.exception.PortalException {
363                    return getService().updateTagStats(tagId, classNameId);
364            }
365    
366            public static AssetTagStatsLocalService getService() {
367                    if (_service == null) {
368                            _service = (AssetTagStatsLocalService)PortalBeanLocatorUtil.locate(AssetTagStatsLocalService.class.getName());
369    
370                            ReferenceRegistry.registerReference(AssetTagStatsLocalServiceUtil.class,
371                                    "_service");
372                    }
373    
374                    return _service;
375            }
376    
377            /**
378             * @deprecated As of 6.2.0
379             */
380            @Deprecated
381            public void setService(AssetTagStatsLocalService service) {
382            }
383    
384            private static AssetTagStatsLocalService _service;
385    }