001 /** 002 * Copyright (c) 2000-2013 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.exception.SystemException; 022 import com.liferay.portal.kernel.util.OrderByComparator; 023 import com.liferay.portal.kernel.util.ReferenceRegistry; 024 import com.liferay.portal.service.ServiceContext; 025 026 import com.liferay.portlet.softwarecatalog.model.SCProductScreenshot; 027 028 import java.util.List; 029 030 /** 031 * The persistence utility for the s c product screenshot service. This utility wraps {@link SCProductScreenshotPersistenceImpl} 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. 032 * 033 * <p> 034 * Caching information and settings can be found in <code>portal.properties</code> 035 * </p> 036 * 037 * @author Brian Wing Shun Chan 038 * @see SCProductScreenshotPersistence 039 * @see SCProductScreenshotPersistenceImpl 040 * @generated 041 */ 042 @ProviderType 043 public class SCProductScreenshotUtil { 044 /* 045 * NOTE FOR DEVELOPERS: 046 * 047 * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class. 048 */ 049 050 /** 051 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache() 052 */ 053 public static void clearCache() { 054 getPersistence().clearCache(); 055 } 056 057 /** 058 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel) 059 */ 060 public static void clearCache(SCProductScreenshot scProductScreenshot) { 061 getPersistence().clearCache(scProductScreenshot); 062 } 063 064 /** 065 * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 066 */ 067 public static long countWithDynamicQuery(DynamicQuery dynamicQuery) 068 throws SystemException { 069 return getPersistence().countWithDynamicQuery(dynamicQuery); 070 } 071 072 /** 073 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 074 */ 075 public static List<SCProductScreenshot> findWithDynamicQuery( 076 DynamicQuery dynamicQuery) throws SystemException { 077 return getPersistence().findWithDynamicQuery(dynamicQuery); 078 } 079 080 /** 081 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 082 */ 083 public static List<SCProductScreenshot> findWithDynamicQuery( 084 DynamicQuery dynamicQuery, int start, int end) 085 throws SystemException { 086 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 087 } 088 089 /** 090 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 091 */ 092 public static List<SCProductScreenshot> findWithDynamicQuery( 093 DynamicQuery dynamicQuery, int start, int end, 094 OrderByComparator orderByComparator) throws SystemException { 095 return getPersistence() 096 .findWithDynamicQuery(dynamicQuery, start, end, 097 orderByComparator); 098 } 099 100 /** 101 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel) 102 */ 103 public static SCProductScreenshot update( 104 SCProductScreenshot scProductScreenshot) throws SystemException { 105 return getPersistence().update(scProductScreenshot); 106 } 107 108 /** 109 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 110 */ 111 public static SCProductScreenshot update( 112 SCProductScreenshot scProductScreenshot, ServiceContext serviceContext) 113 throws SystemException { 114 return getPersistence().update(scProductScreenshot, serviceContext); 115 } 116 117 /** 118 * Returns all the s c product screenshots where productEntryId = ?. 119 * 120 * @param productEntryId the product entry ID 121 * @return the matching s c product screenshots 122 * @throws SystemException if a system exception occurred 123 */ 124 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> findByProductEntryId( 125 long productEntryId) 126 throws com.liferay.portal.kernel.exception.SystemException { 127 return getPersistence().findByProductEntryId(productEntryId); 128 } 129 130 /** 131 * Returns a range of all the s c product screenshots where productEntryId = ?. 132 * 133 * <p> 134 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 135 * </p> 136 * 137 * @param productEntryId the product entry ID 138 * @param start the lower bound of the range of s c product screenshots 139 * @param end the upper bound of the range of s c product screenshots (not inclusive) 140 * @return the range of matching s c product screenshots 141 * @throws SystemException if a system exception occurred 142 */ 143 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> findByProductEntryId( 144 long productEntryId, int start, int end) 145 throws com.liferay.portal.kernel.exception.SystemException { 146 return getPersistence().findByProductEntryId(productEntryId, start, end); 147 } 148 149 /** 150 * Returns an ordered range of all the s c product screenshots where productEntryId = ?. 151 * 152 * <p> 153 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 154 * </p> 155 * 156 * @param productEntryId the product entry ID 157 * @param start the lower bound of the range of s c product screenshots 158 * @param end the upper bound of the range of s c product screenshots (not inclusive) 159 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 160 * @return the ordered range of matching s c product screenshots 161 * @throws SystemException if a system exception occurred 162 */ 163 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> findByProductEntryId( 164 long productEntryId, int start, int end, 165 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 166 throws com.liferay.portal.kernel.exception.SystemException { 167 return getPersistence() 168 .findByProductEntryId(productEntryId, start, end, 169 orderByComparator); 170 } 171 172 /** 173 * Returns the first s c product screenshot in the ordered set where productEntryId = ?. 174 * 175 * @param productEntryId the product entry ID 176 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 177 * @return the first matching s c product screenshot 178 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a matching s c product screenshot could not be found 179 * @throws SystemException if a system exception occurred 180 */ 181 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot findByProductEntryId_First( 182 long productEntryId, 183 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 184 throws com.liferay.portal.kernel.exception.SystemException, 185 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 186 return getPersistence() 187 .findByProductEntryId_First(productEntryId, orderByComparator); 188 } 189 190 /** 191 * Returns the first s c product screenshot in the ordered set where productEntryId = ?. 192 * 193 * @param productEntryId the product entry ID 194 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 195 * @return the first matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 196 * @throws SystemException if a system exception occurred 197 */ 198 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByProductEntryId_First( 199 long productEntryId, 200 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 201 throws com.liferay.portal.kernel.exception.SystemException { 202 return getPersistence() 203 .fetchByProductEntryId_First(productEntryId, 204 orderByComparator); 205 } 206 207 /** 208 * Returns the last s c product screenshot in the ordered set where productEntryId = ?. 209 * 210 * @param productEntryId the product entry ID 211 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 212 * @return the last matching s c product screenshot 213 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a matching s c product screenshot could not be found 214 * @throws SystemException if a system exception occurred 215 */ 216 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot findByProductEntryId_Last( 217 long productEntryId, 218 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 219 throws com.liferay.portal.kernel.exception.SystemException, 220 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 221 return getPersistence() 222 .findByProductEntryId_Last(productEntryId, orderByComparator); 223 } 224 225 /** 226 * Returns the last s c product screenshot in the ordered set where productEntryId = ?. 227 * 228 * @param productEntryId the product entry ID 229 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 230 * @return the last matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 231 * @throws SystemException if a system exception occurred 232 */ 233 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByProductEntryId_Last( 234 long productEntryId, 235 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 236 throws com.liferay.portal.kernel.exception.SystemException { 237 return getPersistence() 238 .fetchByProductEntryId_Last(productEntryId, orderByComparator); 239 } 240 241 /** 242 * Returns the s c product screenshots before and after the current s c product screenshot in the ordered set where productEntryId = ?. 243 * 244 * @param productScreenshotId the primary key of the current s c product screenshot 245 * @param productEntryId the product entry ID 246 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 247 * @return the previous, current, and next s c product screenshot 248 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a s c product screenshot with the primary key could not be found 249 * @throws SystemException if a system exception occurred 250 */ 251 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot[] findByProductEntryId_PrevAndNext( 252 long productScreenshotId, long productEntryId, 253 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 254 throws com.liferay.portal.kernel.exception.SystemException, 255 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 256 return getPersistence() 257 .findByProductEntryId_PrevAndNext(productScreenshotId, 258 productEntryId, orderByComparator); 259 } 260 261 /** 262 * Removes all the s c product screenshots where productEntryId = ? from the database. 263 * 264 * @param productEntryId the product entry ID 265 * @throws SystemException if a system exception occurred 266 */ 267 public static void removeByProductEntryId(long productEntryId) 268 throws com.liferay.portal.kernel.exception.SystemException { 269 getPersistence().removeByProductEntryId(productEntryId); 270 } 271 272 /** 273 * Returns the number of s c product screenshots where productEntryId = ?. 274 * 275 * @param productEntryId the product entry ID 276 * @return the number of matching s c product screenshots 277 * @throws SystemException if a system exception occurred 278 */ 279 public static int countByProductEntryId(long productEntryId) 280 throws com.liferay.portal.kernel.exception.SystemException { 281 return getPersistence().countByProductEntryId(productEntryId); 282 } 283 284 /** 285 * Returns the s c product screenshot where thumbnailId = ? or throws a {@link com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException} if it could not be found. 286 * 287 * @param thumbnailId the thumbnail ID 288 * @return the matching s c product screenshot 289 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a matching s c product screenshot could not be found 290 * @throws SystemException if a system exception occurred 291 */ 292 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot findByThumbnailId( 293 long thumbnailId) 294 throws com.liferay.portal.kernel.exception.SystemException, 295 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 296 return getPersistence().findByThumbnailId(thumbnailId); 297 } 298 299 /** 300 * Returns the s c product screenshot where thumbnailId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 301 * 302 * @param thumbnailId the thumbnail ID 303 * @return the matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 304 * @throws SystemException if a system exception occurred 305 */ 306 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByThumbnailId( 307 long thumbnailId) 308 throws com.liferay.portal.kernel.exception.SystemException { 309 return getPersistence().fetchByThumbnailId(thumbnailId); 310 } 311 312 /** 313 * Returns the s c product screenshot where thumbnailId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 314 * 315 * @param thumbnailId the thumbnail ID 316 * @param retrieveFromCache whether to use the finder cache 317 * @return the matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 318 * @throws SystemException if a system exception occurred 319 */ 320 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByThumbnailId( 321 long thumbnailId, boolean retrieveFromCache) 322 throws com.liferay.portal.kernel.exception.SystemException { 323 return getPersistence() 324 .fetchByThumbnailId(thumbnailId, retrieveFromCache); 325 } 326 327 /** 328 * Removes the s c product screenshot where thumbnailId = ? from the database. 329 * 330 * @param thumbnailId the thumbnail ID 331 * @return the s c product screenshot that was removed 332 * @throws SystemException if a system exception occurred 333 */ 334 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot removeByThumbnailId( 335 long thumbnailId) 336 throws com.liferay.portal.kernel.exception.SystemException, 337 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 338 return getPersistence().removeByThumbnailId(thumbnailId); 339 } 340 341 /** 342 * Returns the number of s c product screenshots where thumbnailId = ?. 343 * 344 * @param thumbnailId the thumbnail ID 345 * @return the number of matching s c product screenshots 346 * @throws SystemException if a system exception occurred 347 */ 348 public static int countByThumbnailId(long thumbnailId) 349 throws com.liferay.portal.kernel.exception.SystemException { 350 return getPersistence().countByThumbnailId(thumbnailId); 351 } 352 353 /** 354 * Returns the s c product screenshot where fullImageId = ? or throws a {@link com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException} if it could not be found. 355 * 356 * @param fullImageId the full image ID 357 * @return the matching s c product screenshot 358 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a matching s c product screenshot could not be found 359 * @throws SystemException if a system exception occurred 360 */ 361 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot findByFullImageId( 362 long fullImageId) 363 throws com.liferay.portal.kernel.exception.SystemException, 364 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 365 return getPersistence().findByFullImageId(fullImageId); 366 } 367 368 /** 369 * Returns the s c product screenshot where fullImageId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 370 * 371 * @param fullImageId the full image ID 372 * @return the matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 373 * @throws SystemException if a system exception occurred 374 */ 375 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByFullImageId( 376 long fullImageId) 377 throws com.liferay.portal.kernel.exception.SystemException { 378 return getPersistence().fetchByFullImageId(fullImageId); 379 } 380 381 /** 382 * Returns the s c product screenshot where fullImageId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 383 * 384 * @param fullImageId the full image ID 385 * @param retrieveFromCache whether to use the finder cache 386 * @return the matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 387 * @throws SystemException if a system exception occurred 388 */ 389 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByFullImageId( 390 long fullImageId, boolean retrieveFromCache) 391 throws com.liferay.portal.kernel.exception.SystemException { 392 return getPersistence() 393 .fetchByFullImageId(fullImageId, retrieveFromCache); 394 } 395 396 /** 397 * Removes the s c product screenshot where fullImageId = ? from the database. 398 * 399 * @param fullImageId the full image ID 400 * @return the s c product screenshot that was removed 401 * @throws SystemException if a system exception occurred 402 */ 403 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot removeByFullImageId( 404 long fullImageId) 405 throws com.liferay.portal.kernel.exception.SystemException, 406 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 407 return getPersistence().removeByFullImageId(fullImageId); 408 } 409 410 /** 411 * Returns the number of s c product screenshots where fullImageId = ?. 412 * 413 * @param fullImageId the full image ID 414 * @return the number of matching s c product screenshots 415 * @throws SystemException if a system exception occurred 416 */ 417 public static int countByFullImageId(long fullImageId) 418 throws com.liferay.portal.kernel.exception.SystemException { 419 return getPersistence().countByFullImageId(fullImageId); 420 } 421 422 /** 423 * Returns the s c product screenshot where productEntryId = ? and priority = ? or throws a {@link com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException} if it could not be found. 424 * 425 * @param productEntryId the product entry ID 426 * @param priority the priority 427 * @return the matching s c product screenshot 428 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a matching s c product screenshot could not be found 429 * @throws SystemException if a system exception occurred 430 */ 431 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot findByP_P( 432 long productEntryId, int priority) 433 throws com.liferay.portal.kernel.exception.SystemException, 434 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 435 return getPersistence().findByP_P(productEntryId, priority); 436 } 437 438 /** 439 * Returns the s c product screenshot where productEntryId = ? and priority = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 440 * 441 * @param productEntryId the product entry ID 442 * @param priority the priority 443 * @return the matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 444 * @throws SystemException if a system exception occurred 445 */ 446 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByP_P( 447 long productEntryId, int priority) 448 throws com.liferay.portal.kernel.exception.SystemException { 449 return getPersistence().fetchByP_P(productEntryId, priority); 450 } 451 452 /** 453 * Returns the s c product screenshot where productEntryId = ? and priority = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 454 * 455 * @param productEntryId the product entry ID 456 * @param priority the priority 457 * @param retrieveFromCache whether to use the finder cache 458 * @return the matching s c product screenshot, or <code>null</code> if a matching s c product screenshot could not be found 459 * @throws SystemException if a system exception occurred 460 */ 461 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByP_P( 462 long productEntryId, int priority, boolean retrieveFromCache) 463 throws com.liferay.portal.kernel.exception.SystemException { 464 return getPersistence() 465 .fetchByP_P(productEntryId, priority, retrieveFromCache); 466 } 467 468 /** 469 * Removes the s c product screenshot where productEntryId = ? and priority = ? from the database. 470 * 471 * @param productEntryId the product entry ID 472 * @param priority the priority 473 * @return the s c product screenshot that was removed 474 * @throws SystemException if a system exception occurred 475 */ 476 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot removeByP_P( 477 long productEntryId, int priority) 478 throws com.liferay.portal.kernel.exception.SystemException, 479 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 480 return getPersistence().removeByP_P(productEntryId, priority); 481 } 482 483 /** 484 * Returns the number of s c product screenshots where productEntryId = ? and priority = ?. 485 * 486 * @param productEntryId the product entry ID 487 * @param priority the priority 488 * @return the number of matching s c product screenshots 489 * @throws SystemException if a system exception occurred 490 */ 491 public static int countByP_P(long productEntryId, int priority) 492 throws com.liferay.portal.kernel.exception.SystemException { 493 return getPersistence().countByP_P(productEntryId, priority); 494 } 495 496 /** 497 * Caches the s c product screenshot in the entity cache if it is enabled. 498 * 499 * @param scProductScreenshot the s c product screenshot 500 */ 501 public static void cacheResult( 502 com.liferay.portlet.softwarecatalog.model.SCProductScreenshot scProductScreenshot) { 503 getPersistence().cacheResult(scProductScreenshot); 504 } 505 506 /** 507 * Caches the s c product screenshots in the entity cache if it is enabled. 508 * 509 * @param scProductScreenshots the s c product screenshots 510 */ 511 public static void cacheResult( 512 java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> scProductScreenshots) { 513 getPersistence().cacheResult(scProductScreenshots); 514 } 515 516 /** 517 * Creates a new s c product screenshot with the primary key. Does not add the s c product screenshot to the database. 518 * 519 * @param productScreenshotId the primary key for the new s c product screenshot 520 * @return the new s c product screenshot 521 */ 522 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot create( 523 long productScreenshotId) { 524 return getPersistence().create(productScreenshotId); 525 } 526 527 /** 528 * Removes the s c product screenshot with the primary key from the database. Also notifies the appropriate model listeners. 529 * 530 * @param productScreenshotId the primary key of the s c product screenshot 531 * @return the s c product screenshot that was removed 532 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a s c product screenshot with the primary key could not be found 533 * @throws SystemException if a system exception occurred 534 */ 535 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot remove( 536 long productScreenshotId) 537 throws com.liferay.portal.kernel.exception.SystemException, 538 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 539 return getPersistence().remove(productScreenshotId); 540 } 541 542 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot updateImpl( 543 com.liferay.portlet.softwarecatalog.model.SCProductScreenshot scProductScreenshot) 544 throws com.liferay.portal.kernel.exception.SystemException { 545 return getPersistence().updateImpl(scProductScreenshot); 546 } 547 548 /** 549 * Returns the s c product screenshot with the primary key or throws a {@link com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException} if it could not be found. 550 * 551 * @param productScreenshotId the primary key of the s c product screenshot 552 * @return the s c product screenshot 553 * @throws com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException if a s c product screenshot with the primary key could not be found 554 * @throws SystemException if a system exception occurred 555 */ 556 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot findByPrimaryKey( 557 long productScreenshotId) 558 throws com.liferay.portal.kernel.exception.SystemException, 559 com.liferay.portlet.softwarecatalog.NoSuchProductScreenshotException { 560 return getPersistence().findByPrimaryKey(productScreenshotId); 561 } 562 563 /** 564 * Returns the s c product screenshot with the primary key or returns <code>null</code> if it could not be found. 565 * 566 * @param productScreenshotId the primary key of the s c product screenshot 567 * @return the s c product screenshot, or <code>null</code> if a s c product screenshot with the primary key could not be found 568 * @throws SystemException if a system exception occurred 569 */ 570 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchByPrimaryKey( 571 long productScreenshotId) 572 throws com.liferay.portal.kernel.exception.SystemException { 573 return getPersistence().fetchByPrimaryKey(productScreenshotId); 574 } 575 576 /** 577 * Returns all the s c product screenshots. 578 * 579 * @return the s c product screenshots 580 * @throws SystemException if a system exception occurred 581 */ 582 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> findAll() 583 throws com.liferay.portal.kernel.exception.SystemException { 584 return getPersistence().findAll(); 585 } 586 587 /** 588 * Returns a range of all the s c product screenshots. 589 * 590 * <p> 591 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 592 * </p> 593 * 594 * @param start the lower bound of the range of s c product screenshots 595 * @param end the upper bound of the range of s c product screenshots (not inclusive) 596 * @return the range of s c product screenshots 597 * @throws SystemException if a system exception occurred 598 */ 599 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> findAll( 600 int start, int end) 601 throws com.liferay.portal.kernel.exception.SystemException { 602 return getPersistence().findAll(start, end); 603 } 604 605 /** 606 * Returns an ordered range of all the s c product screenshots. 607 * 608 * <p> 609 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 610 * </p> 611 * 612 * @param start the lower bound of the range of s c product screenshots 613 * @param end the upper bound of the range of s c product screenshots (not inclusive) 614 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 615 * @return the ordered range of s c product screenshots 616 * @throws SystemException if a system exception occurred 617 */ 618 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> findAll( 619 int start, int end, 620 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 621 throws com.liferay.portal.kernel.exception.SystemException { 622 return getPersistence().findAll(start, end, orderByComparator); 623 } 624 625 /** 626 * Removes all the s c product screenshots from the database. 627 * 628 * @throws SystemException if a system exception occurred 629 */ 630 public static void removeAll() 631 throws com.liferay.portal.kernel.exception.SystemException { 632 getPersistence().removeAll(); 633 } 634 635 /** 636 * Returns the number of s c product screenshots. 637 * 638 * @return the number of s c product screenshots 639 * @throws SystemException if a system exception occurred 640 */ 641 public static int countAll() 642 throws com.liferay.portal.kernel.exception.SystemException { 643 return getPersistence().countAll(); 644 } 645 646 public static SCProductScreenshotPersistence getPersistence() { 647 if (_persistence == null) { 648 _persistence = (SCProductScreenshotPersistence)PortalBeanLocatorUtil.locate(SCProductScreenshotPersistence.class.getName()); 649 650 ReferenceRegistry.registerReference(SCProductScreenshotUtil.class, 651 "_persistence"); 652 } 653 654 return _persistence; 655 } 656 657 /** 658 * @deprecated As of 6.2.0 659 */ 660 public void setPersistence(SCProductScreenshotPersistence persistence) { 661 } 662 663 private static SCProductScreenshotPersistence _persistence; 664 }