001 /** 002 * Copyright (c) 2000-2010 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.persistence; 016 017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil; 018 import com.liferay.portal.kernel.dao.orm.DynamicQuery; 019 import com.liferay.portal.kernel.exception.SystemException; 020 import com.liferay.portal.kernel.util.OrderByComparator; 021 import com.liferay.portal.service.ServiceContext; 022 023 import com.liferay.portlet.asset.model.AssetEntry; 024 025 import java.util.List; 026 027 /** 028 * The persistence utility for the asset entry service. This utility wraps {@link AssetEntryPersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class. 029 * 030 * <p> 031 * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class. 032 * </p> 033 * 034 * <p> 035 * Caching information and settings can be found in <code>portal.properties</code> 036 * </p> 037 * 038 * @author Brian Wing Shun Chan 039 * @see AssetEntryPersistence 040 * @see AssetEntryPersistenceImpl 041 * @generated 042 */ 043 public class AssetEntryUtil { 044 /** 045 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache() 046 */ 047 public static void clearCache() { 048 getPersistence().clearCache(); 049 } 050 051 /** 052 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel) 053 */ 054 public static void clearCache(AssetEntry assetEntry) { 055 getPersistence().clearCache(assetEntry); 056 } 057 058 /** 059 * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 060 */ 061 public long countWithDynamicQuery(DynamicQuery dynamicQuery) 062 throws SystemException { 063 return getPersistence().countWithDynamicQuery(dynamicQuery); 064 } 065 066 /** 067 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 068 */ 069 public static List<AssetEntry> findWithDynamicQuery( 070 DynamicQuery dynamicQuery) throws SystemException { 071 return getPersistence().findWithDynamicQuery(dynamicQuery); 072 } 073 074 /** 075 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 076 */ 077 public static List<AssetEntry> findWithDynamicQuery( 078 DynamicQuery dynamicQuery, int start, int end) 079 throws SystemException { 080 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 081 } 082 083 /** 084 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 085 */ 086 public static List<AssetEntry> findWithDynamicQuery( 087 DynamicQuery dynamicQuery, int start, int end, 088 OrderByComparator orderByComparator) throws SystemException { 089 return getPersistence() 090 .findWithDynamicQuery(dynamicQuery, start, end, 091 orderByComparator); 092 } 093 094 /** 095 * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel) 096 */ 097 public static AssetEntry remove(AssetEntry assetEntry) 098 throws SystemException { 099 return getPersistence().remove(assetEntry); 100 } 101 102 /** 103 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean) 104 */ 105 public static AssetEntry update(AssetEntry assetEntry, boolean merge) 106 throws SystemException { 107 return getPersistence().update(assetEntry, merge); 108 } 109 110 /** 111 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean, ServiceContext) 112 */ 113 public static AssetEntry update(AssetEntry assetEntry, boolean merge, 114 ServiceContext serviceContext) throws SystemException { 115 return getPersistence().update(assetEntry, merge, serviceContext); 116 } 117 118 /** 119 * Caches the asset entry in the entity cache if it is enabled. 120 * 121 * @param assetEntry the asset entry to cache 122 */ 123 public static void cacheResult( 124 com.liferay.portlet.asset.model.AssetEntry assetEntry) { 125 getPersistence().cacheResult(assetEntry); 126 } 127 128 /** 129 * Caches the asset entries in the entity cache if it is enabled. 130 * 131 * @param assetEntries the asset entries to cache 132 */ 133 public static void cacheResult( 134 java.util.List<com.liferay.portlet.asset.model.AssetEntry> assetEntries) { 135 getPersistence().cacheResult(assetEntries); 136 } 137 138 /** 139 * Creates a new asset entry with the primary key. Does not add the asset entry to the database. 140 * 141 * @param entryId the primary key for the new asset entry 142 * @return the new asset entry 143 */ 144 public static com.liferay.portlet.asset.model.AssetEntry create( 145 long entryId) { 146 return getPersistence().create(entryId); 147 } 148 149 /** 150 * Removes the asset entry with the primary key from the database. Also notifies the appropriate model listeners. 151 * 152 * @param entryId the primary key of the asset entry to remove 153 * @return the asset entry that was removed 154 * @throws com.liferay.portlet.asset.NoSuchEntryException if a asset entry with the primary key could not be found 155 * @throws SystemException if a system exception occurred 156 */ 157 public static com.liferay.portlet.asset.model.AssetEntry remove( 158 long entryId) 159 throws com.liferay.portal.kernel.exception.SystemException, 160 com.liferay.portlet.asset.NoSuchEntryException { 161 return getPersistence().remove(entryId); 162 } 163 164 public static com.liferay.portlet.asset.model.AssetEntry updateImpl( 165 com.liferay.portlet.asset.model.AssetEntry assetEntry, boolean merge) 166 throws com.liferay.portal.kernel.exception.SystemException { 167 return getPersistence().updateImpl(assetEntry, merge); 168 } 169 170 /** 171 * Finds the asset entry with the primary key or throws a {@link com.liferay.portlet.asset.NoSuchEntryException} if it could not be found. 172 * 173 * @param entryId the primary key of the asset entry to find 174 * @return the asset entry 175 * @throws com.liferay.portlet.asset.NoSuchEntryException if a asset entry with the primary key could not be found 176 * @throws SystemException if a system exception occurred 177 */ 178 public static com.liferay.portlet.asset.model.AssetEntry findByPrimaryKey( 179 long entryId) 180 throws com.liferay.portal.kernel.exception.SystemException, 181 com.liferay.portlet.asset.NoSuchEntryException { 182 return getPersistence().findByPrimaryKey(entryId); 183 } 184 185 /** 186 * Finds the asset entry with the primary key or returns <code>null</code> if it could not be found. 187 * 188 * @param entryId the primary key of the asset entry to find 189 * @return the asset entry, or <code>null</code> if a asset entry with the primary key could not be found 190 * @throws SystemException if a system exception occurred 191 */ 192 public static com.liferay.portlet.asset.model.AssetEntry fetchByPrimaryKey( 193 long entryId) 194 throws com.liferay.portal.kernel.exception.SystemException { 195 return getPersistence().fetchByPrimaryKey(entryId); 196 } 197 198 /** 199 * Finds all the asset entries where companyId = ?. 200 * 201 * @param companyId the company id to search with 202 * @return the matching asset entries 203 * @throws SystemException if a system exception occurred 204 */ 205 public static java.util.List<com.liferay.portlet.asset.model.AssetEntry> findByCompanyId( 206 long companyId) 207 throws com.liferay.portal.kernel.exception.SystemException { 208 return getPersistence().findByCompanyId(companyId); 209 } 210 211 /** 212 * Finds a range of all the asset entries where companyId = ?. 213 * 214 * <p> 215 * 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. 216 * </p> 217 * 218 * @param companyId the company id to search with 219 * @param start the lower bound of the range of asset entries to return 220 * @param end the upper bound of the range of asset entries to return (not inclusive) 221 * @return the range of matching asset entries 222 * @throws SystemException if a system exception occurred 223 */ 224 public static java.util.List<com.liferay.portlet.asset.model.AssetEntry> findByCompanyId( 225 long companyId, int start, int end) 226 throws com.liferay.portal.kernel.exception.SystemException { 227 return getPersistence().findByCompanyId(companyId, start, end); 228 } 229 230 /** 231 * Finds an ordered range of all the asset entries where companyId = ?. 232 * 233 * <p> 234 * 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. 235 * </p> 236 * 237 * @param companyId the company id to search with 238 * @param start the lower bound of the range of asset entries to return 239 * @param end the upper bound of the range of asset entries to return (not inclusive) 240 * @param orderByComparator the comparator to order the results by 241 * @return the ordered range of matching asset entries 242 * @throws SystemException if a system exception occurred 243 */ 244 public static java.util.List<com.liferay.portlet.asset.model.AssetEntry> findByCompanyId( 245 long companyId, int start, int end, 246 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 247 throws com.liferay.portal.kernel.exception.SystemException { 248 return getPersistence() 249 .findByCompanyId(companyId, start, end, orderByComparator); 250 } 251 252 /** 253 * Finds the first asset entry in the ordered set where companyId = ?. 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. 257 * </p> 258 * 259 * @param companyId the company id to search with 260 * @param orderByComparator the comparator to order the set by 261 * @return the first matching asset entry 262 * @throws com.liferay.portlet.asset.NoSuchEntryException if a matching asset entry could not be found 263 * @throws SystemException if a system exception occurred 264 */ 265 public static com.liferay.portlet.asset.model.AssetEntry findByCompanyId_First( 266 long companyId, 267 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 268 throws com.liferay.portal.kernel.exception.SystemException, 269 com.liferay.portlet.asset.NoSuchEntryException { 270 return getPersistence() 271 .findByCompanyId_First(companyId, orderByComparator); 272 } 273 274 /** 275 * Finds the last asset entry in the ordered set where companyId = ?. 276 * 277 * <p> 278 * 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. 279 * </p> 280 * 281 * @param companyId the company id to search with 282 * @param orderByComparator the comparator to order the set by 283 * @return the last matching asset entry 284 * @throws com.liferay.portlet.asset.NoSuchEntryException if a matching asset entry could not be found 285 * @throws SystemException if a system exception occurred 286 */ 287 public static com.liferay.portlet.asset.model.AssetEntry findByCompanyId_Last( 288 long companyId, 289 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 290 throws com.liferay.portal.kernel.exception.SystemException, 291 com.liferay.portlet.asset.NoSuchEntryException { 292 return getPersistence() 293 .findByCompanyId_Last(companyId, orderByComparator); 294 } 295 296 /** 297 * Finds the asset entries before and after the current asset entry in the ordered set where companyId = ?. 298 * 299 * <p> 300 * 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. 301 * </p> 302 * 303 * @param entryId the primary key of the current asset entry 304 * @param companyId the company id to search with 305 * @param orderByComparator the comparator to order the set by 306 * @return the previous, current, and next asset entry 307 * @throws com.liferay.portlet.asset.NoSuchEntryException if a asset entry with the primary key could not be found 308 * @throws SystemException if a system exception occurred 309 */ 310 public static com.liferay.portlet.asset.model.AssetEntry[] findByCompanyId_PrevAndNext( 311 long entryId, long companyId, 312 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 313 throws com.liferay.portal.kernel.exception.SystemException, 314 com.liferay.portlet.asset.NoSuchEntryException { 315 return getPersistence() 316 .findByCompanyId_PrevAndNext(entryId, companyId, 317 orderByComparator); 318 } 319 320 /** 321 * Finds the asset entry where groupId = ? and classUuid = ? or throws a {@link com.liferay.portlet.asset.NoSuchEntryException} if it could not be found. 322 * 323 * @param groupId the group id to search with 324 * @param classUuid the class uuid to search with 325 * @return the matching asset entry 326 * @throws com.liferay.portlet.asset.NoSuchEntryException if a matching asset entry could not be found 327 * @throws SystemException if a system exception occurred 328 */ 329 public static com.liferay.portlet.asset.model.AssetEntry findByG_CU( 330 long groupId, java.lang.String classUuid) 331 throws com.liferay.portal.kernel.exception.SystemException, 332 com.liferay.portlet.asset.NoSuchEntryException { 333 return getPersistence().findByG_CU(groupId, classUuid); 334 } 335 336 /** 337 * Finds the asset entry where groupId = ? and classUuid = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 338 * 339 * @param groupId the group id to search with 340 * @param classUuid the class uuid to search with 341 * @return the matching asset entry, or <code>null</code> if a matching asset entry could not be found 342 * @throws SystemException if a system exception occurred 343 */ 344 public static com.liferay.portlet.asset.model.AssetEntry fetchByG_CU( 345 long groupId, java.lang.String classUuid) 346 throws com.liferay.portal.kernel.exception.SystemException { 347 return getPersistence().fetchByG_CU(groupId, classUuid); 348 } 349 350 /** 351 * Finds the asset entry where groupId = ? and classUuid = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 352 * 353 * @param groupId the group id to search with 354 * @param classUuid the class uuid to search with 355 * @return the matching asset entry, or <code>null</code> if a matching asset entry could not be found 356 * @throws SystemException if a system exception occurred 357 */ 358 public static com.liferay.portlet.asset.model.AssetEntry fetchByG_CU( 359 long groupId, java.lang.String classUuid, boolean retrieveFromCache) 360 throws com.liferay.portal.kernel.exception.SystemException { 361 return getPersistence() 362 .fetchByG_CU(groupId, classUuid, retrieveFromCache); 363 } 364 365 /** 366 * Finds the asset entry where classNameId = ? and classPK = ? or throws a {@link com.liferay.portlet.asset.NoSuchEntryException} if it could not be found. 367 * 368 * @param classNameId the class name id to search with 369 * @param classPK the class p k to search with 370 * @return the matching asset entry 371 * @throws com.liferay.portlet.asset.NoSuchEntryException if a matching asset entry could not be found 372 * @throws SystemException if a system exception occurred 373 */ 374 public static com.liferay.portlet.asset.model.AssetEntry findByC_C( 375 long classNameId, long classPK) 376 throws com.liferay.portal.kernel.exception.SystemException, 377 com.liferay.portlet.asset.NoSuchEntryException { 378 return getPersistence().findByC_C(classNameId, classPK); 379 } 380 381 /** 382 * Finds the asset entry where classNameId = ? and classPK = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 383 * 384 * @param classNameId the class name id to search with 385 * @param classPK the class p k to search with 386 * @return the matching asset entry, or <code>null</code> if a matching asset entry could not be found 387 * @throws SystemException if a system exception occurred 388 */ 389 public static com.liferay.portlet.asset.model.AssetEntry fetchByC_C( 390 long classNameId, long classPK) 391 throws com.liferay.portal.kernel.exception.SystemException { 392 return getPersistence().fetchByC_C(classNameId, classPK); 393 } 394 395 /** 396 * Finds the asset entry where classNameId = ? and classPK = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 397 * 398 * @param classNameId the class name id to search with 399 * @param classPK the class p k to search with 400 * @return the matching asset entry, or <code>null</code> if a matching asset entry could not be found 401 * @throws SystemException if a system exception occurred 402 */ 403 public static com.liferay.portlet.asset.model.AssetEntry fetchByC_C( 404 long classNameId, long classPK, boolean retrieveFromCache) 405 throws com.liferay.portal.kernel.exception.SystemException { 406 return getPersistence() 407 .fetchByC_C(classNameId, classPK, retrieveFromCache); 408 } 409 410 /** 411 * Finds all the asset entries. 412 * 413 * @return the asset entries 414 * @throws SystemException if a system exception occurred 415 */ 416 public static java.util.List<com.liferay.portlet.asset.model.AssetEntry> findAll() 417 throws com.liferay.portal.kernel.exception.SystemException { 418 return getPersistence().findAll(); 419 } 420 421 /** 422 * Finds a range of all the asset entries. 423 * 424 * <p> 425 * 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. 426 * </p> 427 * 428 * @param start the lower bound of the range of asset entries to return 429 * @param end the upper bound of the range of asset entries to return (not inclusive) 430 * @return the range of asset entries 431 * @throws SystemException if a system exception occurred 432 */ 433 public static java.util.List<com.liferay.portlet.asset.model.AssetEntry> findAll( 434 int start, int end) 435 throws com.liferay.portal.kernel.exception.SystemException { 436 return getPersistence().findAll(start, end); 437 } 438 439 /** 440 * Finds an ordered range of all the asset entries. 441 * 442 * <p> 443 * 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. 444 * </p> 445 * 446 * @param start the lower bound of the range of asset entries to return 447 * @param end the upper bound of the range of asset entries to return (not inclusive) 448 * @param orderByComparator the comparator to order the results by 449 * @return the ordered range of asset entries 450 * @throws SystemException if a system exception occurred 451 */ 452 public static java.util.List<com.liferay.portlet.asset.model.AssetEntry> findAll( 453 int start, int end, 454 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 455 throws com.liferay.portal.kernel.exception.SystemException { 456 return getPersistence().findAll(start, end, orderByComparator); 457 } 458 459 /** 460 * Removes all the asset entries where companyId = ? from the database. 461 * 462 * @param companyId the company id to search with 463 * @throws SystemException if a system exception occurred 464 */ 465 public static void removeByCompanyId(long companyId) 466 throws com.liferay.portal.kernel.exception.SystemException { 467 getPersistence().removeByCompanyId(companyId); 468 } 469 470 /** 471 * Removes the asset entry where groupId = ? and classUuid = ? from the database. 472 * 473 * @param groupId the group id to search with 474 * @param classUuid the class uuid to search with 475 * @throws SystemException if a system exception occurred 476 */ 477 public static void removeByG_CU(long groupId, java.lang.String classUuid) 478 throws com.liferay.portal.kernel.exception.SystemException, 479 com.liferay.portlet.asset.NoSuchEntryException { 480 getPersistence().removeByG_CU(groupId, classUuid); 481 } 482 483 /** 484 * Removes the asset entry where classNameId = ? and classPK = ? from the database. 485 * 486 * @param classNameId the class name id to search with 487 * @param classPK the class p k to search with 488 * @throws SystemException if a system exception occurred 489 */ 490 public static void removeByC_C(long classNameId, long classPK) 491 throws com.liferay.portal.kernel.exception.SystemException, 492 com.liferay.portlet.asset.NoSuchEntryException { 493 getPersistence().removeByC_C(classNameId, classPK); 494 } 495 496 /** 497 * Removes all the asset entries from the database. 498 * 499 * @throws SystemException if a system exception occurred 500 */ 501 public static void removeAll() 502 throws com.liferay.portal.kernel.exception.SystemException { 503 getPersistence().removeAll(); 504 } 505 506 /** 507 * Counts all the asset entries where companyId = ?. 508 * 509 * @param companyId the company id to search with 510 * @return the number of matching asset entries 511 * @throws SystemException if a system exception occurred 512 */ 513 public static int countByCompanyId(long companyId) 514 throws com.liferay.portal.kernel.exception.SystemException { 515 return getPersistence().countByCompanyId(companyId); 516 } 517 518 /** 519 * Counts all the asset entries where groupId = ? and classUuid = ?. 520 * 521 * @param groupId the group id to search with 522 * @param classUuid the class uuid to search with 523 * @return the number of matching asset entries 524 * @throws SystemException if a system exception occurred 525 */ 526 public static int countByG_CU(long groupId, java.lang.String classUuid) 527 throws com.liferay.portal.kernel.exception.SystemException { 528 return getPersistence().countByG_CU(groupId, classUuid); 529 } 530 531 /** 532 * Counts all the asset entries where classNameId = ? and classPK = ?. 533 * 534 * @param classNameId the class name id to search with 535 * @param classPK the class p k to search with 536 * @return the number of matching asset entries 537 * @throws SystemException if a system exception occurred 538 */ 539 public static int countByC_C(long classNameId, long classPK) 540 throws com.liferay.portal.kernel.exception.SystemException { 541 return getPersistence().countByC_C(classNameId, classPK); 542 } 543 544 /** 545 * Counts all the asset entries. 546 * 547 * @return the number of asset entries 548 * @throws SystemException if a system exception occurred 549 */ 550 public static int countAll() 551 throws com.liferay.portal.kernel.exception.SystemException { 552 return getPersistence().countAll(); 553 } 554 555 /** 556 * Gets all the asset categories associated with the asset entry. 557 * 558 * @param pk the primary key of the asset entry to get the associated asset categories for 559 * @return the asset categories associated with the asset entry 560 * @throws SystemException if a system exception occurred 561 */ 562 public static java.util.List<com.liferay.portlet.asset.model.AssetCategory> getAssetCategories( 563 long pk) throws com.liferay.portal.kernel.exception.SystemException { 564 return getPersistence().getAssetCategories(pk); 565 } 566 567 /** 568 * Gets a range of all the asset categories associated with the asset entry. 569 * 570 * <p> 571 * 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. 572 * </p> 573 * 574 * @param pk the primary key of the asset entry to get the associated asset categories for 575 * @param start the lower bound of the range of asset entries to return 576 * @param end the upper bound of the range of asset entries to return (not inclusive) 577 * @return the range of asset categories associated with the asset entry 578 * @throws SystemException if a system exception occurred 579 */ 580 public static java.util.List<com.liferay.portlet.asset.model.AssetCategory> getAssetCategories( 581 long pk, int start, int end) 582 throws com.liferay.portal.kernel.exception.SystemException { 583 return getPersistence().getAssetCategories(pk, start, end); 584 } 585 586 /** 587 * Gets an ordered range of all the asset categories associated with the asset entry. 588 * 589 * <p> 590 * 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. 591 * </p> 592 * 593 * @param pk the primary key of the asset entry to get the associated asset categories for 594 * @param start the lower bound of the range of asset entries to return 595 * @param end the upper bound of the range of asset entries to return (not inclusive) 596 * @param orderByComparator the comparator to order the results by 597 * @return the ordered range of asset categories associated with the asset entry 598 * @throws SystemException if a system exception occurred 599 */ 600 public static java.util.List<com.liferay.portlet.asset.model.AssetCategory> getAssetCategories( 601 long pk, int start, int end, 602 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 603 throws com.liferay.portal.kernel.exception.SystemException { 604 return getPersistence() 605 .getAssetCategories(pk, start, end, orderByComparator); 606 } 607 608 /** 609 * Gets the number of asset categories associated with the asset entry. 610 * 611 * @param pk the primary key of the asset entry to get the number of associated asset categories for 612 * @return the number of asset categories associated with the asset entry 613 * @throws SystemException if a system exception occurred 614 */ 615 public static int getAssetCategoriesSize(long pk) 616 throws com.liferay.portal.kernel.exception.SystemException { 617 return getPersistence().getAssetCategoriesSize(pk); 618 } 619 620 /** 621 * Determines whether the asset category is associated with the asset entry. 622 * 623 * @param pk the primary key of the asset entry 624 * @param assetCategoryPK the primary key of the asset category 625 * @return whether the asset category is associated with the asset entry 626 * @throws SystemException if a system exception occurred 627 */ 628 public static boolean containsAssetCategory(long pk, long assetCategoryPK) 629 throws com.liferay.portal.kernel.exception.SystemException { 630 return getPersistence().containsAssetCategory(pk, assetCategoryPK); 631 } 632 633 /** 634 * Determines whether the asset entry has any asset categories associated with it. 635 * 636 * @param pk the primary key of the asset entry to check for associations with asset categories 637 * @return whether the asset entry has any asset categories associated with it 638 * @throws SystemException if a system exception occurred 639 */ 640 public static boolean containsAssetCategories(long pk) 641 throws com.liferay.portal.kernel.exception.SystemException { 642 return getPersistence().containsAssetCategories(pk); 643 } 644 645 /** 646 * Adds an association between the asset entry and the asset category. Also notifies the appropriate model listeners and clears the mapping table finder cache. 647 * 648 * @param pk the primary key of the asset entry 649 * @param assetCategoryPK the primary key of the asset category 650 * @throws SystemException if a system exception occurred 651 */ 652 public static void addAssetCategory(long pk, long assetCategoryPK) 653 throws com.liferay.portal.kernel.exception.SystemException { 654 getPersistence().addAssetCategory(pk, assetCategoryPK); 655 } 656 657 /** 658 * Adds an association between the asset entry and the asset category. Also notifies the appropriate model listeners and clears the mapping table finder cache. 659 * 660 * @param pk the primary key of the asset entry 661 * @param assetCategory the asset category 662 * @throws SystemException if a system exception occurred 663 */ 664 public static void addAssetCategory(long pk, 665 com.liferay.portlet.asset.model.AssetCategory assetCategory) 666 throws com.liferay.portal.kernel.exception.SystemException { 667 getPersistence().addAssetCategory(pk, assetCategory); 668 } 669 670 /** 671 * Adds an association between the asset entry and the asset categories. Also notifies the appropriate model listeners and clears the mapping table finder cache. 672 * 673 * @param pk the primary key of the asset entry 674 * @param assetCategoryPKs the primary keys of the asset categories 675 * @throws SystemException if a system exception occurred 676 */ 677 public static void addAssetCategories(long pk, long[] assetCategoryPKs) 678 throws com.liferay.portal.kernel.exception.SystemException { 679 getPersistence().addAssetCategories(pk, assetCategoryPKs); 680 } 681 682 /** 683 * Adds an association between the asset entry and the asset categories. Also notifies the appropriate model listeners and clears the mapping table finder cache. 684 * 685 * @param pk the primary key of the asset entry 686 * @param assetCategories the asset categories 687 * @throws SystemException if a system exception occurred 688 */ 689 public static void addAssetCategories(long pk, 690 java.util.List<com.liferay.portlet.asset.model.AssetCategory> assetCategories) 691 throws com.liferay.portal.kernel.exception.SystemException { 692 getPersistence().addAssetCategories(pk, assetCategories); 693 } 694 695 /** 696 * Clears all associations between the asset entry and its asset categories. Also notifies the appropriate model listeners and clears the mapping table finder cache. 697 * 698 * @param pk the primary key of the asset entry to clear the associated asset categories from 699 * @throws SystemException if a system exception occurred 700 */ 701 public static void clearAssetCategories(long pk) 702 throws com.liferay.portal.kernel.exception.SystemException { 703 getPersistence().clearAssetCategories(pk); 704 } 705 706 /** 707 * Removes the association between the asset entry and the asset category. Also notifies the appropriate model listeners and clears the mapping table finder cache. 708 * 709 * @param pk the primary key of the asset entry 710 * @param assetCategoryPK the primary key of the asset category 711 * @throws SystemException if a system exception occurred 712 */ 713 public static void removeAssetCategory(long pk, long assetCategoryPK) 714 throws com.liferay.portal.kernel.exception.SystemException { 715 getPersistence().removeAssetCategory(pk, assetCategoryPK); 716 } 717 718 /** 719 * Removes the association between the asset entry and the asset category. Also notifies the appropriate model listeners and clears the mapping table finder cache. 720 * 721 * @param pk the primary key of the asset entry 722 * @param assetCategory the asset category 723 * @throws SystemException if a system exception occurred 724 */ 725 public static void removeAssetCategory(long pk, 726 com.liferay.portlet.asset.model.AssetCategory assetCategory) 727 throws com.liferay.portal.kernel.exception.SystemException { 728 getPersistence().removeAssetCategory(pk, assetCategory); 729 } 730 731 /** 732 * Removes the association between the asset entry and the asset categories. Also notifies the appropriate model listeners and clears the mapping table finder cache. 733 * 734 * @param pk the primary key of the asset entry 735 * @param assetCategoryPKs the primary keys of the asset categories 736 * @throws SystemException if a system exception occurred 737 */ 738 public static void removeAssetCategories(long pk, long[] assetCategoryPKs) 739 throws com.liferay.portal.kernel.exception.SystemException { 740 getPersistence().removeAssetCategories(pk, assetCategoryPKs); 741 } 742 743 /** 744 * Removes the association between the asset entry and the asset categories. Also notifies the appropriate model listeners and clears the mapping table finder cache. 745 * 746 * @param pk the primary key of the asset entry 747 * @param assetCategories the asset categories 748 * @throws SystemException if a system exception occurred 749 */ 750 public static void removeAssetCategories(long pk, 751 java.util.List<com.liferay.portlet.asset.model.AssetCategory> assetCategories) 752 throws com.liferay.portal.kernel.exception.SystemException { 753 getPersistence().removeAssetCategories(pk, assetCategories); 754 } 755 756 /** 757 * Sets the asset categories associated with the asset entry, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache. 758 * 759 * @param pk the primary key of the asset entry to set the associations for 760 * @param assetCategoryPKs the primary keys of the asset categories to be associated with the asset entry 761 * @throws SystemException if a system exception occurred 762 */ 763 public static void setAssetCategories(long pk, long[] assetCategoryPKs) 764 throws com.liferay.portal.kernel.exception.SystemException { 765 getPersistence().setAssetCategories(pk, assetCategoryPKs); 766 } 767 768 /** 769 * Sets the asset categories associated with the asset entry, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache. 770 * 771 * @param pk the primary key of the asset entry to set the associations for 772 * @param assetCategories the asset categories to be associated with the asset entry 773 * @throws SystemException if a system exception occurred 774 */ 775 public static void setAssetCategories(long pk, 776 java.util.List<com.liferay.portlet.asset.model.AssetCategory> assetCategories) 777 throws com.liferay.portal.kernel.exception.SystemException { 778 getPersistence().setAssetCategories(pk, assetCategories); 779 } 780 781 /** 782 * Gets all the asset tags associated with the asset entry. 783 * 784 * @param pk the primary key of the asset entry to get the associated asset tags for 785 * @return the asset tags associated with the asset entry 786 * @throws SystemException if a system exception occurred 787 */ 788 public static java.util.List<com.liferay.portlet.asset.model.AssetTag> getAssetTags( 789 long pk) throws com.liferay.portal.kernel.exception.SystemException { 790 return getPersistence().getAssetTags(pk); 791 } 792 793 /** 794 * Gets a range of all the asset tags associated with the asset entry. 795 * 796 * <p> 797 * 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. 798 * </p> 799 * 800 * @param pk the primary key of the asset entry to get the associated asset tags for 801 * @param start the lower bound of the range of asset entries to return 802 * @param end the upper bound of the range of asset entries to return (not inclusive) 803 * @return the range of asset tags associated with the asset entry 804 * @throws SystemException if a system exception occurred 805 */ 806 public static java.util.List<com.liferay.portlet.asset.model.AssetTag> getAssetTags( 807 long pk, int start, int end) 808 throws com.liferay.portal.kernel.exception.SystemException { 809 return getPersistence().getAssetTags(pk, start, end); 810 } 811 812 /** 813 * Gets an ordered range of all the asset tags associated with the asset entry. 814 * 815 * <p> 816 * 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. 817 * </p> 818 * 819 * @param pk the primary key of the asset entry to get the associated asset tags for 820 * @param start the lower bound of the range of asset entries to return 821 * @param end the upper bound of the range of asset entries to return (not inclusive) 822 * @param orderByComparator the comparator to order the results by 823 * @return the ordered range of asset tags associated with the asset entry 824 * @throws SystemException if a system exception occurred 825 */ 826 public static java.util.List<com.liferay.portlet.asset.model.AssetTag> getAssetTags( 827 long pk, int start, int end, 828 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 829 throws com.liferay.portal.kernel.exception.SystemException { 830 return getPersistence().getAssetTags(pk, start, end, orderByComparator); 831 } 832 833 /** 834 * Gets the number of asset tags associated with the asset entry. 835 * 836 * @param pk the primary key of the asset entry to get the number of associated asset tags for 837 * @return the number of asset tags associated with the asset entry 838 * @throws SystemException if a system exception occurred 839 */ 840 public static int getAssetTagsSize(long pk) 841 throws com.liferay.portal.kernel.exception.SystemException { 842 return getPersistence().getAssetTagsSize(pk); 843 } 844 845 /** 846 * Determines whether the asset tag is associated with the asset entry. 847 * 848 * @param pk the primary key of the asset entry 849 * @param assetTagPK the primary key of the asset tag 850 * @return whether the asset tag is associated with the asset entry 851 * @throws SystemException if a system exception occurred 852 */ 853 public static boolean containsAssetTag(long pk, long assetTagPK) 854 throws com.liferay.portal.kernel.exception.SystemException { 855 return getPersistence().containsAssetTag(pk, assetTagPK); 856 } 857 858 /** 859 * Determines whether the asset entry has any asset tags associated with it. 860 * 861 * @param pk the primary key of the asset entry to check for associations with asset tags 862 * @return whether the asset entry has any asset tags associated with it 863 * @throws SystemException if a system exception occurred 864 */ 865 public static boolean containsAssetTags(long pk) 866 throws com.liferay.portal.kernel.exception.SystemException { 867 return getPersistence().containsAssetTags(pk); 868 } 869 870 /** 871 * Adds an association between the asset entry and the asset tag. Also notifies the appropriate model listeners and clears the mapping table finder cache. 872 * 873 * @param pk the primary key of the asset entry 874 * @param assetTagPK the primary key of the asset tag 875 * @throws SystemException if a system exception occurred 876 */ 877 public static void addAssetTag(long pk, long assetTagPK) 878 throws com.liferay.portal.kernel.exception.SystemException { 879 getPersistence().addAssetTag(pk, assetTagPK); 880 } 881 882 /** 883 * Adds an association between the asset entry and the asset tag. Also notifies the appropriate model listeners and clears the mapping table finder cache. 884 * 885 * @param pk the primary key of the asset entry 886 * @param assetTag the asset tag 887 * @throws SystemException if a system exception occurred 888 */ 889 public static void addAssetTag(long pk, 890 com.liferay.portlet.asset.model.AssetTag assetTag) 891 throws com.liferay.portal.kernel.exception.SystemException { 892 getPersistence().addAssetTag(pk, assetTag); 893 } 894 895 /** 896 * Adds an association between the asset entry and the asset tags. Also notifies the appropriate model listeners and clears the mapping table finder cache. 897 * 898 * @param pk the primary key of the asset entry 899 * @param assetTagPKs the primary keys of the asset tags 900 * @throws SystemException if a system exception occurred 901 */ 902 public static void addAssetTags(long pk, long[] assetTagPKs) 903 throws com.liferay.portal.kernel.exception.SystemException { 904 getPersistence().addAssetTags(pk, assetTagPKs); 905 } 906 907 /** 908 * Adds an association between the asset entry and the asset tags. Also notifies the appropriate model listeners and clears the mapping table finder cache. 909 * 910 * @param pk the primary key of the asset entry 911 * @param assetTags the asset tags 912 * @throws SystemException if a system exception occurred 913 */ 914 public static void addAssetTags(long pk, 915 java.util.List<com.liferay.portlet.asset.model.AssetTag> assetTags) 916 throws com.liferay.portal.kernel.exception.SystemException { 917 getPersistence().addAssetTags(pk, assetTags); 918 } 919 920 /** 921 * Clears all associations between the asset entry and its asset tags. Also notifies the appropriate model listeners and clears the mapping table finder cache. 922 * 923 * @param pk the primary key of the asset entry to clear the associated asset tags from 924 * @throws SystemException if a system exception occurred 925 */ 926 public static void clearAssetTags(long pk) 927 throws com.liferay.portal.kernel.exception.SystemException { 928 getPersistence().clearAssetTags(pk); 929 } 930 931 /** 932 * Removes the association between the asset entry and the asset tag. Also notifies the appropriate model listeners and clears the mapping table finder cache. 933 * 934 * @param pk the primary key of the asset entry 935 * @param assetTagPK the primary key of the asset tag 936 * @throws SystemException if a system exception occurred 937 */ 938 public static void removeAssetTag(long pk, long assetTagPK) 939 throws com.liferay.portal.kernel.exception.SystemException { 940 getPersistence().removeAssetTag(pk, assetTagPK); 941 } 942 943 /** 944 * Removes the association between the asset entry and the asset tag. Also notifies the appropriate model listeners and clears the mapping table finder cache. 945 * 946 * @param pk the primary key of the asset entry 947 * @param assetTag the asset tag 948 * @throws SystemException if a system exception occurred 949 */ 950 public static void removeAssetTag(long pk, 951 com.liferay.portlet.asset.model.AssetTag assetTag) 952 throws com.liferay.portal.kernel.exception.SystemException { 953 getPersistence().removeAssetTag(pk, assetTag); 954 } 955 956 /** 957 * Removes the association between the asset entry and the asset tags. Also notifies the appropriate model listeners and clears the mapping table finder cache. 958 * 959 * @param pk the primary key of the asset entry 960 * @param assetTagPKs the primary keys of the asset tags 961 * @throws SystemException if a system exception occurred 962 */ 963 public static void removeAssetTags(long pk, long[] assetTagPKs) 964 throws com.liferay.portal.kernel.exception.SystemException { 965 getPersistence().removeAssetTags(pk, assetTagPKs); 966 } 967 968 /** 969 * Removes the association between the asset entry and the asset tags. Also notifies the appropriate model listeners and clears the mapping table finder cache. 970 * 971 * @param pk the primary key of the asset entry 972 * @param assetTags the asset tags 973 * @throws SystemException if a system exception occurred 974 */ 975 public static void removeAssetTags(long pk, 976 java.util.List<com.liferay.portlet.asset.model.AssetTag> assetTags) 977 throws com.liferay.portal.kernel.exception.SystemException { 978 getPersistence().removeAssetTags(pk, assetTags); 979 } 980 981 /** 982 * Sets the asset tags associated with the asset entry, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache. 983 * 984 * @param pk the primary key of the asset entry to set the associations for 985 * @param assetTagPKs the primary keys of the asset tags to be associated with the asset entry 986 * @throws SystemException if a system exception occurred 987 */ 988 public static void setAssetTags(long pk, long[] assetTagPKs) 989 throws com.liferay.portal.kernel.exception.SystemException { 990 getPersistence().setAssetTags(pk, assetTagPKs); 991 } 992 993 /** 994 * Sets the asset tags associated with the asset entry, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache. 995 * 996 * @param pk the primary key of the asset entry to set the associations for 997 * @param assetTags the asset tags to be associated with the asset entry 998 * @throws SystemException if a system exception occurred 999 */ 1000 public static void setAssetTags(long pk, 1001 java.util.List<com.liferay.portlet.asset.model.AssetTag> assetTags) 1002 throws com.liferay.portal.kernel.exception.SystemException { 1003 getPersistence().setAssetTags(pk, assetTags); 1004 } 1005 1006 public static AssetEntryPersistence getPersistence() { 1007 if (_persistence == null) { 1008 _persistence = (AssetEntryPersistence)PortalBeanLocatorUtil.locate(AssetEntryPersistence.class.getName()); 1009 } 1010 1011 return _persistence; 1012 } 1013 1014 public void setPersistence(AssetEntryPersistence persistence) { 1015 _persistence = persistence; 1016 } 1017 1018 private static AssetEntryPersistence _persistence; 1019 }