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