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