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