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