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.exception.PortalException;
020    import com.liferay.portal.kernel.exception.SystemException;
021    import com.liferay.portal.kernel.search.IndexableType;
022    import com.liferay.portal.kernel.transaction.Isolation;
023    import com.liferay.portal.kernel.transaction.Propagation;
024    import com.liferay.portal.kernel.transaction.Transactional;
025    import com.liferay.portal.service.BaseLocalService;
026    import com.liferay.portal.service.PersistedModelLocalService;
027    
028    /**
029     * Provides the local service interface for AssetTagProperty. Methods of this
030     * service will not have security checks based on the propagated JAAS
031     * credentials because this service can only be accessed from within the same
032     * VM.
033     *
034     * @author Brian Wing Shun Chan
035     * @see AssetTagPropertyLocalServiceUtil
036     * @see com.liferay.portlet.asset.service.base.AssetTagPropertyLocalServiceBaseImpl
037     * @see com.liferay.portlet.asset.service.impl.AssetTagPropertyLocalServiceImpl
038     * @generated
039     */
040    @ProviderType
041    @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
042            PortalException.class, SystemException.class})
043    public interface AssetTagPropertyLocalService extends BaseLocalService,
044            PersistedModelLocalService {
045            /*
046             * NOTE FOR DEVELOPERS:
047             *
048             * Never modify or reference this interface directly. Always use {@link AssetTagPropertyLocalServiceUtil} to access the asset tag property local service. Add custom service methods to {@link com.liferay.portlet.asset.service.impl.AssetTagPropertyLocalServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface.
049             */
050    
051            /**
052            * Adds the asset tag property to the database. Also notifies the appropriate model listeners.
053            *
054            * @param assetTagProperty the asset tag property
055            * @return the asset tag property that was added
056            */
057            @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX)
058            public com.liferay.portlet.asset.model.AssetTagProperty addAssetTagProperty(
059                    com.liferay.portlet.asset.model.AssetTagProperty assetTagProperty);
060    
061            /**
062            * Adds an asset tag property.
063            *
064            * @param userId the primary key of the user
065            * @param tagId the primary key of the tag
066            * @param key the key to be associated to the value
067            * @param value the value to which the key will refer
068            * @return the created asset tag property
069            * @throws PortalException if a user with the primary key could not be
070            found, or if the key or value were invalid
071            */
072            public com.liferay.portlet.asset.model.AssetTagProperty addTagProperty(
073                    long userId, long tagId, java.lang.String key, java.lang.String value)
074                    throws com.liferay.portal.kernel.exception.PortalException;
075    
076            /**
077            * Creates a new asset tag property with the primary key. Does not add the asset tag property to the database.
078            *
079            * @param tagPropertyId the primary key for the new asset tag property
080            * @return the new asset tag property
081            */
082            public com.liferay.portlet.asset.model.AssetTagProperty createAssetTagProperty(
083                    long tagPropertyId);
084    
085            /**
086            * Deletes the asset tag property from the database. Also notifies the appropriate model listeners.
087            *
088            * @param assetTagProperty the asset tag property
089            * @return the asset tag property that was removed
090            */
091            @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE)
092            public com.liferay.portlet.asset.model.AssetTagProperty deleteAssetTagProperty(
093                    com.liferay.portlet.asset.model.AssetTagProperty assetTagProperty);
094    
095            /**
096            * Deletes the asset tag property with the primary key from the database. Also notifies the appropriate model listeners.
097            *
098            * @param tagPropertyId the primary key of the asset tag property
099            * @return the asset tag property that was removed
100            * @throws PortalException if a asset tag property with the primary key could not be found
101            */
102            @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE)
103            public com.liferay.portlet.asset.model.AssetTagProperty deleteAssetTagProperty(
104                    long tagPropertyId)
105                    throws com.liferay.portal.kernel.exception.PortalException;
106    
107            /**
108            * @throws PortalException
109            */
110            @Override
111            public com.liferay.portal.model.PersistedModel deletePersistedModel(
112                    com.liferay.portal.model.PersistedModel persistedModel)
113                    throws com.liferay.portal.kernel.exception.PortalException;
114    
115            /**
116            * Deletes the asset tag property with the specified tag ID.
117            *
118            * @param tagId the primary key of the tag
119            */
120            public void deleteTagProperties(long tagId);
121    
122            /**
123            * Deletes the asset tag property instance.
124            *
125            * @param tagProperty the asset tag property instance
126            */
127            public void deleteTagProperty(
128                    com.liferay.portlet.asset.model.AssetTagProperty tagProperty);
129    
130            /**
131            * Deletes the asset tag property with the specified ID.
132            *
133            * @param tagPropertyId the primary key of the asset tag property instance
134            * @throws PortalException if an asset tag property with the primary key
135            could not be found
136            */
137            public void deleteTagProperty(long tagPropertyId)
138                    throws com.liferay.portal.kernel.exception.PortalException;
139    
140            public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery();
141    
142            /**
143            * Performs a dynamic query on the database and returns the matching rows.
144            *
145            * @param dynamicQuery the dynamic query
146            * @return the matching rows
147            */
148            public <T> java.util.List<T> dynamicQuery(
149                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery);
150    
151            /**
152            * Performs a dynamic query on the database and returns a range of the matching rows.
153            *
154            * <p>
155            * 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.AssetTagPropertyModelImpl}. 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.
156            * </p>
157            *
158            * @param dynamicQuery the dynamic query
159            * @param start the lower bound of the range of model instances
160            * @param end the upper bound of the range of model instances (not inclusive)
161            * @return the range of matching rows
162            */
163            public <T> java.util.List<T> dynamicQuery(
164                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
165                    int end);
166    
167            /**
168            * Performs a dynamic query on the database and returns an ordered 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.AssetTagPropertyModelImpl}. 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            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
178            * @return the ordered range of matching rows
179            */
180            public <T> java.util.List<T> dynamicQuery(
181                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
182                    int end,
183                    com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator);
184    
185            /**
186            * Returns the number of rows matching the dynamic query.
187            *
188            * @param dynamicQuery the dynamic query
189            * @return the number of rows matching the dynamic query
190            */
191            public long dynamicQueryCount(
192                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery);
193    
194            /**
195            * Returns the number of rows matching the dynamic query.
196            *
197            * @param dynamicQuery the dynamic query
198            * @param projection the projection to apply to the query
199            * @return the number of rows matching the dynamic query
200            */
201            public long dynamicQueryCount(
202                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery,
203                    com.liferay.portal.kernel.dao.orm.Projection projection);
204    
205            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
206            public com.liferay.portlet.asset.model.AssetTagProperty fetchAssetTagProperty(
207                    long tagPropertyId);
208    
209            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
210            public com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery();
211    
212            /**
213            * Returns a range of all the asset tag properties.
214            *
215            * <p>
216            * 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.AssetTagPropertyModelImpl}. 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.
217            * </p>
218            *
219            * @param start the lower bound of the range of asset tag properties
220            * @param end the upper bound of the range of asset tag properties (not inclusive)
221            * @return the range of asset tag properties
222            */
223            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
224            public java.util.List<com.liferay.portlet.asset.model.AssetTagProperty> getAssetTagProperties(
225                    int start, int end);
226    
227            /**
228            * Returns the number of asset tag properties.
229            *
230            * @return the number of asset tag properties
231            */
232            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
233            public int getAssetTagPropertiesCount();
234    
235            /**
236            * Returns the asset tag property with the primary key.
237            *
238            * @param tagPropertyId the primary key of the asset tag property
239            * @return the asset tag property
240            * @throws PortalException if a asset tag property with the primary key could not be found
241            */
242            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
243            public com.liferay.portlet.asset.model.AssetTagProperty getAssetTagProperty(
244                    long tagPropertyId)
245                    throws com.liferay.portal.kernel.exception.PortalException;
246    
247            /**
248            * Returns the Spring bean ID for this bean.
249            *
250            * @return the Spring bean ID for this bean
251            */
252            public java.lang.String getBeanIdentifier();
253    
254            @Override
255            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
256            public com.liferay.portal.model.PersistedModel getPersistedModel(
257                    java.io.Serializable primaryKeyObj)
258                    throws com.liferay.portal.kernel.exception.PortalException;
259    
260            /**
261            * Returns all the asset tag property instances.
262            *
263            * @return the asset tag property instances
264            */
265            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
266            public java.util.List<com.liferay.portlet.asset.model.AssetTagProperty> getTagProperties();
267    
268            /**
269            * Returns all the asset tag property instances with the specified tag ID.
270            *
271            * @param tagId the primary key of the tag
272            * @return the matching asset tag properties
273            */
274            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
275            public java.util.List<com.liferay.portlet.asset.model.AssetTagProperty> getTagProperties(
276                    long tagId);
277    
278            /**
279            * Returns the asset tag property with the specified tag ID and key.
280            *
281            * @param tagId the primary key of the tag
282            * @param key the key that refers to some value
283            * @return the matching asset tag property
284            * @throws PortalException if an asset tag property with the tag ID and key
285            could not be found
286            */
287            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
288            public com.liferay.portlet.asset.model.AssetTagProperty getTagProperty(
289                    long tagId, java.lang.String key)
290                    throws com.liferay.portal.kernel.exception.PortalException;
291    
292            /**
293            * Returns the asset tag property with the specified ID.
294            *
295            * @param tagPropertyId the primary key of the asset tag property
296            * @return the matching asset tag property
297            * @throws PortalException if an asset tag property with the primary key
298            could not be found
299            */
300            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
301            public com.liferay.portlet.asset.model.AssetTagProperty getTagProperty(
302                    long tagPropertyId)
303                    throws com.liferay.portal.kernel.exception.PortalException;
304    
305            /**
306            * Returns asset tag property keys with the specified group
307            *
308            * @param groupId the primary key of the group
309            * @return the matching asset tag property keys
310            */
311            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
312            public java.lang.String[] getTagPropertyKeys(long groupId);
313    
314            /**
315            * Returns asset tag properties with the specified group and key.
316            *
317            * @param groupId the primary key of the group
318            * @param key the key that refers to some value
319            * @return the matching asset tag properties
320            */
321            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
322            public java.util.List<com.liferay.portlet.asset.model.AssetTagProperty> getTagPropertyValues(
323                    long groupId, java.lang.String key);
324    
325            /**
326            * Sets the Spring bean ID for this bean.
327            *
328            * @param beanIdentifier the Spring bean ID for this bean
329            */
330            public void setBeanIdentifier(java.lang.String beanIdentifier);
331    
332            /**
333            * Updates the asset tag property in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
334            *
335            * @param assetTagProperty the asset tag property
336            * @return the asset tag property that was updated
337            */
338            @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX)
339            public com.liferay.portlet.asset.model.AssetTagProperty updateAssetTagProperty(
340                    com.liferay.portlet.asset.model.AssetTagProperty assetTagProperty);
341    
342            /**
343            * Updates the asset tag property.
344            *
345            * @param tagPropertyId the primary key of the asset tag property
346            * @param key the new key to be associated to the value
347            * @param value the new value to which the key will refer
348            * @return the updated asset tag property
349            * @throws PortalException if an asset tag property with the primary key
350            could not be found, or if the key or value were invalid
351            */
352            public com.liferay.portlet.asset.model.AssetTagProperty updateTagProperty(
353                    long tagPropertyId, java.lang.String key, java.lang.String value)
354                    throws com.liferay.portal.kernel.exception.PortalException;
355    }