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.softwarecatalog.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.softwarecatalog.model.SCLicense; 026 027 import java.util.List; 028 029 /** 030 * The persistence utility for the s c license service. This utility wraps {@link com.liferay.portlet.softwarecatalog.service.persistence.impl.SCLicensePersistenceImpl} 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 SCLicensePersistence 038 * @see com.liferay.portlet.softwarecatalog.service.persistence.impl.SCLicensePersistenceImpl 039 * @generated 040 */ 041 @ProviderType 042 public class SCLicenseUtil { 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(SCLicense scLicense) { 060 getPersistence().clearCache(scLicense); 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<SCLicense> 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<SCLicense> 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<SCLicense> findWithDynamicQuery( 090 DynamicQuery dynamicQuery, int start, int end, 091 OrderByComparator<SCLicense> 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 SCLicense update(SCLicense scLicense) { 101 return getPersistence().update(scLicense); 102 } 103 104 /** 105 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 106 */ 107 public static SCLicense update(SCLicense scLicense, 108 ServiceContext serviceContext) { 109 return getPersistence().update(scLicense, serviceContext); 110 } 111 112 /** 113 * Returns all the s c licenses where active = ?. 114 * 115 * @param active the active 116 * @return the matching s c licenses 117 */ 118 public static List<SCLicense> findByActive(boolean active) { 119 return getPersistence().findByActive(active); 120 } 121 122 /** 123 * Returns a range of all the s c licenses where active = ?. 124 * 125 * <p> 126 * 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 SCLicenseModelImpl}. 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. 127 * </p> 128 * 129 * @param active the active 130 * @param start the lower bound of the range of s c licenses 131 * @param end the upper bound of the range of s c licenses (not inclusive) 132 * @return the range of matching s c licenses 133 */ 134 public static List<SCLicense> findByActive(boolean active, int start, 135 int end) { 136 return getPersistence().findByActive(active, start, end); 137 } 138 139 /** 140 * Returns an ordered range of all the s c licenses where active = ?. 141 * 142 * <p> 143 * 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 SCLicenseModelImpl}. 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. 144 * </p> 145 * 146 * @param active the active 147 * @param start the lower bound of the range of s c licenses 148 * @param end the upper bound of the range of s c licenses (not inclusive) 149 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 150 * @return the ordered range of matching s c licenses 151 */ 152 public static List<SCLicense> findByActive(boolean active, int start, 153 int end, OrderByComparator<SCLicense> orderByComparator) { 154 return getPersistence() 155 .findByActive(active, start, end, orderByComparator); 156 } 157 158 /** 159 * Returns the first s c license in the ordered set where active = ?. 160 * 161 * @param active the active 162 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 163 * @return the first matching s c license 164 * @throws NoSuchLicenseException if a matching s c license could not be found 165 */ 166 public static SCLicense findByActive_First(boolean active, 167 OrderByComparator<SCLicense> orderByComparator) 168 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 169 return getPersistence().findByActive_First(active, orderByComparator); 170 } 171 172 /** 173 * Returns the first s c license in the ordered set where active = ?. 174 * 175 * @param active the active 176 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 177 * @return the first matching s c license, or <code>null</code> if a matching s c license could not be found 178 */ 179 public static SCLicense fetchByActive_First(boolean active, 180 OrderByComparator<SCLicense> orderByComparator) { 181 return getPersistence().fetchByActive_First(active, orderByComparator); 182 } 183 184 /** 185 * Returns the last s c license in the ordered set where active = ?. 186 * 187 * @param active the active 188 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 189 * @return the last matching s c license 190 * @throws NoSuchLicenseException if a matching s c license could not be found 191 */ 192 public static SCLicense findByActive_Last(boolean active, 193 OrderByComparator<SCLicense> orderByComparator) 194 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 195 return getPersistence().findByActive_Last(active, orderByComparator); 196 } 197 198 /** 199 * Returns the last s c license in the ordered set where active = ?. 200 * 201 * @param active the active 202 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 203 * @return the last matching s c license, or <code>null</code> if a matching s c license could not be found 204 */ 205 public static SCLicense fetchByActive_Last(boolean active, 206 OrderByComparator<SCLicense> orderByComparator) { 207 return getPersistence().fetchByActive_Last(active, orderByComparator); 208 } 209 210 /** 211 * Returns the s c licenses before and after the current s c license in the ordered set where active = ?. 212 * 213 * @param licenseId the primary key of the current s c license 214 * @param active the active 215 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 216 * @return the previous, current, and next s c license 217 * @throws NoSuchLicenseException if a s c license with the primary key could not be found 218 */ 219 public static SCLicense[] findByActive_PrevAndNext(long licenseId, 220 boolean active, OrderByComparator<SCLicense> orderByComparator) 221 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 222 return getPersistence() 223 .findByActive_PrevAndNext(licenseId, active, 224 orderByComparator); 225 } 226 227 /** 228 * Returns all the s c licenses that the user has permission to view where active = ?. 229 * 230 * @param active the active 231 * @return the matching s c licenses that the user has permission to view 232 */ 233 public static List<SCLicense> filterFindByActive(boolean active) { 234 return getPersistence().filterFindByActive(active); 235 } 236 237 /** 238 * Returns a range of all the s c licenses that the user has permission to view where active = ?. 239 * 240 * <p> 241 * 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 SCLicenseModelImpl}. 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. 242 * </p> 243 * 244 * @param active the active 245 * @param start the lower bound of the range of s c licenses 246 * @param end the upper bound of the range of s c licenses (not inclusive) 247 * @return the range of matching s c licenses that the user has permission to view 248 */ 249 public static List<SCLicense> filterFindByActive(boolean active, int start, 250 int end) { 251 return getPersistence().filterFindByActive(active, start, end); 252 } 253 254 /** 255 * Returns an ordered range of all the s c licenses that the user has permissions to view where active = ?. 256 * 257 * <p> 258 * 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 SCLicenseModelImpl}. 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. 259 * </p> 260 * 261 * @param active the active 262 * @param start the lower bound of the range of s c licenses 263 * @param end the upper bound of the range of s c licenses (not inclusive) 264 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 265 * @return the ordered range of matching s c licenses that the user has permission to view 266 */ 267 public static List<SCLicense> filterFindByActive(boolean active, int start, 268 int end, OrderByComparator<SCLicense> orderByComparator) { 269 return getPersistence() 270 .filterFindByActive(active, start, end, orderByComparator); 271 } 272 273 /** 274 * Returns the s c licenses before and after the current s c license in the ordered set of s c licenses that the user has permission to view where active = ?. 275 * 276 * @param licenseId the primary key of the current s c license 277 * @param active the active 278 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 279 * @return the previous, current, and next s c license 280 * @throws NoSuchLicenseException if a s c license with the primary key could not be found 281 */ 282 public static SCLicense[] filterFindByActive_PrevAndNext(long licenseId, 283 boolean active, OrderByComparator<SCLicense> orderByComparator) 284 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 285 return getPersistence() 286 .filterFindByActive_PrevAndNext(licenseId, active, 287 orderByComparator); 288 } 289 290 /** 291 * Removes all the s c licenses where active = ? from the database. 292 * 293 * @param active the active 294 */ 295 public static void removeByActive(boolean active) { 296 getPersistence().removeByActive(active); 297 } 298 299 /** 300 * Returns the number of s c licenses where active = ?. 301 * 302 * @param active the active 303 * @return the number of matching s c licenses 304 */ 305 public static int countByActive(boolean active) { 306 return getPersistence().countByActive(active); 307 } 308 309 /** 310 * Returns the number of s c licenses that the user has permission to view where active = ?. 311 * 312 * @param active the active 313 * @return the number of matching s c licenses that the user has permission to view 314 */ 315 public static int filterCountByActive(boolean active) { 316 return getPersistence().filterCountByActive(active); 317 } 318 319 /** 320 * Returns all the s c licenses where active = ? and recommended = ?. 321 * 322 * @param active the active 323 * @param recommended the recommended 324 * @return the matching s c licenses 325 */ 326 public static List<SCLicense> findByA_R(boolean active, boolean recommended) { 327 return getPersistence().findByA_R(active, recommended); 328 } 329 330 /** 331 * Returns a range of all the s c licenses where active = ? and recommended = ?. 332 * 333 * <p> 334 * 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 SCLicenseModelImpl}. 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. 335 * </p> 336 * 337 * @param active the active 338 * @param recommended the recommended 339 * @param start the lower bound of the range of s c licenses 340 * @param end the upper bound of the range of s c licenses (not inclusive) 341 * @return the range of matching s c licenses 342 */ 343 public static List<SCLicense> findByA_R(boolean active, 344 boolean recommended, int start, int end) { 345 return getPersistence().findByA_R(active, recommended, start, end); 346 } 347 348 /** 349 * Returns an ordered range of all the s c licenses where active = ? and recommended = ?. 350 * 351 * <p> 352 * 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 SCLicenseModelImpl}. 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. 353 * </p> 354 * 355 * @param active the active 356 * @param recommended the recommended 357 * @param start the lower bound of the range of s c licenses 358 * @param end the upper bound of the range of s c licenses (not inclusive) 359 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 360 * @return the ordered range of matching s c licenses 361 */ 362 public static List<SCLicense> findByA_R(boolean active, 363 boolean recommended, int start, int end, 364 OrderByComparator<SCLicense> orderByComparator) { 365 return getPersistence() 366 .findByA_R(active, recommended, start, end, orderByComparator); 367 } 368 369 /** 370 * Returns the first s c license in the ordered set where active = ? and recommended = ?. 371 * 372 * @param active the active 373 * @param recommended the recommended 374 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 375 * @return the first matching s c license 376 * @throws NoSuchLicenseException if a matching s c license could not be found 377 */ 378 public static SCLicense findByA_R_First(boolean active, 379 boolean recommended, OrderByComparator<SCLicense> orderByComparator) 380 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 381 return getPersistence() 382 .findByA_R_First(active, recommended, orderByComparator); 383 } 384 385 /** 386 * Returns the first s c license in the ordered set where active = ? and recommended = ?. 387 * 388 * @param active the active 389 * @param recommended the recommended 390 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 391 * @return the first matching s c license, or <code>null</code> if a matching s c license could not be found 392 */ 393 public static SCLicense fetchByA_R_First(boolean active, 394 boolean recommended, OrderByComparator<SCLicense> orderByComparator) { 395 return getPersistence() 396 .fetchByA_R_First(active, recommended, orderByComparator); 397 } 398 399 /** 400 * Returns the last s c license in the ordered set where active = ? and recommended = ?. 401 * 402 * @param active the active 403 * @param recommended the recommended 404 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 405 * @return the last matching s c license 406 * @throws NoSuchLicenseException if a matching s c license could not be found 407 */ 408 public static SCLicense findByA_R_Last(boolean active, boolean recommended, 409 OrderByComparator<SCLicense> orderByComparator) 410 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 411 return getPersistence() 412 .findByA_R_Last(active, recommended, orderByComparator); 413 } 414 415 /** 416 * Returns the last s c license in the ordered set where active = ? and recommended = ?. 417 * 418 * @param active the active 419 * @param recommended the recommended 420 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 421 * @return the last matching s c license, or <code>null</code> if a matching s c license could not be found 422 */ 423 public static SCLicense fetchByA_R_Last(boolean active, 424 boolean recommended, OrderByComparator<SCLicense> orderByComparator) { 425 return getPersistence() 426 .fetchByA_R_Last(active, recommended, orderByComparator); 427 } 428 429 /** 430 * Returns the s c licenses before and after the current s c license in the ordered set where active = ? and recommended = ?. 431 * 432 * @param licenseId the primary key of the current s c license 433 * @param active the active 434 * @param recommended the recommended 435 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 436 * @return the previous, current, and next s c license 437 * @throws NoSuchLicenseException if a s c license with the primary key could not be found 438 */ 439 public static SCLicense[] findByA_R_PrevAndNext(long licenseId, 440 boolean active, boolean recommended, 441 OrderByComparator<SCLicense> orderByComparator) 442 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 443 return getPersistence() 444 .findByA_R_PrevAndNext(licenseId, active, recommended, 445 orderByComparator); 446 } 447 448 /** 449 * Returns all the s c licenses that the user has permission to view where active = ? and recommended = ?. 450 * 451 * @param active the active 452 * @param recommended the recommended 453 * @return the matching s c licenses that the user has permission to view 454 */ 455 public static List<SCLicense> filterFindByA_R(boolean active, 456 boolean recommended) { 457 return getPersistence().filterFindByA_R(active, recommended); 458 } 459 460 /** 461 * Returns a range of all the s c licenses that the user has permission to view where active = ? and recommended = ?. 462 * 463 * <p> 464 * 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 SCLicenseModelImpl}. 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. 465 * </p> 466 * 467 * @param active the active 468 * @param recommended the recommended 469 * @param start the lower bound of the range of s c licenses 470 * @param end the upper bound of the range of s c licenses (not inclusive) 471 * @return the range of matching s c licenses that the user has permission to view 472 */ 473 public static List<SCLicense> filterFindByA_R(boolean active, 474 boolean recommended, int start, int end) { 475 return getPersistence().filterFindByA_R(active, recommended, start, end); 476 } 477 478 /** 479 * Returns an ordered range of all the s c licenses that the user has permissions to view where active = ? and recommended = ?. 480 * 481 * <p> 482 * 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 SCLicenseModelImpl}. 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. 483 * </p> 484 * 485 * @param active the active 486 * @param recommended the recommended 487 * @param start the lower bound of the range of s c licenses 488 * @param end the upper bound of the range of s c licenses (not inclusive) 489 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 490 * @return the ordered range of matching s c licenses that the user has permission to view 491 */ 492 public static List<SCLicense> filterFindByA_R(boolean active, 493 boolean recommended, int start, int end, 494 OrderByComparator<SCLicense> orderByComparator) { 495 return getPersistence() 496 .filterFindByA_R(active, recommended, start, end, 497 orderByComparator); 498 } 499 500 /** 501 * Returns the s c licenses before and after the current s c license in the ordered set of s c licenses that the user has permission to view where active = ? and recommended = ?. 502 * 503 * @param licenseId the primary key of the current s c license 504 * @param active the active 505 * @param recommended the recommended 506 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 507 * @return the previous, current, and next s c license 508 * @throws NoSuchLicenseException if a s c license with the primary key could not be found 509 */ 510 public static SCLicense[] filterFindByA_R_PrevAndNext(long licenseId, 511 boolean active, boolean recommended, 512 OrderByComparator<SCLicense> orderByComparator) 513 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 514 return getPersistence() 515 .filterFindByA_R_PrevAndNext(licenseId, active, recommended, 516 orderByComparator); 517 } 518 519 /** 520 * Removes all the s c licenses where active = ? and recommended = ? from the database. 521 * 522 * @param active the active 523 * @param recommended the recommended 524 */ 525 public static void removeByA_R(boolean active, boolean recommended) { 526 getPersistence().removeByA_R(active, recommended); 527 } 528 529 /** 530 * Returns the number of s c licenses where active = ? and recommended = ?. 531 * 532 * @param active the active 533 * @param recommended the recommended 534 * @return the number of matching s c licenses 535 */ 536 public static int countByA_R(boolean active, boolean recommended) { 537 return getPersistence().countByA_R(active, recommended); 538 } 539 540 /** 541 * Returns the number of s c licenses that the user has permission to view where active = ? and recommended = ?. 542 * 543 * @param active the active 544 * @param recommended the recommended 545 * @return the number of matching s c licenses that the user has permission to view 546 */ 547 public static int filterCountByA_R(boolean active, boolean recommended) { 548 return getPersistence().filterCountByA_R(active, recommended); 549 } 550 551 /** 552 * Caches the s c license in the entity cache if it is enabled. 553 * 554 * @param scLicense the s c license 555 */ 556 public static void cacheResult(SCLicense scLicense) { 557 getPersistence().cacheResult(scLicense); 558 } 559 560 /** 561 * Caches the s c licenses in the entity cache if it is enabled. 562 * 563 * @param scLicenses the s c licenses 564 */ 565 public static void cacheResult(List<SCLicense> scLicenses) { 566 getPersistence().cacheResult(scLicenses); 567 } 568 569 /** 570 * Creates a new s c license with the primary key. Does not add the s c license to the database. 571 * 572 * @param licenseId the primary key for the new s c license 573 * @return the new s c license 574 */ 575 public static SCLicense create(long licenseId) { 576 return getPersistence().create(licenseId); 577 } 578 579 /** 580 * Removes the s c license with the primary key from the database. Also notifies the appropriate model listeners. 581 * 582 * @param licenseId the primary key of the s c license 583 * @return the s c license that was removed 584 * @throws NoSuchLicenseException if a s c license with the primary key could not be found 585 */ 586 public static SCLicense remove(long licenseId) 587 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 588 return getPersistence().remove(licenseId); 589 } 590 591 public static SCLicense updateImpl(SCLicense scLicense) { 592 return getPersistence().updateImpl(scLicense); 593 } 594 595 /** 596 * Returns the s c license with the primary key or throws a {@link NoSuchLicenseException} if it could not be found. 597 * 598 * @param licenseId the primary key of the s c license 599 * @return the s c license 600 * @throws NoSuchLicenseException if a s c license with the primary key could not be found 601 */ 602 public static SCLicense findByPrimaryKey(long licenseId) 603 throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException { 604 return getPersistence().findByPrimaryKey(licenseId); 605 } 606 607 /** 608 * Returns the s c license with the primary key or returns <code>null</code> if it could not be found. 609 * 610 * @param licenseId the primary key of the s c license 611 * @return the s c license, or <code>null</code> if a s c license with the primary key could not be found 612 */ 613 public static SCLicense fetchByPrimaryKey(long licenseId) { 614 return getPersistence().fetchByPrimaryKey(licenseId); 615 } 616 617 public static java.util.Map<java.io.Serializable, SCLicense> fetchByPrimaryKeys( 618 java.util.Set<java.io.Serializable> primaryKeys) { 619 return getPersistence().fetchByPrimaryKeys(primaryKeys); 620 } 621 622 /** 623 * Returns all the s c licenses. 624 * 625 * @return the s c licenses 626 */ 627 public static List<SCLicense> findAll() { 628 return getPersistence().findAll(); 629 } 630 631 /** 632 * Returns a range of all the s c licenses. 633 * 634 * <p> 635 * 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 SCLicenseModelImpl}. 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. 636 * </p> 637 * 638 * @param start the lower bound of the range of s c licenses 639 * @param end the upper bound of the range of s c licenses (not inclusive) 640 * @return the range of s c licenses 641 */ 642 public static List<SCLicense> findAll(int start, int end) { 643 return getPersistence().findAll(start, end); 644 } 645 646 /** 647 * Returns an ordered range of all the s c licenses. 648 * 649 * <p> 650 * 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 SCLicenseModelImpl}. 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. 651 * </p> 652 * 653 * @param start the lower bound of the range of s c licenses 654 * @param end the upper bound of the range of s c licenses (not inclusive) 655 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 656 * @return the ordered range of s c licenses 657 */ 658 public static List<SCLicense> findAll(int start, int end, 659 OrderByComparator<SCLicense> orderByComparator) { 660 return getPersistence().findAll(start, end, orderByComparator); 661 } 662 663 /** 664 * Removes all the s c licenses from the database. 665 */ 666 public static void removeAll() { 667 getPersistence().removeAll(); 668 } 669 670 /** 671 * Returns the number of s c licenses. 672 * 673 * @return the number of s c licenses 674 */ 675 public static int countAll() { 676 return getPersistence().countAll(); 677 } 678 679 /** 680 * Returns the primaryKeys of s c product entries associated with the s c license. 681 * 682 * @param pk the primary key of the s c license 683 * @return long[] of the primaryKeys of s c product entries associated with the s c license 684 */ 685 public static long[] getSCProductEntryPrimaryKeys(long pk) { 686 return getPersistence().getSCProductEntryPrimaryKeys(pk); 687 } 688 689 /** 690 * Returns all the s c product entries associated with the s c license. 691 * 692 * @param pk the primary key of the s c license 693 * @return the s c product entries associated with the s c license 694 */ 695 public static List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> getSCProductEntries( 696 long pk) { 697 return getPersistence().getSCProductEntries(pk); 698 } 699 700 /** 701 * Returns a range of all the s c product entries associated with the s c license. 702 * 703 * <p> 704 * 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 SCLicenseModelImpl}. 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. 705 * </p> 706 * 707 * @param pk the primary key of the s c license 708 * @param start the lower bound of the range of s c licenses 709 * @param end the upper bound of the range of s c licenses (not inclusive) 710 * @return the range of s c product entries associated with the s c license 711 */ 712 public static List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> getSCProductEntries( 713 long pk, int start, int end) { 714 return getPersistence().getSCProductEntries(pk, start, end); 715 } 716 717 /** 718 * Returns an ordered range of all the s c product entries associated with the s c license. 719 * 720 * <p> 721 * 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 SCLicenseModelImpl}. 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. 722 * </p> 723 * 724 * @param pk the primary key of the s c license 725 * @param start the lower bound of the range of s c licenses 726 * @param end the upper bound of the range of s c licenses (not inclusive) 727 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 728 * @return the ordered range of s c product entries associated with the s c license 729 */ 730 public static List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> getSCProductEntries( 731 long pk, int start, int end, 732 OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCProductEntry> orderByComparator) { 733 return getPersistence() 734 .getSCProductEntries(pk, start, end, orderByComparator); 735 } 736 737 /** 738 * Returns the number of s c product entries associated with the s c license. 739 * 740 * @param pk the primary key of the s c license 741 * @return the number of s c product entries associated with the s c license 742 */ 743 public static int getSCProductEntriesSize(long pk) { 744 return getPersistence().getSCProductEntriesSize(pk); 745 } 746 747 /** 748 * Returns <code>true</code> if the s c product entry is associated with the s c license. 749 * 750 * @param pk the primary key of the s c license 751 * @param scProductEntryPK the primary key of the s c product entry 752 * @return <code>true</code> if the s c product entry is associated with the s c license; <code>false</code> otherwise 753 */ 754 public static boolean containsSCProductEntry(long pk, long scProductEntryPK) { 755 return getPersistence().containsSCProductEntry(pk, scProductEntryPK); 756 } 757 758 /** 759 * Returns <code>true</code> if the s c license has any s c product entries associated with it. 760 * 761 * @param pk the primary key of the s c license to check for associations with s c product entries 762 * @return <code>true</code> if the s c license has any s c product entries associated with it; <code>false</code> otherwise 763 */ 764 public static boolean containsSCProductEntries(long pk) { 765 return getPersistence().containsSCProductEntries(pk); 766 } 767 768 /** 769 * Adds an association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache. 770 * 771 * @param pk the primary key of the s c license 772 * @param scProductEntryPK the primary key of the s c product entry 773 */ 774 public static void addSCProductEntry(long pk, long scProductEntryPK) { 775 getPersistence().addSCProductEntry(pk, scProductEntryPK); 776 } 777 778 /** 779 * Adds an association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache. 780 * 781 * @param pk the primary key of the s c license 782 * @param scProductEntry the s c product entry 783 */ 784 public static void addSCProductEntry(long pk, 785 com.liferay.portlet.softwarecatalog.model.SCProductEntry scProductEntry) { 786 getPersistence().addSCProductEntry(pk, scProductEntry); 787 } 788 789 /** 790 * Adds an association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache. 791 * 792 * @param pk the primary key of the s c license 793 * @param scProductEntryPKs the primary keys of the s c product entries 794 */ 795 public static void addSCProductEntries(long pk, long[] scProductEntryPKs) { 796 getPersistence().addSCProductEntries(pk, scProductEntryPKs); 797 } 798 799 /** 800 * Adds an association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache. 801 * 802 * @param pk the primary key of the s c license 803 * @param scProductEntries the s c product entries 804 */ 805 public static void addSCProductEntries(long pk, 806 List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> scProductEntries) { 807 getPersistence().addSCProductEntries(pk, scProductEntries); 808 } 809 810 /** 811 * Clears all associations between the s c license and its s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache. 812 * 813 * @param pk the primary key of the s c license to clear the associated s c product entries from 814 */ 815 public static void clearSCProductEntries(long pk) { 816 getPersistence().clearSCProductEntries(pk); 817 } 818 819 /** 820 * Removes the association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache. 821 * 822 * @param pk the primary key of the s c license 823 * @param scProductEntryPK the primary key of the s c product entry 824 */ 825 public static void removeSCProductEntry(long pk, long scProductEntryPK) { 826 getPersistence().removeSCProductEntry(pk, scProductEntryPK); 827 } 828 829 /** 830 * Removes the association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache. 831 * 832 * @param pk the primary key of the s c license 833 * @param scProductEntry the s c product entry 834 */ 835 public static void removeSCProductEntry(long pk, 836 com.liferay.portlet.softwarecatalog.model.SCProductEntry scProductEntry) { 837 getPersistence().removeSCProductEntry(pk, scProductEntry); 838 } 839 840 /** 841 * Removes the association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache. 842 * 843 * @param pk the primary key of the s c license 844 * @param scProductEntryPKs the primary keys of the s c product entries 845 */ 846 public static void removeSCProductEntries(long pk, long[] scProductEntryPKs) { 847 getPersistence().removeSCProductEntries(pk, scProductEntryPKs); 848 } 849 850 /** 851 * Removes the association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache. 852 * 853 * @param pk the primary key of the s c license 854 * @param scProductEntries the s c product entries 855 */ 856 public static void removeSCProductEntries(long pk, 857 List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> scProductEntries) { 858 getPersistence().removeSCProductEntries(pk, scProductEntries); 859 } 860 861 /** 862 * Sets the s c product entries associated with the s c license, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache. 863 * 864 * @param pk the primary key of the s c license 865 * @param scProductEntryPKs the primary keys of the s c product entries to be associated with the s c license 866 */ 867 public static void setSCProductEntries(long pk, long[] scProductEntryPKs) { 868 getPersistence().setSCProductEntries(pk, scProductEntryPKs); 869 } 870 871 /** 872 * Sets the s c product entries associated with the s c license, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache. 873 * 874 * @param pk the primary key of the s c license 875 * @param scProductEntries the s c product entries to be associated with the s c license 876 */ 877 public static void setSCProductEntries(long pk, 878 List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> scProductEntries) { 879 getPersistence().setSCProductEntries(pk, scProductEntries); 880 } 881 882 public static SCLicensePersistence getPersistence() { 883 if (_persistence == null) { 884 _persistence = (SCLicensePersistence)PortalBeanLocatorUtil.locate(SCLicensePersistence.class.getName()); 885 886 ReferenceRegistry.registerReference(SCLicenseUtil.class, 887 "_persistence"); 888 } 889 890 return _persistence; 891 } 892 893 /** 894 * @deprecated As of 6.2.0 895 */ 896 @Deprecated 897 public void setPersistence(SCLicensePersistence persistence) { 898 } 899 900 private static SCLicensePersistence _persistence; 901 }