1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.service;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  
19  /**
20   * <a href="LayoutLocalServiceUtil.java.html"><b><i>View Source</i></b></a>
21   *
22   * <p>
23   * ServiceBuilder generated this class. Modifications in this class will be
24   * overwritten the next time is generated.
25   * </p>
26   *
27   * <p>
28   * This class provides static methods for the
29   * {@link LayoutLocalService} bean. The static methods of
30   * this class calls the same methods of the bean instance. It's convenient to be
31   * able to just write one line to call a method on a bean instead of writing a
32   * lookup call and a method call.
33   * </p>
34   *
35   * @author    Brian Wing Shun Chan
36   * @see       LayoutLocalService
37   * @generated
38   */
39  public class LayoutLocalServiceUtil {
40      public static com.liferay.portal.model.Layout addLayout(
41          com.liferay.portal.model.Layout layout)
42          throws com.liferay.portal.kernel.exception.SystemException {
43          return getService().addLayout(layout);
44      }
45  
46      public static com.liferay.portal.model.Layout createLayout(long plid) {
47          return getService().createLayout(plid);
48      }
49  
50      public static void deleteLayout(long plid)
51          throws com.liferay.portal.kernel.exception.PortalException,
52              com.liferay.portal.kernel.exception.SystemException {
53          getService().deleteLayout(plid);
54      }
55  
56      public static void deleteLayout(com.liferay.portal.model.Layout layout)
57          throws com.liferay.portal.kernel.exception.SystemException {
58          getService().deleteLayout(layout);
59      }
60  
61      public static java.util.List<Object> dynamicQuery(
62          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
63          throws com.liferay.portal.kernel.exception.SystemException {
64          return getService().dynamicQuery(dynamicQuery);
65      }
66  
67      public static java.util.List<Object> dynamicQuery(
68          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
69          int end) throws com.liferay.portal.kernel.exception.SystemException {
70          return getService().dynamicQuery(dynamicQuery, start, end);
71      }
72  
73      public static java.util.List<Object> dynamicQuery(
74          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
75          int end,
76          com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
77          throws com.liferay.portal.kernel.exception.SystemException {
78          return getService()
79                     .dynamicQuery(dynamicQuery, start, end, orderByComparator);
80      }
81  
82      public static int dynamicQueryCount(
83          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
84          throws com.liferay.portal.kernel.exception.SystemException {
85          return getService().dynamicQueryCount(dynamicQuery);
86      }
87  
88      public static com.liferay.portal.model.Layout getLayout(long plid)
89          throws com.liferay.portal.kernel.exception.PortalException,
90              com.liferay.portal.kernel.exception.SystemException {
91          return getService().getLayout(plid);
92      }
93  
94      public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
95          int start, int end)
96          throws com.liferay.portal.kernel.exception.SystemException {
97          return getService().getLayouts(start, end);
98      }
99  
100     public static int getLayoutsCount()
101         throws com.liferay.portal.kernel.exception.SystemException {
102         return getService().getLayoutsCount();
103     }
104 
105     public static com.liferay.portal.model.Layout updateLayout(
106         com.liferay.portal.model.Layout layout)
107         throws com.liferay.portal.kernel.exception.SystemException {
108         return getService().updateLayout(layout);
109     }
110 
111     public static com.liferay.portal.model.Layout updateLayout(
112         com.liferay.portal.model.Layout layout, boolean merge)
113         throws com.liferay.portal.kernel.exception.SystemException {
114         return getService().updateLayout(layout, merge);
115     }
116 
117     public static com.liferay.portal.model.Layout addLayout(long userId,
118         long groupId, boolean privateLayout, long parentLayoutId,
119         java.util.Map<java.util.Locale, String> localeNamesMap,
120         java.util.Map<java.util.Locale, String> localeTitlesMap,
121         java.lang.String description, java.lang.String type, boolean hidden,
122         java.lang.String friendlyURL, long dlFolderId,
123         com.liferay.portal.service.ServiceContext serviceContext)
124         throws com.liferay.portal.kernel.exception.PortalException,
125             com.liferay.portal.kernel.exception.SystemException {
126         return getService()
127                    .addLayout(userId, groupId, privateLayout, parentLayoutId,
128             localeNamesMap, localeTitlesMap, description, type, hidden,
129             friendlyURL, dlFolderId, serviceContext);
130     }
131 
132     public static com.liferay.portal.model.Layout addLayout(long userId,
133         long groupId, boolean privateLayout, long parentLayoutId,
134         java.util.Map<java.util.Locale, String> localeNamesMap,
135         java.util.Map<java.util.Locale, String> localeTitlesMap,
136         java.lang.String description, java.lang.String type, boolean hidden,
137         java.lang.String friendlyURL,
138         com.liferay.portal.service.ServiceContext serviceContext)
139         throws com.liferay.portal.kernel.exception.PortalException,
140             com.liferay.portal.kernel.exception.SystemException {
141         return getService()
142                    .addLayout(userId, groupId, privateLayout, parentLayoutId,
143             localeNamesMap, localeTitlesMap, description, type, hidden,
144             friendlyURL, serviceContext);
145     }
146 
147     public static com.liferay.portal.model.Layout addLayout(long userId,
148         long groupId, boolean privateLayout, long parentLayoutId,
149         java.lang.String name, java.lang.String title,
150         java.lang.String description, java.lang.String type, boolean hidden,
151         java.lang.String friendlyURL, long dlFolderId,
152         com.liferay.portal.service.ServiceContext serviceContext)
153         throws com.liferay.portal.kernel.exception.PortalException,
154             com.liferay.portal.kernel.exception.SystemException {
155         return getService()
156                    .addLayout(userId, groupId, privateLayout, parentLayoutId,
157             name, title, description, type, hidden, friendlyURL, dlFolderId,
158             serviceContext);
159     }
160 
161     public static com.liferay.portal.model.Layout addLayout(long userId,
162         long groupId, boolean privateLayout, long parentLayoutId,
163         java.lang.String name, java.lang.String title,
164         java.lang.String description, java.lang.String type, boolean hidden,
165         java.lang.String friendlyURL,
166         com.liferay.portal.service.ServiceContext serviceContext)
167         throws com.liferay.portal.kernel.exception.PortalException,
168             com.liferay.portal.kernel.exception.SystemException {
169         return getService()
170                    .addLayout(userId, groupId, privateLayout, parentLayoutId,
171             name, title, description, type, hidden, friendlyURL, serviceContext);
172     }
173 
174     public static void deleteLayout(com.liferay.portal.model.Layout layout,
175         boolean updateLayoutSet)
176         throws com.liferay.portal.kernel.exception.PortalException,
177             com.liferay.portal.kernel.exception.SystemException {
178         getService().deleteLayout(layout, updateLayoutSet);
179     }
180 
181     public static void deleteLayout(long groupId, boolean privateLayout,
182         long layoutId)
183         throws com.liferay.portal.kernel.exception.PortalException,
184             com.liferay.portal.kernel.exception.SystemException {
185         getService().deleteLayout(groupId, privateLayout, layoutId);
186     }
187 
188     public static void deleteLayouts(long groupId, boolean privateLayout)
189         throws com.liferay.portal.kernel.exception.PortalException,
190             com.liferay.portal.kernel.exception.SystemException {
191         getService().deleteLayouts(groupId, privateLayout);
192     }
193 
194     public static byte[] exportLayouts(long groupId, boolean privateLayout,
195         long[] layoutIds, java.util.Map<String, String[]> parameterMap,
196         java.util.Date startDate, java.util.Date endDate)
197         throws com.liferay.portal.kernel.exception.PortalException,
198             com.liferay.portal.kernel.exception.SystemException {
199         return getService()
200                    .exportLayouts(groupId, privateLayout, layoutIds,
201             parameterMap, startDate, endDate);
202     }
203 
204     public static byte[] exportLayouts(long groupId, boolean privateLayout,
205         java.util.Map<String, String[]> parameterMap, java.util.Date startDate,
206         java.util.Date endDate)
207         throws com.liferay.portal.kernel.exception.PortalException,
208             com.liferay.portal.kernel.exception.SystemException {
209         return getService()
210                    .exportLayouts(groupId, privateLayout, parameterMap,
211             startDate, endDate);
212     }
213 
214     public static java.io.File exportLayoutsAsFile(long groupId,
215         boolean privateLayout, long[] layoutIds,
216         java.util.Map<String, String[]> parameterMap, java.util.Date startDate,
217         java.util.Date endDate)
218         throws com.liferay.portal.kernel.exception.PortalException,
219             com.liferay.portal.kernel.exception.SystemException {
220         return getService()
221                    .exportLayoutsAsFile(groupId, privateLayout, layoutIds,
222             parameterMap, startDate, endDate);
223     }
224 
225     public static byte[] exportPortletInfo(long plid, long groupId,
226         java.lang.String portletId,
227         java.util.Map<String, String[]> parameterMap, java.util.Date startDate,
228         java.util.Date endDate)
229         throws com.liferay.portal.kernel.exception.PortalException,
230             com.liferay.portal.kernel.exception.SystemException {
231         return getService()
232                    .exportPortletInfo(plid, groupId, portletId, parameterMap,
233             startDate, endDate);
234     }
235 
236     public static java.io.File exportPortletInfoAsFile(long plid, long groupId,
237         java.lang.String portletId,
238         java.util.Map<String, String[]> parameterMap, java.util.Date startDate,
239         java.util.Date endDate)
240         throws com.liferay.portal.kernel.exception.PortalException,
241             com.liferay.portal.kernel.exception.SystemException {
242         return getService()
243                    .exportPortletInfoAsFile(plid, groupId, portletId,
244             parameterMap, startDate, endDate);
245     }
246 
247     public static long getDefaultPlid(long groupId)
248         throws com.liferay.portal.kernel.exception.SystemException {
249         return getService().getDefaultPlid(groupId);
250     }
251 
252     public static long getDefaultPlid(long groupId, boolean privateLayout)
253         throws com.liferay.portal.kernel.exception.SystemException {
254         return getService().getDefaultPlid(groupId, privateLayout);
255     }
256 
257     public static long getDefaultPlid(long groupId, boolean privateLayout,
258         java.lang.String portletId)
259         throws com.liferay.portal.kernel.exception.PortalException,
260             com.liferay.portal.kernel.exception.SystemException {
261         return getService().getDefaultPlid(groupId, privateLayout, portletId);
262     }
263 
264     public static com.liferay.portal.model.Layout getDLFolderLayout(
265         long dlFolderId)
266         throws com.liferay.portal.kernel.exception.PortalException,
267             com.liferay.portal.kernel.exception.SystemException {
268         return getService().getDLFolderLayout(dlFolderId);
269     }
270 
271     public static com.liferay.portal.model.Layout getFriendlyURLLayout(
272         long groupId, boolean privateLayout, java.lang.String friendlyURL)
273         throws com.liferay.portal.kernel.exception.PortalException,
274             com.liferay.portal.kernel.exception.SystemException {
275         return getService()
276                    .getFriendlyURLLayout(groupId, privateLayout, friendlyURL);
277     }
278 
279     public static com.liferay.portal.model.Layout getLayout(long groupId,
280         boolean privateLayout, long layoutId)
281         throws com.liferay.portal.kernel.exception.PortalException,
282             com.liferay.portal.kernel.exception.SystemException {
283         return getService().getLayout(groupId, privateLayout, layoutId);
284     }
285 
286     public static com.liferay.portal.model.Layout getLayoutByIconImageId(
287         long iconImageId)
288         throws com.liferay.portal.kernel.exception.PortalException,
289             com.liferay.portal.kernel.exception.SystemException {
290         return getService().getLayoutByIconImageId(iconImageId);
291     }
292 
293     public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
294         long groupId, boolean privateLayout)
295         throws com.liferay.portal.kernel.exception.SystemException {
296         return getService().getLayouts(groupId, privateLayout);
297     }
298 
299     public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
300         long groupId, boolean privateLayout, long parentLayoutId)
301         throws com.liferay.portal.kernel.exception.SystemException {
302         return getService().getLayouts(groupId, privateLayout, parentLayoutId);
303     }
304 
305     public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
306         long groupId, boolean privateLayout, long parentLayoutId, int start,
307         int end) throws com.liferay.portal.kernel.exception.SystemException {
308         return getService()
309                    .getLayouts(groupId, privateLayout, parentLayoutId, start,
310             end);
311     }
312 
313     public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
314         long groupId, boolean privateLayout, long[] layoutIds)
315         throws com.liferay.portal.kernel.exception.PortalException,
316             com.liferay.portal.kernel.exception.SystemException {
317         return getService().getLayouts(groupId, privateLayout, layoutIds);
318     }
319 
320     public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
321         long groupId, boolean privateLayout, java.lang.String type)
322         throws com.liferay.portal.kernel.exception.SystemException {
323         return getService().getLayouts(groupId, privateLayout, type);
324     }
325 
326     public static com.liferay.portal.model.LayoutReference[] getLayouts(
327         long companyId, java.lang.String portletId,
328         java.lang.String preferencesKey, java.lang.String preferencesValue)
329         throws com.liferay.portal.kernel.exception.SystemException {
330         return getService()
331                    .getLayouts(companyId, portletId, preferencesKey,
332             preferencesValue);
333     }
334 
335     public static long getNextLayoutId(long groupId, boolean privateLayout)
336         throws com.liferay.portal.kernel.exception.SystemException {
337         return getService().getNextLayoutId(groupId, privateLayout);
338     }
339 
340     public static java.util.List<com.liferay.portal.model.Layout> getNullFriendlyURLLayouts()
341         throws com.liferay.portal.kernel.exception.SystemException {
342         return getService().getNullFriendlyURLLayouts();
343     }
344 
345     public static boolean hasLayouts(long groupId, boolean privateLayout,
346         long parentLayoutId)
347         throws com.liferay.portal.kernel.exception.SystemException {
348         return getService().hasLayouts(groupId, privateLayout, parentLayoutId);
349     }
350 
351     public static void importLayouts(long userId, long groupId,
352         boolean privateLayout, java.util.Map<String, String[]> parameterMap,
353         byte[] bytes)
354         throws com.liferay.portal.kernel.exception.PortalException,
355             com.liferay.portal.kernel.exception.SystemException {
356         getService()
357             .importLayouts(userId, groupId, privateLayout, parameterMap, bytes);
358     }
359 
360     public static void importLayouts(long userId, long groupId,
361         boolean privateLayout, java.util.Map<String, String[]> parameterMap,
362         java.io.File file)
363         throws com.liferay.portal.kernel.exception.PortalException,
364             com.liferay.portal.kernel.exception.SystemException {
365         getService()
366             .importLayouts(userId, groupId, privateLayout, parameterMap, file);
367     }
368 
369     public static void importLayouts(long userId, long groupId,
370         boolean privateLayout, java.util.Map<String, String[]> parameterMap,
371         java.io.InputStream is)
372         throws com.liferay.portal.kernel.exception.PortalException,
373             com.liferay.portal.kernel.exception.SystemException {
374         getService()
375             .importLayouts(userId, groupId, privateLayout, parameterMap, is);
376     }
377 
378     public static void importPortletInfo(long userId, long plid, long groupId,
379         java.lang.String portletId,
380         java.util.Map<String, String[]> parameterMap, java.io.File file)
381         throws com.liferay.portal.kernel.exception.PortalException,
382             com.liferay.portal.kernel.exception.SystemException {
383         getService()
384             .importPortletInfo(userId, plid, groupId, portletId, parameterMap,
385             file);
386     }
387 
388     public static void importPortletInfo(long userId, long plid, long groupId,
389         java.lang.String portletId,
390         java.util.Map<String, String[]> parameterMap, java.io.InputStream is)
391         throws com.liferay.portal.kernel.exception.PortalException,
392             com.liferay.portal.kernel.exception.SystemException {
393         getService()
394             .importPortletInfo(userId, plid, groupId, portletId, parameterMap,
395             is);
396     }
397 
398     public static void setLayouts(long groupId, boolean privateLayout,
399         long parentLayoutId, long[] layoutIds)
400         throws com.liferay.portal.kernel.exception.PortalException,
401             com.liferay.portal.kernel.exception.SystemException {
402         getService()
403             .setLayouts(groupId, privateLayout, parentLayoutId, layoutIds);
404     }
405 
406     public static com.liferay.portal.model.Layout updateFriendlyURL(long plid,
407         java.lang.String friendlyURL)
408         throws com.liferay.portal.kernel.exception.PortalException,
409             com.liferay.portal.kernel.exception.SystemException {
410         return getService().updateFriendlyURL(plid, friendlyURL);
411     }
412 
413     public static com.liferay.portal.model.Layout updateLayout(long groupId,
414         boolean privateLayout, long layoutId, long parentLayoutId,
415         java.util.Map<java.util.Locale, String> localeNamesMap,
416         java.util.Map<java.util.Locale, String> localeTitlesMap,
417         java.lang.String description, java.lang.String type, boolean hidden,
418         java.lang.String friendlyURL, java.lang.Boolean iconImage,
419         byte[] iconBytes,
420         com.liferay.portal.service.ServiceContext serviceContext)
421         throws com.liferay.portal.kernel.exception.PortalException,
422             com.liferay.portal.kernel.exception.SystemException {
423         return getService()
424                    .updateLayout(groupId, privateLayout, layoutId,
425             parentLayoutId, localeNamesMap, localeTitlesMap, description, type,
426             hidden, friendlyURL, iconImage, iconBytes, serviceContext);
427     }
428 
429     public static com.liferay.portal.model.Layout updateLayout(long groupId,
430         boolean privateLayout, long layoutId, long parentLayoutId,
431         java.util.Map<java.util.Locale, String> localeNamesMap,
432         java.util.Map<java.util.Locale, String> localeTitlesMap,
433         java.lang.String description, java.lang.String type, boolean hidden,
434         java.lang.String friendlyURL,
435         com.liferay.portal.service.ServiceContext serviceContext)
436         throws com.liferay.portal.kernel.exception.PortalException,
437             com.liferay.portal.kernel.exception.SystemException {
438         return getService()
439                    .updateLayout(groupId, privateLayout, layoutId,
440             parentLayoutId, localeNamesMap, localeTitlesMap, description, type,
441             hidden, friendlyURL, serviceContext);
442     }
443 
444     public static com.liferay.portal.model.Layout updateLayout(long groupId,
445         boolean privateLayout, long layoutId, java.lang.String typeSettings)
446         throws com.liferay.portal.kernel.exception.PortalException,
447             com.liferay.portal.kernel.exception.SystemException {
448         return getService()
449                    .updateLayout(groupId, privateLayout, layoutId, typeSettings);
450     }
451 
452     public static com.liferay.portal.model.Layout updateLookAndFeel(
453         long groupId, boolean privateLayout, long layoutId,
454         java.lang.String themeId, java.lang.String colorSchemeId,
455         java.lang.String css, boolean wapTheme)
456         throws com.liferay.portal.kernel.exception.PortalException,
457             com.liferay.portal.kernel.exception.SystemException {
458         return getService()
459                    .updateLookAndFeel(groupId, privateLayout, layoutId,
460             themeId, colorSchemeId, css, wapTheme);
461     }
462 
463     public static com.liferay.portal.model.Layout updateName(
464         com.liferay.portal.model.Layout layout, java.lang.String name,
465         java.lang.String languageId)
466         throws com.liferay.portal.kernel.exception.PortalException,
467             com.liferay.portal.kernel.exception.SystemException {
468         return getService().updateName(layout, name, languageId);
469     }
470 
471     public static com.liferay.portal.model.Layout updateName(long groupId,
472         boolean privateLayout, long layoutId, java.lang.String name,
473         java.lang.String languageId)
474         throws com.liferay.portal.kernel.exception.PortalException,
475             com.liferay.portal.kernel.exception.SystemException {
476         return getService()
477                    .updateName(groupId, privateLayout, layoutId, name,
478             languageId);
479     }
480 
481     public static com.liferay.portal.model.Layout updateName(long plid,
482         java.lang.String name, java.lang.String languageId)
483         throws com.liferay.portal.kernel.exception.PortalException,
484             com.liferay.portal.kernel.exception.SystemException {
485         return getService().updateName(plid, name, languageId);
486     }
487 
488     public static com.liferay.portal.model.Layout updateParentLayoutId(
489         long groupId, boolean privateLayout, long layoutId, long parentLayoutId)
490         throws com.liferay.portal.kernel.exception.PortalException,
491             com.liferay.portal.kernel.exception.SystemException {
492         return getService()
493                    .updateParentLayoutId(groupId, privateLayout, layoutId,
494             parentLayoutId);
495     }
496 
497     public static com.liferay.portal.model.Layout updateParentLayoutId(
498         long plid, long parentPlid)
499         throws com.liferay.portal.kernel.exception.PortalException,
500             com.liferay.portal.kernel.exception.SystemException {
501         return getService().updateParentLayoutId(plid, parentPlid);
502     }
503 
504     public static com.liferay.portal.model.Layout updatePriority(
505         com.liferay.portal.model.Layout layout, int priority)
506         throws com.liferay.portal.kernel.exception.SystemException {
507         return getService().updatePriority(layout, priority);
508     }
509 
510     public static com.liferay.portal.model.Layout updatePriority(long groupId,
511         boolean privateLayout, long layoutId, int priority)
512         throws com.liferay.portal.kernel.exception.PortalException,
513             com.liferay.portal.kernel.exception.SystemException {
514         return getService()
515                    .updatePriority(groupId, privateLayout, layoutId, priority);
516     }
517 
518     public static com.liferay.portal.model.Layout updatePriority(long plid,
519         int priority)
520         throws com.liferay.portal.kernel.exception.PortalException,
521             com.liferay.portal.kernel.exception.SystemException {
522         return getService().updatePriority(plid, priority);
523     }
524 
525     public static LayoutLocalService getService() {
526         if (_service == null) {
527             _service = (LayoutLocalService)PortalBeanLocatorUtil.locate(LayoutLocalService.class.getName());
528         }
529 
530         return _service;
531     }
532 
533     public void setService(LayoutLocalService service) {
534         _service = service;
535     }
536 
537     private static LayoutLocalService _service;
538 }