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 AssetTagStats. 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 AssetTagStatsLocalServiceUtil 036 * @see com.liferay.portlet.asset.service.base.AssetTagStatsLocalServiceBaseImpl 037 * @see com.liferay.portlet.asset.service.impl.AssetTagStatsLocalServiceImpl 038 * @generated 039 */ 040 @ProviderType 041 @Transactional(isolation = Isolation.PORTAL, rollbackFor = { 042 PortalException.class, SystemException.class}) 043 public interface AssetTagStatsLocalService extends BaseLocalService, 044 PersistedModelLocalService { 045 /* 046 * NOTE FOR DEVELOPERS: 047 * 048 * Never modify or reference this interface directly. Always use {@link AssetTagStatsLocalServiceUtil} to access the asset tag stats local service. Add custom service methods to {@link com.liferay.portlet.asset.service.impl.AssetTagStatsLocalServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface. 049 */ 050 051 /** 052 * Adds the asset tag stats to the database. Also notifies the appropriate model listeners. 053 * 054 * @param assetTagStats the asset tag stats 055 * @return the asset tag stats that was added 056 */ 057 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 058 public com.liferay.portlet.asset.model.AssetTagStats addAssetTagStats( 059 com.liferay.portlet.asset.model.AssetTagStats assetTagStats); 060 061 /** 062 * Adds an asset tag statistics instance. 063 * 064 * @param tagId the primary key of the tag 065 * @param classNameId the asset entry's class name ID 066 * @return the asset tag statistics instance 067 */ 068 public com.liferay.portlet.asset.model.AssetTagStats addTagStats( 069 long tagId, long classNameId); 070 071 /** 072 * Creates a new asset tag stats with the primary key. Does not add the asset tag stats to the database. 073 * 074 * @param tagStatsId the primary key for the new asset tag stats 075 * @return the new asset tag stats 076 */ 077 public com.liferay.portlet.asset.model.AssetTagStats createAssetTagStats( 078 long tagStatsId); 079 080 /** 081 * Deletes the asset tag stats from the database. Also notifies the appropriate model listeners. 082 * 083 * @param assetTagStats the asset tag stats 084 * @return the asset tag stats that was removed 085 */ 086 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 087 public com.liferay.portlet.asset.model.AssetTagStats deleteAssetTagStats( 088 com.liferay.portlet.asset.model.AssetTagStats assetTagStats); 089 090 /** 091 * Deletes the asset tag stats with the primary key from the database. Also notifies the appropriate model listeners. 092 * 093 * @param tagStatsId the primary key of the asset tag stats 094 * @return the asset tag stats that was removed 095 * @throws PortalException if a asset tag stats with the primary key could not be found 096 */ 097 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 098 public com.liferay.portlet.asset.model.AssetTagStats deleteAssetTagStats( 099 long tagStatsId) 100 throws com.liferay.portal.kernel.exception.PortalException; 101 102 /** 103 * @throws PortalException 104 */ 105 @Override 106 public com.liferay.portal.model.PersistedModel deletePersistedModel( 107 com.liferay.portal.model.PersistedModel persistedModel) 108 throws com.liferay.portal.kernel.exception.PortalException; 109 110 /** 111 * Deletes the asset tag statistics instance. 112 * 113 * @param tagStats the asset tag statistics instance 114 */ 115 public void deleteTagStats( 116 com.liferay.portlet.asset.model.AssetTagStats tagStats); 117 118 /** 119 * Deletes the asset tag statistics instance matching the tag statistics ID. 120 * 121 * @param tagStatsId the primary key of the asset tag statistics instance 122 * @throws PortalException if the assetTagStats with the primary key could 123 not be found 124 */ 125 public void deleteTagStats(long tagStatsId) 126 throws com.liferay.portal.kernel.exception.PortalException; 127 128 /** 129 * Deletes all asset tag statistics instances associated with the asset 130 * entry matching the class name ID. 131 * 132 * @param classNameId the asset entry's class name ID 133 */ 134 public void deleteTagStatsByClassNameId(long classNameId); 135 136 /** 137 * Deletes all asset tag statistics instances associated with the tag. 138 * 139 * @param tagId the primary key of the tag 140 */ 141 public void deleteTagStatsByTagId(long tagId); 142 143 public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery(); 144 145 /** 146 * Performs a dynamic query on the database and returns the matching rows. 147 * 148 * @param dynamicQuery the dynamic query 149 * @return the matching rows 150 */ 151 public <T> java.util.List<T> dynamicQuery( 152 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery); 153 154 /** 155 * Performs a dynamic query on the database and returns a range of the matching rows. 156 * 157 * <p> 158 * 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. 159 * </p> 160 * 161 * @param dynamicQuery the dynamic query 162 * @param start the lower bound of the range of model instances 163 * @param end the upper bound of the range of model instances (not inclusive) 164 * @return the range of matching rows 165 */ 166 public <T> java.util.List<T> dynamicQuery( 167 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 168 int end); 169 170 /** 171 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 172 * 173 * <p> 174 * 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. 175 * </p> 176 * 177 * @param dynamicQuery the dynamic query 178 * @param start the lower bound of the range of model instances 179 * @param end the upper bound of the range of model instances (not inclusive) 180 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 181 * @return the ordered range of matching rows 182 */ 183 public <T> java.util.List<T> dynamicQuery( 184 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 185 int end, 186 com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator); 187 188 /** 189 * Returns the number of rows matching the dynamic query. 190 * 191 * @param dynamicQuery the dynamic query 192 * @return the number of rows matching the dynamic query 193 */ 194 public long dynamicQueryCount( 195 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery); 196 197 /** 198 * Returns the number of rows matching the dynamic query. 199 * 200 * @param dynamicQuery the dynamic query 201 * @param projection the projection to apply to the query 202 * @return the number of rows matching the dynamic query 203 */ 204 public long dynamicQueryCount( 205 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, 206 com.liferay.portal.kernel.dao.orm.Projection projection); 207 208 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 209 public com.liferay.portlet.asset.model.AssetTagStats fetchAssetTagStats( 210 long tagStatsId); 211 212 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 213 public com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery(); 214 215 /** 216 * Returns the asset tag stats with the primary key. 217 * 218 * @param tagStatsId the primary key of the asset tag stats 219 * @return the asset tag stats 220 * @throws PortalException if a asset tag stats with the primary key could not be found 221 */ 222 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 223 public com.liferay.portlet.asset.model.AssetTagStats getAssetTagStats( 224 long tagStatsId) 225 throws com.liferay.portal.kernel.exception.PortalException; 226 227 /** 228 * Returns a range of all the asset tag statses. 229 * 230 * <p> 231 * 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. 232 * </p> 233 * 234 * @param start the lower bound of the range of asset tag statses 235 * @param end the upper bound of the range of asset tag statses (not inclusive) 236 * @return the range of asset tag statses 237 */ 238 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 239 public java.util.List<com.liferay.portlet.asset.model.AssetTagStats> getAssetTagStatses( 240 int start, int end); 241 242 /** 243 * Returns the number of asset tag statses. 244 * 245 * @return the number of asset tag statses 246 */ 247 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 248 public int getAssetTagStatsesCount(); 249 250 /** 251 * Returns the Spring bean ID for this bean. 252 * 253 * @return the Spring bean ID for this bean 254 */ 255 public java.lang.String getBeanIdentifier(); 256 257 @Override 258 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 259 public com.liferay.portal.model.PersistedModel getPersistedModel( 260 java.io.Serializable primaryKeyObj) 261 throws com.liferay.portal.kernel.exception.PortalException; 262 263 /** 264 * Returns a range of all the asset tag statistics instances associated with 265 * the asset entry matching the class name ID. 266 * 267 * <p> 268 * Useful when paginating results. Returns a maximum of <code>end - 269 * start</code> instances. <code>start</code> and <code>end</code> are not 270 * primary keys, they are indexes in the result set. Thus, <code>0</code> 271 * refers to the first result in the set. Setting both <code>start</code> 272 * and <code>end</code> to {@link 273 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 274 * result set. 275 * </p> 276 * 277 * @param classNameId the asset entry's class name ID 278 * @param start the lower bound of the range of results 279 * @param end the upper bound of the range of results (not inclusive) 280 * @return the range of asset tag statistics associated with the asset entry 281 matching the class name ID 282 */ 283 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 284 public java.util.List<com.liferay.portlet.asset.model.AssetTagStats> getTagStats( 285 long classNameId, int start, int end); 286 287 /** 288 * Returns the asset tag statistics instance with the tag and asset entry 289 * matching the class name ID 290 * 291 * @param tagId the primary key of the tag 292 * @param classNameId the asset entry's class name ID 293 * @return Returns the asset tag statistics instance with the tag and asset 294 entry matching the class name ID 295 */ 296 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 297 public com.liferay.portlet.asset.model.AssetTagStats getTagStats( 298 long tagId, long classNameId); 299 300 /** 301 * Sets the Spring bean ID for this bean. 302 * 303 * @param beanIdentifier the Spring bean ID for this bean 304 */ 305 public void setBeanIdentifier(java.lang.String beanIdentifier); 306 307 /** 308 * Updates the asset tag stats in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 309 * 310 * @param assetTagStats the asset tag stats 311 * @return the asset tag stats that was updated 312 */ 313 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 314 public com.liferay.portlet.asset.model.AssetTagStats updateAssetTagStats( 315 com.liferay.portlet.asset.model.AssetTagStats assetTagStats); 316 317 /** 318 * Updates the asset tag statistics instance. 319 * 320 * @param tagId the primary key of the tag 321 * @param classNameId the asset entry's class name ID 322 * @return the updated asset tag statistics instance 323 * @throws PortalException if an asset tag with the tag ID could not be 324 found 325 */ 326 public com.liferay.portlet.asset.model.AssetTagStats updateTagStats( 327 long tagId, long classNameId) 328 throws com.liferay.portal.kernel.exception.PortalException; 329 }