1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   * 
13   */
14  
15  package com.liferay.portal.service.persistence;
16  
17  import com.liferay.portal.SystemException;
18  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
19  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
20  import com.liferay.portal.model.Layout;
21  
22  import java.util.List;
23  
24  /**
25   * <a href="LayoutUtil.java.html"><b><i>View Source</i></b></a>
26   *
27   * <p>
28   * ServiceBuilder generated this class. Modifications in this class will be
29   * overwritten the next time is generated.
30   * </p>
31   *
32   * @author    Brian Wing Shun Chan
33   * @see       LayoutPersistence
34   * @see       LayoutPersistenceImpl
35   * @generated
36   */
37  public class LayoutUtil {
38      /**
39       * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
40       */
41      public static void clearCache() {
42          getPersistence().clearCache();
43      }
44  
45      /**
46       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
47       */
48      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
49          throws SystemException {
50          return getPersistence().findWithDynamicQuery(dynamicQuery);
51      }
52  
53      /**
54       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
55       */
56      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
57          int start, int end) throws SystemException {
58          return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
59      }
60  
61      /**
62       * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
63       */
64      public static Layout remove(Layout layout) throws SystemException {
65          return getPersistence().remove(layout);
66      }
67  
68      /**
69       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
70       */
71      public static Layout update(Layout layout, boolean merge)
72          throws SystemException {
73          return getPersistence().update(layout, merge);
74      }
75  
76      public static void cacheResult(com.liferay.portal.model.Layout layout) {
77          getPersistence().cacheResult(layout);
78      }
79  
80      public static void cacheResult(
81          java.util.List<com.liferay.portal.model.Layout> layouts) {
82          getPersistence().cacheResult(layouts);
83      }
84  
85      public static com.liferay.portal.model.Layout create(long plid) {
86          return getPersistence().create(plid);
87      }
88  
89      public static com.liferay.portal.model.Layout remove(long plid)
90          throws com.liferay.portal.NoSuchLayoutException,
91              com.liferay.portal.SystemException {
92          return getPersistence().remove(plid);
93      }
94  
95      /**
96       * @deprecated Use {@link com.liferay.portal.service.persistence.BasePersistence.#update(com.liferay.portal.model.BaseModel, boolean)}.
97       */
98      public static com.liferay.portal.model.Layout update(
99          com.liferay.portal.model.Layout layout)
100         throws com.liferay.portal.SystemException {
101         return getPersistence().update(layout);
102     }
103 
104     public static com.liferay.portal.model.Layout updateImpl(
105         com.liferay.portal.model.Layout layout, boolean merge)
106         throws com.liferay.portal.SystemException {
107         return getPersistence().updateImpl(layout, merge);
108     }
109 
110     public static com.liferay.portal.model.Layout findByPrimaryKey(long plid)
111         throws com.liferay.portal.NoSuchLayoutException,
112             com.liferay.portal.SystemException {
113         return getPersistence().findByPrimaryKey(plid);
114     }
115 
116     public static com.liferay.portal.model.Layout fetchByPrimaryKey(long plid)
117         throws com.liferay.portal.SystemException {
118         return getPersistence().fetchByPrimaryKey(plid);
119     }
120 
121     public static java.util.List<com.liferay.portal.model.Layout> findByGroupId(
122         long groupId) throws com.liferay.portal.SystemException {
123         return getPersistence().findByGroupId(groupId);
124     }
125 
126     public static java.util.List<com.liferay.portal.model.Layout> findByGroupId(
127         long groupId, int start, int end)
128         throws com.liferay.portal.SystemException {
129         return getPersistence().findByGroupId(groupId, start, end);
130     }
131 
132     public static java.util.List<com.liferay.portal.model.Layout> findByGroupId(
133         long groupId, int start, int end,
134         com.liferay.portal.kernel.util.OrderByComparator obc)
135         throws com.liferay.portal.SystemException {
136         return getPersistence().findByGroupId(groupId, start, end, obc);
137     }
138 
139     public static com.liferay.portal.model.Layout findByGroupId_First(
140         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
141         throws com.liferay.portal.NoSuchLayoutException,
142             com.liferay.portal.SystemException {
143         return getPersistence().findByGroupId_First(groupId, obc);
144     }
145 
146     public static com.liferay.portal.model.Layout findByGroupId_Last(
147         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
148         throws com.liferay.portal.NoSuchLayoutException,
149             com.liferay.portal.SystemException {
150         return getPersistence().findByGroupId_Last(groupId, obc);
151     }
152 
153     public static com.liferay.portal.model.Layout[] findByGroupId_PrevAndNext(
154         long plid, long groupId,
155         com.liferay.portal.kernel.util.OrderByComparator obc)
156         throws com.liferay.portal.NoSuchLayoutException,
157             com.liferay.portal.SystemException {
158         return getPersistence().findByGroupId_PrevAndNext(plid, groupId, obc);
159     }
160 
161     public static java.util.List<com.liferay.portal.model.Layout> findByCompanyId(
162         long companyId) throws com.liferay.portal.SystemException {
163         return getPersistence().findByCompanyId(companyId);
164     }
165 
166     public static java.util.List<com.liferay.portal.model.Layout> findByCompanyId(
167         long companyId, int start, int end)
168         throws com.liferay.portal.SystemException {
169         return getPersistence().findByCompanyId(companyId, start, end);
170     }
171 
172     public static java.util.List<com.liferay.portal.model.Layout> findByCompanyId(
173         long companyId, int start, int end,
174         com.liferay.portal.kernel.util.OrderByComparator obc)
175         throws com.liferay.portal.SystemException {
176         return getPersistence().findByCompanyId(companyId, start, end, obc);
177     }
178 
179     public static com.liferay.portal.model.Layout findByCompanyId_First(
180         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
181         throws com.liferay.portal.NoSuchLayoutException,
182             com.liferay.portal.SystemException {
183         return getPersistence().findByCompanyId_First(companyId, obc);
184     }
185 
186     public static com.liferay.portal.model.Layout findByCompanyId_Last(
187         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
188         throws com.liferay.portal.NoSuchLayoutException,
189             com.liferay.portal.SystemException {
190         return getPersistence().findByCompanyId_Last(companyId, obc);
191     }
192 
193     public static com.liferay.portal.model.Layout[] findByCompanyId_PrevAndNext(
194         long plid, long companyId,
195         com.liferay.portal.kernel.util.OrderByComparator obc)
196         throws com.liferay.portal.NoSuchLayoutException,
197             com.liferay.portal.SystemException {
198         return getPersistence().findByCompanyId_PrevAndNext(plid, companyId, obc);
199     }
200 
201     public static com.liferay.portal.model.Layout findByDLFolderId(
202         long dlFolderId)
203         throws com.liferay.portal.NoSuchLayoutException,
204             com.liferay.portal.SystemException {
205         return getPersistence().findByDLFolderId(dlFolderId);
206     }
207 
208     public static com.liferay.portal.model.Layout fetchByDLFolderId(
209         long dlFolderId) throws com.liferay.portal.SystemException {
210         return getPersistence().fetchByDLFolderId(dlFolderId);
211     }
212 
213     public static com.liferay.portal.model.Layout fetchByDLFolderId(
214         long dlFolderId, boolean retrieveFromCache)
215         throws com.liferay.portal.SystemException {
216         return getPersistence().fetchByDLFolderId(dlFolderId, retrieveFromCache);
217     }
218 
219     public static com.liferay.portal.model.Layout findByIconImageId(
220         long iconImageId)
221         throws com.liferay.portal.NoSuchLayoutException,
222             com.liferay.portal.SystemException {
223         return getPersistence().findByIconImageId(iconImageId);
224     }
225 
226     public static com.liferay.portal.model.Layout fetchByIconImageId(
227         long iconImageId) throws com.liferay.portal.SystemException {
228         return getPersistence().fetchByIconImageId(iconImageId);
229     }
230 
231     public static com.liferay.portal.model.Layout fetchByIconImageId(
232         long iconImageId, boolean retrieveFromCache)
233         throws com.liferay.portal.SystemException {
234         return getPersistence()
235                    .fetchByIconImageId(iconImageId, retrieveFromCache);
236     }
237 
238     public static java.util.List<com.liferay.portal.model.Layout> findByG_P(
239         long groupId, boolean privateLayout)
240         throws com.liferay.portal.SystemException {
241         return getPersistence().findByG_P(groupId, privateLayout);
242     }
243 
244     public static java.util.List<com.liferay.portal.model.Layout> findByG_P(
245         long groupId, boolean privateLayout, int start, int end)
246         throws com.liferay.portal.SystemException {
247         return getPersistence().findByG_P(groupId, privateLayout, start, end);
248     }
249 
250     public static java.util.List<com.liferay.portal.model.Layout> findByG_P(
251         long groupId, boolean privateLayout, int start, int end,
252         com.liferay.portal.kernel.util.OrderByComparator obc)
253         throws com.liferay.portal.SystemException {
254         return getPersistence()
255                    .findByG_P(groupId, privateLayout, start, end, obc);
256     }
257 
258     public static com.liferay.portal.model.Layout findByG_P_First(
259         long groupId, boolean privateLayout,
260         com.liferay.portal.kernel.util.OrderByComparator obc)
261         throws com.liferay.portal.NoSuchLayoutException,
262             com.liferay.portal.SystemException {
263         return getPersistence().findByG_P_First(groupId, privateLayout, obc);
264     }
265 
266     public static com.liferay.portal.model.Layout findByG_P_Last(long groupId,
267         boolean privateLayout,
268         com.liferay.portal.kernel.util.OrderByComparator obc)
269         throws com.liferay.portal.NoSuchLayoutException,
270             com.liferay.portal.SystemException {
271         return getPersistence().findByG_P_Last(groupId, privateLayout, obc);
272     }
273 
274     public static com.liferay.portal.model.Layout[] findByG_P_PrevAndNext(
275         long plid, long groupId, boolean privateLayout,
276         com.liferay.portal.kernel.util.OrderByComparator obc)
277         throws com.liferay.portal.NoSuchLayoutException,
278             com.liferay.portal.SystemException {
279         return getPersistence()
280                    .findByG_P_PrevAndNext(plid, groupId, privateLayout, obc);
281     }
282 
283     public static com.liferay.portal.model.Layout findByG_P_L(long groupId,
284         boolean privateLayout, long layoutId)
285         throws com.liferay.portal.NoSuchLayoutException,
286             com.liferay.portal.SystemException {
287         return getPersistence().findByG_P_L(groupId, privateLayout, layoutId);
288     }
289 
290     public static com.liferay.portal.model.Layout fetchByG_P_L(long groupId,
291         boolean privateLayout, long layoutId)
292         throws com.liferay.portal.SystemException {
293         return getPersistence().fetchByG_P_L(groupId, privateLayout, layoutId);
294     }
295 
296     public static com.liferay.portal.model.Layout fetchByG_P_L(long groupId,
297         boolean privateLayout, long layoutId, boolean retrieveFromCache)
298         throws com.liferay.portal.SystemException {
299         return getPersistence()
300                    .fetchByG_P_L(groupId, privateLayout, layoutId,
301             retrieveFromCache);
302     }
303 
304     public static java.util.List<com.liferay.portal.model.Layout> findByG_P_P(
305         long groupId, boolean privateLayout, long parentLayoutId)
306         throws com.liferay.portal.SystemException {
307         return getPersistence()
308                    .findByG_P_P(groupId, privateLayout, parentLayoutId);
309     }
310 
311     public static java.util.List<com.liferay.portal.model.Layout> findByG_P_P(
312         long groupId, boolean privateLayout, long parentLayoutId, int start,
313         int end) throws com.liferay.portal.SystemException {
314         return getPersistence()
315                    .findByG_P_P(groupId, privateLayout, parentLayoutId, start,
316             end);
317     }
318 
319     public static java.util.List<com.liferay.portal.model.Layout> findByG_P_P(
320         long groupId, boolean privateLayout, long parentLayoutId, int start,
321         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
322         throws com.liferay.portal.SystemException {
323         return getPersistence()
324                    .findByG_P_P(groupId, privateLayout, parentLayoutId, start,
325             end, obc);
326     }
327 
328     public static com.liferay.portal.model.Layout findByG_P_P_First(
329         long groupId, boolean privateLayout, long parentLayoutId,
330         com.liferay.portal.kernel.util.OrderByComparator obc)
331         throws com.liferay.portal.NoSuchLayoutException,
332             com.liferay.portal.SystemException {
333         return getPersistence()
334                    .findByG_P_P_First(groupId, privateLayout, parentLayoutId,
335             obc);
336     }
337 
338     public static com.liferay.portal.model.Layout findByG_P_P_Last(
339         long groupId, boolean privateLayout, long parentLayoutId,
340         com.liferay.portal.kernel.util.OrderByComparator obc)
341         throws com.liferay.portal.NoSuchLayoutException,
342             com.liferay.portal.SystemException {
343         return getPersistence()
344                    .findByG_P_P_Last(groupId, privateLayout, parentLayoutId, obc);
345     }
346 
347     public static com.liferay.portal.model.Layout[] findByG_P_P_PrevAndNext(
348         long plid, long groupId, boolean privateLayout, long parentLayoutId,
349         com.liferay.portal.kernel.util.OrderByComparator obc)
350         throws com.liferay.portal.NoSuchLayoutException,
351             com.liferay.portal.SystemException {
352         return getPersistence()
353                    .findByG_P_P_PrevAndNext(plid, groupId, privateLayout,
354             parentLayoutId, obc);
355     }
356 
357     public static com.liferay.portal.model.Layout findByG_P_F(long groupId,
358         boolean privateLayout, java.lang.String friendlyURL)
359         throws com.liferay.portal.NoSuchLayoutException,
360             com.liferay.portal.SystemException {
361         return getPersistence().findByG_P_F(groupId, privateLayout, friendlyURL);
362     }
363 
364     public static com.liferay.portal.model.Layout fetchByG_P_F(long groupId,
365         boolean privateLayout, java.lang.String friendlyURL)
366         throws com.liferay.portal.SystemException {
367         return getPersistence().fetchByG_P_F(groupId, privateLayout, friendlyURL);
368     }
369 
370     public static com.liferay.portal.model.Layout fetchByG_P_F(long groupId,
371         boolean privateLayout, java.lang.String friendlyURL,
372         boolean retrieveFromCache) throws com.liferay.portal.SystemException {
373         return getPersistence()
374                    .fetchByG_P_F(groupId, privateLayout, friendlyURL,
375             retrieveFromCache);
376     }
377 
378     public static java.util.List<com.liferay.portal.model.Layout> findByG_P_T(
379         long groupId, boolean privateLayout, java.lang.String type)
380         throws com.liferay.portal.SystemException {
381         return getPersistence().findByG_P_T(groupId, privateLayout, type);
382     }
383 
384     public static java.util.List<com.liferay.portal.model.Layout> findByG_P_T(
385         long groupId, boolean privateLayout, java.lang.String type, int start,
386         int end) throws com.liferay.portal.SystemException {
387         return getPersistence()
388                    .findByG_P_T(groupId, privateLayout, type, start, end);
389     }
390 
391     public static java.util.List<com.liferay.portal.model.Layout> findByG_P_T(
392         long groupId, boolean privateLayout, java.lang.String type, int start,
393         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
394         throws com.liferay.portal.SystemException {
395         return getPersistence()
396                    .findByG_P_T(groupId, privateLayout, type, start, end, obc);
397     }
398 
399     public static com.liferay.portal.model.Layout findByG_P_T_First(
400         long groupId, boolean privateLayout, java.lang.String type,
401         com.liferay.portal.kernel.util.OrderByComparator obc)
402         throws com.liferay.portal.NoSuchLayoutException,
403             com.liferay.portal.SystemException {
404         return getPersistence()
405                    .findByG_P_T_First(groupId, privateLayout, type, obc);
406     }
407 
408     public static com.liferay.portal.model.Layout findByG_P_T_Last(
409         long groupId, boolean privateLayout, java.lang.String type,
410         com.liferay.portal.kernel.util.OrderByComparator obc)
411         throws com.liferay.portal.NoSuchLayoutException,
412             com.liferay.portal.SystemException {
413         return getPersistence()
414                    .findByG_P_T_Last(groupId, privateLayout, type, obc);
415     }
416 
417     public static com.liferay.portal.model.Layout[] findByG_P_T_PrevAndNext(
418         long plid, long groupId, boolean privateLayout, java.lang.String type,
419         com.liferay.portal.kernel.util.OrderByComparator obc)
420         throws com.liferay.portal.NoSuchLayoutException,
421             com.liferay.portal.SystemException {
422         return getPersistence()
423                    .findByG_P_T_PrevAndNext(plid, groupId, privateLayout, type,
424             obc);
425     }
426 
427     public static java.util.List<com.liferay.portal.model.Layout> findAll()
428         throws com.liferay.portal.SystemException {
429         return getPersistence().findAll();
430     }
431 
432     public static java.util.List<com.liferay.portal.model.Layout> findAll(
433         int start, int end) throws com.liferay.portal.SystemException {
434         return getPersistence().findAll(start, end);
435     }
436 
437     public static java.util.List<com.liferay.portal.model.Layout> findAll(
438         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
439         throws com.liferay.portal.SystemException {
440         return getPersistence().findAll(start, end, obc);
441     }
442 
443     public static void removeByGroupId(long groupId)
444         throws com.liferay.portal.SystemException {
445         getPersistence().removeByGroupId(groupId);
446     }
447 
448     public static void removeByCompanyId(long companyId)
449         throws com.liferay.portal.SystemException {
450         getPersistence().removeByCompanyId(companyId);
451     }
452 
453     public static void removeByDLFolderId(long dlFolderId)
454         throws com.liferay.portal.NoSuchLayoutException,
455             com.liferay.portal.SystemException {
456         getPersistence().removeByDLFolderId(dlFolderId);
457     }
458 
459     public static void removeByIconImageId(long iconImageId)
460         throws com.liferay.portal.NoSuchLayoutException,
461             com.liferay.portal.SystemException {
462         getPersistence().removeByIconImageId(iconImageId);
463     }
464 
465     public static void removeByG_P(long groupId, boolean privateLayout)
466         throws com.liferay.portal.SystemException {
467         getPersistence().removeByG_P(groupId, privateLayout);
468     }
469 
470     public static void removeByG_P_L(long groupId, boolean privateLayout,
471         long layoutId)
472         throws com.liferay.portal.NoSuchLayoutException,
473             com.liferay.portal.SystemException {
474         getPersistence().removeByG_P_L(groupId, privateLayout, layoutId);
475     }
476 
477     public static void removeByG_P_P(long groupId, boolean privateLayout,
478         long parentLayoutId) throws com.liferay.portal.SystemException {
479         getPersistence().removeByG_P_P(groupId, privateLayout, parentLayoutId);
480     }
481 
482     public static void removeByG_P_F(long groupId, boolean privateLayout,
483         java.lang.String friendlyURL)
484         throws com.liferay.portal.NoSuchLayoutException,
485             com.liferay.portal.SystemException {
486         getPersistence().removeByG_P_F(groupId, privateLayout, friendlyURL);
487     }
488 
489     public static void removeByG_P_T(long groupId, boolean privateLayout,
490         java.lang.String type) throws com.liferay.portal.SystemException {
491         getPersistence().removeByG_P_T(groupId, privateLayout, type);
492     }
493 
494     public static void removeAll() throws com.liferay.portal.SystemException {
495         getPersistence().removeAll();
496     }
497 
498     public static int countByGroupId(long groupId)
499         throws com.liferay.portal.SystemException {
500         return getPersistence().countByGroupId(groupId);
501     }
502 
503     public static int countByCompanyId(long companyId)
504         throws com.liferay.portal.SystemException {
505         return getPersistence().countByCompanyId(companyId);
506     }
507 
508     public static int countByDLFolderId(long dlFolderId)
509         throws com.liferay.portal.SystemException {
510         return getPersistence().countByDLFolderId(dlFolderId);
511     }
512 
513     public static int countByIconImageId(long iconImageId)
514         throws com.liferay.portal.SystemException {
515         return getPersistence().countByIconImageId(iconImageId);
516     }
517 
518     public static int countByG_P(long groupId, boolean privateLayout)
519         throws com.liferay.portal.SystemException {
520         return getPersistence().countByG_P(groupId, privateLayout);
521     }
522 
523     public static int countByG_P_L(long groupId, boolean privateLayout,
524         long layoutId) throws com.liferay.portal.SystemException {
525         return getPersistence().countByG_P_L(groupId, privateLayout, layoutId);
526     }
527 
528     public static int countByG_P_P(long groupId, boolean privateLayout,
529         long parentLayoutId) throws com.liferay.portal.SystemException {
530         return getPersistence()
531                    .countByG_P_P(groupId, privateLayout, parentLayoutId);
532     }
533 
534     public static int countByG_P_F(long groupId, boolean privateLayout,
535         java.lang.String friendlyURL) throws com.liferay.portal.SystemException {
536         return getPersistence().countByG_P_F(groupId, privateLayout, friendlyURL);
537     }
538 
539     public static int countByG_P_T(long groupId, boolean privateLayout,
540         java.lang.String type) throws com.liferay.portal.SystemException {
541         return getPersistence().countByG_P_T(groupId, privateLayout, type);
542     }
543 
544     public static int countAll() throws com.liferay.portal.SystemException {
545         return getPersistence().countAll();
546     }
547 
548     public static LayoutPersistence getPersistence() {
549         if (_persistence == null) {
550             _persistence = (LayoutPersistence)PortalBeanLocatorUtil.locate(LayoutPersistence.class.getName());
551         }
552 
553         return _persistence;
554     }
555 
556     public void setPersistence(LayoutPersistence persistence) {
557         _persistence = persistence;
558     }
559 
560     private static LayoutPersistence _persistence;
561 }