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.persistence; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil; 020 import com.liferay.portal.kernel.dao.orm.DynamicQuery; 021 import com.liferay.portal.kernel.util.OrderByComparator; 022 import com.liferay.portal.kernel.util.ReferenceRegistry; 023 import com.liferay.portal.service.ServiceContext; 024 025 import com.liferay.portlet.asset.model.AssetCategoryProperty; 026 027 import java.util.List; 028 029 /** 030 * The persistence utility for the asset category property service. This utility wraps {@link com.liferay.portlet.asset.service.persistence.impl.AssetCategoryPropertyPersistenceImpl} 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. 031 * 032 * <p> 033 * Caching information and settings can be found in <code>portal.properties</code> 034 * </p> 035 * 036 * @author Brian Wing Shun Chan 037 * @see AssetCategoryPropertyPersistence 038 * @see com.liferay.portlet.asset.service.persistence.impl.AssetCategoryPropertyPersistenceImpl 039 * @generated 040 */ 041 @ProviderType 042 public class AssetCategoryPropertyUtil { 043 /* 044 * NOTE FOR DEVELOPERS: 045 * 046 * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class. 047 */ 048 049 /** 050 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache() 051 */ 052 public static void clearCache() { 053 getPersistence().clearCache(); 054 } 055 056 /** 057 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel) 058 */ 059 public static void clearCache(AssetCategoryProperty assetCategoryProperty) { 060 getPersistence().clearCache(assetCategoryProperty); 061 } 062 063 /** 064 * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 065 */ 066 public static long countWithDynamicQuery(DynamicQuery dynamicQuery) { 067 return getPersistence().countWithDynamicQuery(dynamicQuery); 068 } 069 070 /** 071 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 072 */ 073 public static List<AssetCategoryProperty> findWithDynamicQuery( 074 DynamicQuery dynamicQuery) { 075 return getPersistence().findWithDynamicQuery(dynamicQuery); 076 } 077 078 /** 079 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 080 */ 081 public static List<AssetCategoryProperty> findWithDynamicQuery( 082 DynamicQuery dynamicQuery, int start, int end) { 083 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 084 } 085 086 /** 087 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 088 */ 089 public static List<AssetCategoryProperty> findWithDynamicQuery( 090 DynamicQuery dynamicQuery, int start, int end, 091 OrderByComparator<AssetCategoryProperty> orderByComparator) { 092 return getPersistence() 093 .findWithDynamicQuery(dynamicQuery, start, end, 094 orderByComparator); 095 } 096 097 /** 098 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel) 099 */ 100 public static AssetCategoryProperty update( 101 AssetCategoryProperty assetCategoryProperty) { 102 return getPersistence().update(assetCategoryProperty); 103 } 104 105 /** 106 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 107 */ 108 public static AssetCategoryProperty update( 109 AssetCategoryProperty assetCategoryProperty, 110 ServiceContext serviceContext) { 111 return getPersistence().update(assetCategoryProperty, serviceContext); 112 } 113 114 /** 115 * Returns all the asset category properties where companyId = ?. 116 * 117 * @param companyId the company ID 118 * @return the matching asset category properties 119 */ 120 public static List<AssetCategoryProperty> findByCompanyId(long companyId) { 121 return getPersistence().findByCompanyId(companyId); 122 } 123 124 /** 125 * Returns a range of all the asset category properties where companyId = ?. 126 * 127 * <p> 128 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 129 * </p> 130 * 131 * @param companyId the company ID 132 * @param start the lower bound of the range of asset category properties 133 * @param end the upper bound of the range of asset category properties (not inclusive) 134 * @return the range of matching asset category properties 135 */ 136 public static List<AssetCategoryProperty> findByCompanyId(long companyId, 137 int start, int end) { 138 return getPersistence().findByCompanyId(companyId, start, end); 139 } 140 141 /** 142 * Returns an ordered range of all the asset category properties where companyId = ?. 143 * 144 * <p> 145 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 146 * </p> 147 * 148 * @param companyId the company ID 149 * @param start the lower bound of the range of asset category properties 150 * @param end the upper bound of the range of asset category properties (not inclusive) 151 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 152 * @return the ordered range of matching asset category properties 153 */ 154 public static List<AssetCategoryProperty> findByCompanyId(long companyId, 155 int start, int end, 156 OrderByComparator<AssetCategoryProperty> orderByComparator) { 157 return getPersistence() 158 .findByCompanyId(companyId, start, end, orderByComparator); 159 } 160 161 /** 162 * Returns the first asset category property in the ordered set where companyId = ?. 163 * 164 * @param companyId the company ID 165 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 166 * @return the first matching asset category property 167 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 168 */ 169 public static AssetCategoryProperty findByCompanyId_First(long companyId, 170 OrderByComparator<AssetCategoryProperty> orderByComparator) 171 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 172 return getPersistence() 173 .findByCompanyId_First(companyId, orderByComparator); 174 } 175 176 /** 177 * Returns the first asset category property in the ordered set where companyId = ?. 178 * 179 * @param companyId the company ID 180 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 181 * @return the first matching asset category property, or <code>null</code> if a matching asset category property could not be found 182 */ 183 public static AssetCategoryProperty fetchByCompanyId_First(long companyId, 184 OrderByComparator<AssetCategoryProperty> orderByComparator) { 185 return getPersistence() 186 .fetchByCompanyId_First(companyId, orderByComparator); 187 } 188 189 /** 190 * Returns the last asset category property in the ordered set where companyId = ?. 191 * 192 * @param companyId the company ID 193 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 194 * @return the last matching asset category property 195 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 196 */ 197 public static AssetCategoryProperty findByCompanyId_Last(long companyId, 198 OrderByComparator<AssetCategoryProperty> orderByComparator) 199 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 200 return getPersistence() 201 .findByCompanyId_Last(companyId, orderByComparator); 202 } 203 204 /** 205 * Returns the last asset category property in the ordered set where companyId = ?. 206 * 207 * @param companyId the company ID 208 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 209 * @return the last matching asset category property, or <code>null</code> if a matching asset category property could not be found 210 */ 211 public static AssetCategoryProperty fetchByCompanyId_Last(long companyId, 212 OrderByComparator<AssetCategoryProperty> orderByComparator) { 213 return getPersistence() 214 .fetchByCompanyId_Last(companyId, orderByComparator); 215 } 216 217 /** 218 * Returns the asset category properties before and after the current asset category property in the ordered set where companyId = ?. 219 * 220 * @param categoryPropertyId the primary key of the current asset category property 221 * @param companyId the company ID 222 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 223 * @return the previous, current, and next asset category property 224 * @throws NoSuchCategoryPropertyException if a asset category property with the primary key could not be found 225 */ 226 public static AssetCategoryProperty[] findByCompanyId_PrevAndNext( 227 long categoryPropertyId, long companyId, 228 OrderByComparator<AssetCategoryProperty> orderByComparator) 229 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 230 return getPersistence() 231 .findByCompanyId_PrevAndNext(categoryPropertyId, companyId, 232 orderByComparator); 233 } 234 235 /** 236 * Removes all the asset category properties where companyId = ? from the database. 237 * 238 * @param companyId the company ID 239 */ 240 public static void removeByCompanyId(long companyId) { 241 getPersistence().removeByCompanyId(companyId); 242 } 243 244 /** 245 * Returns the number of asset category properties where companyId = ?. 246 * 247 * @param companyId the company ID 248 * @return the number of matching asset category properties 249 */ 250 public static int countByCompanyId(long companyId) { 251 return getPersistence().countByCompanyId(companyId); 252 } 253 254 /** 255 * Returns all the asset category properties where categoryId = ?. 256 * 257 * @param categoryId the category ID 258 * @return the matching asset category properties 259 */ 260 public static List<AssetCategoryProperty> findByCategoryId(long categoryId) { 261 return getPersistence().findByCategoryId(categoryId); 262 } 263 264 /** 265 * Returns a range of all the asset category properties where categoryId = ?. 266 * 267 * <p> 268 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 269 * </p> 270 * 271 * @param categoryId the category ID 272 * @param start the lower bound of the range of asset category properties 273 * @param end the upper bound of the range of asset category properties (not inclusive) 274 * @return the range of matching asset category properties 275 */ 276 public static List<AssetCategoryProperty> findByCategoryId( 277 long categoryId, int start, int end) { 278 return getPersistence().findByCategoryId(categoryId, start, end); 279 } 280 281 /** 282 * Returns an ordered range of all the asset category properties where categoryId = ?. 283 * 284 * <p> 285 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 286 * </p> 287 * 288 * @param categoryId the category ID 289 * @param start the lower bound of the range of asset category properties 290 * @param end the upper bound of the range of asset category properties (not inclusive) 291 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 292 * @return the ordered range of matching asset category properties 293 */ 294 public static List<AssetCategoryProperty> findByCategoryId( 295 long categoryId, int start, int end, 296 OrderByComparator<AssetCategoryProperty> orderByComparator) { 297 return getPersistence() 298 .findByCategoryId(categoryId, start, end, orderByComparator); 299 } 300 301 /** 302 * Returns the first asset category property in the ordered set where categoryId = ?. 303 * 304 * @param categoryId the category ID 305 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 306 * @return the first matching asset category property 307 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 308 */ 309 public static AssetCategoryProperty findByCategoryId_First( 310 long categoryId, 311 OrderByComparator<AssetCategoryProperty> orderByComparator) 312 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 313 return getPersistence() 314 .findByCategoryId_First(categoryId, orderByComparator); 315 } 316 317 /** 318 * Returns the first asset category property in the ordered set where categoryId = ?. 319 * 320 * @param categoryId the category ID 321 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 322 * @return the first matching asset category property, or <code>null</code> if a matching asset category property could not be found 323 */ 324 public static AssetCategoryProperty fetchByCategoryId_First( 325 long categoryId, 326 OrderByComparator<AssetCategoryProperty> orderByComparator) { 327 return getPersistence() 328 .fetchByCategoryId_First(categoryId, orderByComparator); 329 } 330 331 /** 332 * Returns the last asset category property in the ordered set where categoryId = ?. 333 * 334 * @param categoryId the category ID 335 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 336 * @return the last matching asset category property 337 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 338 */ 339 public static AssetCategoryProperty findByCategoryId_Last(long categoryId, 340 OrderByComparator<AssetCategoryProperty> orderByComparator) 341 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 342 return getPersistence() 343 .findByCategoryId_Last(categoryId, orderByComparator); 344 } 345 346 /** 347 * Returns the last asset category property in the ordered set where categoryId = ?. 348 * 349 * @param categoryId the category ID 350 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 351 * @return the last matching asset category property, or <code>null</code> if a matching asset category property could not be found 352 */ 353 public static AssetCategoryProperty fetchByCategoryId_Last( 354 long categoryId, 355 OrderByComparator<AssetCategoryProperty> orderByComparator) { 356 return getPersistence() 357 .fetchByCategoryId_Last(categoryId, orderByComparator); 358 } 359 360 /** 361 * Returns the asset category properties before and after the current asset category property in the ordered set where categoryId = ?. 362 * 363 * @param categoryPropertyId the primary key of the current asset category property 364 * @param categoryId the category ID 365 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 366 * @return the previous, current, and next asset category property 367 * @throws NoSuchCategoryPropertyException if a asset category property with the primary key could not be found 368 */ 369 public static AssetCategoryProperty[] findByCategoryId_PrevAndNext( 370 long categoryPropertyId, long categoryId, 371 OrderByComparator<AssetCategoryProperty> orderByComparator) 372 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 373 return getPersistence() 374 .findByCategoryId_PrevAndNext(categoryPropertyId, 375 categoryId, orderByComparator); 376 } 377 378 /** 379 * Removes all the asset category properties where categoryId = ? from the database. 380 * 381 * @param categoryId the category ID 382 */ 383 public static void removeByCategoryId(long categoryId) { 384 getPersistence().removeByCategoryId(categoryId); 385 } 386 387 /** 388 * Returns the number of asset category properties where categoryId = ?. 389 * 390 * @param categoryId the category ID 391 * @return the number of matching asset category properties 392 */ 393 public static int countByCategoryId(long categoryId) { 394 return getPersistence().countByCategoryId(categoryId); 395 } 396 397 /** 398 * Returns all the asset category properties where companyId = ? and key = ?. 399 * 400 * @param companyId the company ID 401 * @param key the key 402 * @return the matching asset category properties 403 */ 404 public static List<AssetCategoryProperty> findByC_K(long companyId, 405 java.lang.String key) { 406 return getPersistence().findByC_K(companyId, key); 407 } 408 409 /** 410 * Returns a range of all the asset category properties where companyId = ? and key = ?. 411 * 412 * <p> 413 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 414 * </p> 415 * 416 * @param companyId the company ID 417 * @param key the key 418 * @param start the lower bound of the range of asset category properties 419 * @param end the upper bound of the range of asset category properties (not inclusive) 420 * @return the range of matching asset category properties 421 */ 422 public static List<AssetCategoryProperty> findByC_K(long companyId, 423 java.lang.String key, int start, int end) { 424 return getPersistence().findByC_K(companyId, key, start, end); 425 } 426 427 /** 428 * Returns an ordered range of all the asset category properties where companyId = ? and key = ?. 429 * 430 * <p> 431 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 432 * </p> 433 * 434 * @param companyId the company ID 435 * @param key the key 436 * @param start the lower bound of the range of asset category properties 437 * @param end the upper bound of the range of asset category properties (not inclusive) 438 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 439 * @return the ordered range of matching asset category properties 440 */ 441 public static List<AssetCategoryProperty> findByC_K(long companyId, 442 java.lang.String key, int start, int end, 443 OrderByComparator<AssetCategoryProperty> orderByComparator) { 444 return getPersistence() 445 .findByC_K(companyId, key, start, end, orderByComparator); 446 } 447 448 /** 449 * Returns the first asset category property in the ordered set where companyId = ? and key = ?. 450 * 451 * @param companyId the company ID 452 * @param key the key 453 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 454 * @return the first matching asset category property 455 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 456 */ 457 public static AssetCategoryProperty findByC_K_First(long companyId, 458 java.lang.String key, 459 OrderByComparator<AssetCategoryProperty> orderByComparator) 460 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 461 return getPersistence() 462 .findByC_K_First(companyId, key, orderByComparator); 463 } 464 465 /** 466 * Returns the first asset category property in the ordered set where companyId = ? and key = ?. 467 * 468 * @param companyId the company ID 469 * @param key the key 470 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 471 * @return the first matching asset category property, or <code>null</code> if a matching asset category property could not be found 472 */ 473 public static AssetCategoryProperty fetchByC_K_First(long companyId, 474 java.lang.String key, 475 OrderByComparator<AssetCategoryProperty> orderByComparator) { 476 return getPersistence() 477 .fetchByC_K_First(companyId, key, orderByComparator); 478 } 479 480 /** 481 * Returns the last asset category property in the ordered set where companyId = ? and key = ?. 482 * 483 * @param companyId the company ID 484 * @param key the key 485 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 486 * @return the last matching asset category property 487 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 488 */ 489 public static AssetCategoryProperty findByC_K_Last(long companyId, 490 java.lang.String key, 491 OrderByComparator<AssetCategoryProperty> orderByComparator) 492 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 493 return getPersistence().findByC_K_Last(companyId, key, orderByComparator); 494 } 495 496 /** 497 * Returns the last asset category property in the ordered set where companyId = ? and key = ?. 498 * 499 * @param companyId the company ID 500 * @param key the key 501 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 502 * @return the last matching asset category property, or <code>null</code> if a matching asset category property could not be found 503 */ 504 public static AssetCategoryProperty fetchByC_K_Last(long companyId, 505 java.lang.String key, 506 OrderByComparator<AssetCategoryProperty> orderByComparator) { 507 return getPersistence() 508 .fetchByC_K_Last(companyId, key, orderByComparator); 509 } 510 511 /** 512 * Returns the asset category properties before and after the current asset category property in the ordered set where companyId = ? and key = ?. 513 * 514 * @param categoryPropertyId the primary key of the current asset category property 515 * @param companyId the company ID 516 * @param key the key 517 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 518 * @return the previous, current, and next asset category property 519 * @throws NoSuchCategoryPropertyException if a asset category property with the primary key could not be found 520 */ 521 public static AssetCategoryProperty[] findByC_K_PrevAndNext( 522 long categoryPropertyId, long companyId, java.lang.String key, 523 OrderByComparator<AssetCategoryProperty> orderByComparator) 524 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 525 return getPersistence() 526 .findByC_K_PrevAndNext(categoryPropertyId, companyId, key, 527 orderByComparator); 528 } 529 530 /** 531 * Removes all the asset category properties where companyId = ? and key = ? from the database. 532 * 533 * @param companyId the company ID 534 * @param key the key 535 */ 536 public static void removeByC_K(long companyId, java.lang.String key) { 537 getPersistence().removeByC_K(companyId, key); 538 } 539 540 /** 541 * Returns the number of asset category properties where companyId = ? and key = ?. 542 * 543 * @param companyId the company ID 544 * @param key the key 545 * @return the number of matching asset category properties 546 */ 547 public static int countByC_K(long companyId, java.lang.String key) { 548 return getPersistence().countByC_K(companyId, key); 549 } 550 551 /** 552 * Returns the asset category property where categoryId = ? and key = ? or throws a {@link NoSuchCategoryPropertyException} if it could not be found. 553 * 554 * @param categoryId the category ID 555 * @param key the key 556 * @return the matching asset category property 557 * @throws NoSuchCategoryPropertyException if a matching asset category property could not be found 558 */ 559 public static AssetCategoryProperty findByCA_K(long categoryId, 560 java.lang.String key) 561 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 562 return getPersistence().findByCA_K(categoryId, key); 563 } 564 565 /** 566 * Returns the asset category property where categoryId = ? and key = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 567 * 568 * @param categoryId the category ID 569 * @param key the key 570 * @return the matching asset category property, or <code>null</code> if a matching asset category property could not be found 571 */ 572 public static AssetCategoryProperty fetchByCA_K(long categoryId, 573 java.lang.String key) { 574 return getPersistence().fetchByCA_K(categoryId, key); 575 } 576 577 /** 578 * Returns the asset category property where categoryId = ? and key = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 579 * 580 * @param categoryId the category ID 581 * @param key the key 582 * @param retrieveFromCache whether to use the finder cache 583 * @return the matching asset category property, or <code>null</code> if a matching asset category property could not be found 584 */ 585 public static AssetCategoryProperty fetchByCA_K(long categoryId, 586 java.lang.String key, boolean retrieveFromCache) { 587 return getPersistence().fetchByCA_K(categoryId, key, retrieveFromCache); 588 } 589 590 /** 591 * Removes the asset category property where categoryId = ? and key = ? from the database. 592 * 593 * @param categoryId the category ID 594 * @param key the key 595 * @return the asset category property that was removed 596 */ 597 public static AssetCategoryProperty removeByCA_K(long categoryId, 598 java.lang.String key) 599 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 600 return getPersistence().removeByCA_K(categoryId, key); 601 } 602 603 /** 604 * Returns the number of asset category properties where categoryId = ? and key = ?. 605 * 606 * @param categoryId the category ID 607 * @param key the key 608 * @return the number of matching asset category properties 609 */ 610 public static int countByCA_K(long categoryId, java.lang.String key) { 611 return getPersistence().countByCA_K(categoryId, key); 612 } 613 614 /** 615 * Caches the asset category property in the entity cache if it is enabled. 616 * 617 * @param assetCategoryProperty the asset category property 618 */ 619 public static void cacheResult(AssetCategoryProperty assetCategoryProperty) { 620 getPersistence().cacheResult(assetCategoryProperty); 621 } 622 623 /** 624 * Caches the asset category properties in the entity cache if it is enabled. 625 * 626 * @param assetCategoryProperties the asset category properties 627 */ 628 public static void cacheResult( 629 List<AssetCategoryProperty> assetCategoryProperties) { 630 getPersistence().cacheResult(assetCategoryProperties); 631 } 632 633 /** 634 * Creates a new asset category property with the primary key. Does not add the asset category property to the database. 635 * 636 * @param categoryPropertyId the primary key for the new asset category property 637 * @return the new asset category property 638 */ 639 public static AssetCategoryProperty create(long categoryPropertyId) { 640 return getPersistence().create(categoryPropertyId); 641 } 642 643 /** 644 * Removes the asset category property with the primary key from the database. Also notifies the appropriate model listeners. 645 * 646 * @param categoryPropertyId the primary key of the asset category property 647 * @return the asset category property that was removed 648 * @throws NoSuchCategoryPropertyException if a asset category property with the primary key could not be found 649 */ 650 public static AssetCategoryProperty remove(long categoryPropertyId) 651 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 652 return getPersistence().remove(categoryPropertyId); 653 } 654 655 public static AssetCategoryProperty updateImpl( 656 AssetCategoryProperty assetCategoryProperty) { 657 return getPersistence().updateImpl(assetCategoryProperty); 658 } 659 660 /** 661 * Returns the asset category property with the primary key or throws a {@link NoSuchCategoryPropertyException} if it could not be found. 662 * 663 * @param categoryPropertyId the primary key of the asset category property 664 * @return the asset category property 665 * @throws NoSuchCategoryPropertyException if a asset category property with the primary key could not be found 666 */ 667 public static AssetCategoryProperty findByPrimaryKey( 668 long categoryPropertyId) 669 throws com.liferay.portlet.asset.NoSuchCategoryPropertyException { 670 return getPersistence().findByPrimaryKey(categoryPropertyId); 671 } 672 673 /** 674 * Returns the asset category property with the primary key or returns <code>null</code> if it could not be found. 675 * 676 * @param categoryPropertyId the primary key of the asset category property 677 * @return the asset category property, or <code>null</code> if a asset category property with the primary key could not be found 678 */ 679 public static AssetCategoryProperty fetchByPrimaryKey( 680 long categoryPropertyId) { 681 return getPersistence().fetchByPrimaryKey(categoryPropertyId); 682 } 683 684 public static java.util.Map<java.io.Serializable, AssetCategoryProperty> fetchByPrimaryKeys( 685 java.util.Set<java.io.Serializable> primaryKeys) { 686 return getPersistence().fetchByPrimaryKeys(primaryKeys); 687 } 688 689 /** 690 * Returns all the asset category properties. 691 * 692 * @return the asset category properties 693 */ 694 public static List<AssetCategoryProperty> findAll() { 695 return getPersistence().findAll(); 696 } 697 698 /** 699 * Returns a range of all the asset category properties. 700 * 701 * <p> 702 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 703 * </p> 704 * 705 * @param start the lower bound of the range of asset category properties 706 * @param end the upper bound of the range of asset category properties (not inclusive) 707 * @return the range of asset category properties 708 */ 709 public static List<AssetCategoryProperty> findAll(int start, int end) { 710 return getPersistence().findAll(start, end); 711 } 712 713 /** 714 * Returns an ordered range of all the asset category properties. 715 * 716 * <p> 717 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link AssetCategoryPropertyModelImpl}. 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. 718 * </p> 719 * 720 * @param start the lower bound of the range of asset category properties 721 * @param end the upper bound of the range of asset category properties (not inclusive) 722 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 723 * @return the ordered range of asset category properties 724 */ 725 public static List<AssetCategoryProperty> findAll(int start, int end, 726 OrderByComparator<AssetCategoryProperty> orderByComparator) { 727 return getPersistence().findAll(start, end, orderByComparator); 728 } 729 730 /** 731 * Removes all the asset category properties from the database. 732 */ 733 public static void removeAll() { 734 getPersistence().removeAll(); 735 } 736 737 /** 738 * Returns the number of asset category properties. 739 * 740 * @return the number of asset category properties 741 */ 742 public static int countAll() { 743 return getPersistence().countAll(); 744 } 745 746 public static AssetCategoryPropertyPersistence getPersistence() { 747 if (_persistence == null) { 748 _persistence = (AssetCategoryPropertyPersistence)PortalBeanLocatorUtil.locate(AssetCategoryPropertyPersistence.class.getName()); 749 750 ReferenceRegistry.registerReference(AssetCategoryPropertyUtil.class, 751 "_persistence"); 752 } 753 754 return _persistence; 755 } 756 757 /** 758 * @deprecated As of 6.2.0 759 */ 760 @Deprecated 761 public void setPersistence(AssetCategoryPropertyPersistence persistence) { 762 } 763 764 private static AssetCategoryPropertyPersistence _persistence; 765 }