001    /**
002     * Copyright (c) 2000-2010 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;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    
019    /**
020     * <p>
021     * This class provides static methods for the
022     * {@link LayoutLocalService} bean. The static methods of
023     * this class calls the same methods of the bean instance. It's convenient to be
024     * able to just write one line to call a method on a bean instead of writing a
025     * lookup call and a method call.
026     * </p>
027     *
028     * @author    Brian Wing Shun Chan
029     * @see       LayoutLocalService
030     * @generated
031     */
032    public class LayoutLocalServiceUtil {
033            public static com.liferay.portal.model.Layout addLayout(
034                    com.liferay.portal.model.Layout layout)
035                    throws com.liferay.portal.kernel.exception.SystemException {
036                    return getService().addLayout(layout);
037            }
038    
039            public static com.liferay.portal.model.Layout createLayout(long plid) {
040                    return getService().createLayout(plid);
041            }
042    
043            public static void deleteLayout(long plid)
044                    throws com.liferay.portal.kernel.exception.PortalException,
045                            com.liferay.portal.kernel.exception.SystemException {
046                    getService().deleteLayout(plid);
047            }
048    
049            public static void deleteLayout(com.liferay.portal.model.Layout layout)
050                    throws com.liferay.portal.kernel.exception.SystemException {
051                    getService().deleteLayout(layout);
052            }
053    
054            @SuppressWarnings("unchecked")
055            public static java.util.List dynamicQuery(
056                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
057                    throws com.liferay.portal.kernel.exception.SystemException {
058                    return getService().dynamicQuery(dynamicQuery);
059            }
060    
061            @SuppressWarnings("unchecked")
062            public static java.util.List dynamicQuery(
063                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
064                    int end) throws com.liferay.portal.kernel.exception.SystemException {
065                    return getService().dynamicQuery(dynamicQuery, start, end);
066            }
067    
068            @SuppressWarnings("unchecked")
069            public static java.util.List dynamicQuery(
070                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
071                    int end,
072                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
073                    throws com.liferay.portal.kernel.exception.SystemException {
074                    return getService()
075                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
076            }
077    
078            public static long dynamicQueryCount(
079                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
080                    throws com.liferay.portal.kernel.exception.SystemException {
081                    return getService().dynamicQueryCount(dynamicQuery);
082            }
083    
084            public static com.liferay.portal.model.Layout getLayout(long plid)
085                    throws com.liferay.portal.kernel.exception.PortalException,
086                            com.liferay.portal.kernel.exception.SystemException {
087                    return getService().getLayout(plid);
088            }
089    
090            public static com.liferay.portal.model.Layout getLayoutByUuidAndGroupId(
091                    java.lang.String uuid, long groupId)
092                    throws com.liferay.portal.kernel.exception.PortalException,
093                            com.liferay.portal.kernel.exception.SystemException {
094                    return getService().getLayoutByUuidAndGroupId(uuid, groupId);
095            }
096    
097            public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
098                    int start, int end)
099                    throws com.liferay.portal.kernel.exception.SystemException {
100                    return getService().getLayouts(start, end);
101            }
102    
103            public static int getLayoutsCount()
104                    throws com.liferay.portal.kernel.exception.SystemException {
105                    return getService().getLayoutsCount();
106            }
107    
108            public static com.liferay.portal.model.Layout updateLayout(
109                    com.liferay.portal.model.Layout layout)
110                    throws com.liferay.portal.kernel.exception.SystemException {
111                    return getService().updateLayout(layout);
112            }
113    
114            public static com.liferay.portal.model.Layout updateLayout(
115                    com.liferay.portal.model.Layout layout, boolean merge)
116                    throws com.liferay.portal.kernel.exception.SystemException {
117                    return getService().updateLayout(layout, merge);
118            }
119    
120            public static com.liferay.portal.model.Layout addLayout(long userId,
121                    long groupId, boolean privateLayout, long parentLayoutId,
122                    java.util.Map<java.util.Locale, java.lang.String> localeNamesMap,
123                    java.util.Map<java.util.Locale, java.lang.String> localeTitlesMap,
124                    java.lang.String description, java.lang.String type, boolean hidden,
125                    java.lang.String friendlyURL, long dlFolderId,
126                    com.liferay.portal.service.ServiceContext serviceContext)
127                    throws com.liferay.portal.kernel.exception.PortalException,
128                            com.liferay.portal.kernel.exception.SystemException {
129                    return getService()
130                                       .addLayout(userId, groupId, privateLayout, parentLayoutId,
131                            localeNamesMap, localeTitlesMap, description, type, hidden,
132                            friendlyURL, dlFolderId, serviceContext);
133            }
134    
135            public static com.liferay.portal.model.Layout addLayout(long userId,
136                    long groupId, boolean privateLayout, long parentLayoutId,
137                    java.util.Map<java.util.Locale, java.lang.String> localeNamesMap,
138                    java.util.Map<java.util.Locale, java.lang.String> localeTitlesMap,
139                    java.lang.String description, java.lang.String type, boolean hidden,
140                    java.lang.String friendlyURL,
141                    com.liferay.portal.service.ServiceContext serviceContext)
142                    throws com.liferay.portal.kernel.exception.PortalException,
143                            com.liferay.portal.kernel.exception.SystemException {
144                    return getService()
145                                       .addLayout(userId, groupId, privateLayout, parentLayoutId,
146                            localeNamesMap, localeTitlesMap, description, type, hidden,
147                            friendlyURL, serviceContext);
148            }
149    
150            public static com.liferay.portal.model.Layout addLayout(long userId,
151                    long groupId, boolean privateLayout, long parentLayoutId,
152                    java.lang.String name, java.lang.String title,
153                    java.lang.String description, java.lang.String type, boolean hidden,
154                    java.lang.String friendlyURL, long dlFolderId,
155                    com.liferay.portal.service.ServiceContext serviceContext)
156                    throws com.liferay.portal.kernel.exception.PortalException,
157                            com.liferay.portal.kernel.exception.SystemException {
158                    return getService()
159                                       .addLayout(userId, groupId, privateLayout, parentLayoutId,
160                            name, title, description, type, hidden, friendlyURL, dlFolderId,
161                            serviceContext);
162            }
163    
164            public static com.liferay.portal.model.Layout addLayout(long userId,
165                    long groupId, boolean privateLayout, long parentLayoutId,
166                    java.lang.String name, java.lang.String title,
167                    java.lang.String description, java.lang.String type, boolean hidden,
168                    java.lang.String friendlyURL,
169                    com.liferay.portal.service.ServiceContext serviceContext)
170                    throws com.liferay.portal.kernel.exception.PortalException,
171                            com.liferay.portal.kernel.exception.SystemException {
172                    return getService()
173                                       .addLayout(userId, groupId, privateLayout, parentLayoutId,
174                            name, title, description, type, hidden, friendlyURL, serviceContext);
175            }
176    
177            public static void deleteLayout(com.liferay.portal.model.Layout layout,
178                    boolean updateLayoutSet)
179                    throws com.liferay.portal.kernel.exception.PortalException,
180                            com.liferay.portal.kernel.exception.SystemException {
181                    getService().deleteLayout(layout, updateLayoutSet);
182            }
183    
184            public static void deleteLayout(long groupId, boolean privateLayout,
185                    long layoutId)
186                    throws com.liferay.portal.kernel.exception.PortalException,
187                            com.liferay.portal.kernel.exception.SystemException {
188                    getService().deleteLayout(groupId, privateLayout, layoutId);
189            }
190    
191            public static void deleteLayouts(long groupId, boolean privateLayout)
192                    throws com.liferay.portal.kernel.exception.PortalException,
193                            com.liferay.portal.kernel.exception.SystemException {
194                    getService().deleteLayouts(groupId, privateLayout);
195            }
196    
197            public static byte[] exportLayouts(long groupId, boolean privateLayout,
198                    long[] layoutIds,
199                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
200                    java.util.Date startDate, java.util.Date endDate)
201                    throws com.liferay.portal.kernel.exception.PortalException,
202                            com.liferay.portal.kernel.exception.SystemException {
203                    return getService()
204                                       .exportLayouts(groupId, privateLayout, layoutIds,
205                            parameterMap, startDate, endDate);
206            }
207    
208            public static byte[] exportLayouts(long groupId, boolean privateLayout,
209                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
210                    java.util.Date startDate, java.util.Date endDate)
211                    throws com.liferay.portal.kernel.exception.PortalException,
212                            com.liferay.portal.kernel.exception.SystemException {
213                    return getService()
214                                       .exportLayouts(groupId, privateLayout, parameterMap,
215                            startDate, endDate);
216            }
217    
218            public static java.io.File exportLayoutsAsFile(long groupId,
219                    boolean privateLayout, long[] layoutIds,
220                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
221                    java.util.Date startDate, java.util.Date endDate)
222                    throws com.liferay.portal.kernel.exception.PortalException,
223                            com.liferay.portal.kernel.exception.SystemException {
224                    return getService()
225                                       .exportLayoutsAsFile(groupId, privateLayout, layoutIds,
226                            parameterMap, startDate, endDate);
227            }
228    
229            public static byte[] exportPortletInfo(long plid, long groupId,
230                    java.lang.String portletId,
231                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
232                    java.util.Date startDate, java.util.Date endDate)
233                    throws com.liferay.portal.kernel.exception.PortalException,
234                            com.liferay.portal.kernel.exception.SystemException {
235                    return getService()
236                                       .exportPortletInfo(plid, groupId, portletId, parameterMap,
237                            startDate, endDate);
238            }
239    
240            public static java.io.File exportPortletInfoAsFile(long plid, long groupId,
241                    java.lang.String portletId,
242                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
243                    java.util.Date startDate, java.util.Date endDate)
244                    throws com.liferay.portal.kernel.exception.PortalException,
245                            com.liferay.portal.kernel.exception.SystemException {
246                    return getService()
247                                       .exportPortletInfoAsFile(plid, groupId, portletId,
248                            parameterMap, startDate, endDate);
249            }
250    
251            public static long getDefaultPlid(long groupId)
252                    throws com.liferay.portal.kernel.exception.SystemException {
253                    return getService().getDefaultPlid(groupId);
254            }
255    
256            public static long getDefaultPlid(long groupId, boolean privateLayout)
257                    throws com.liferay.portal.kernel.exception.SystemException {
258                    return getService().getDefaultPlid(groupId, privateLayout);
259            }
260    
261            public static long getDefaultPlid(long groupId, boolean privateLayout,
262                    java.lang.String portletId)
263                    throws com.liferay.portal.kernel.exception.PortalException,
264                            com.liferay.portal.kernel.exception.SystemException {
265                    return getService().getDefaultPlid(groupId, privateLayout, portletId);
266            }
267    
268            public static com.liferay.portal.model.Layout getDLFolderLayout(
269                    long dlFolderId)
270                    throws com.liferay.portal.kernel.exception.PortalException,
271                            com.liferay.portal.kernel.exception.SystemException {
272                    return getService().getDLFolderLayout(dlFolderId);
273            }
274    
275            public static com.liferay.portal.model.Layout getFriendlyURLLayout(
276                    long groupId, boolean privateLayout, java.lang.String friendlyURL)
277                    throws com.liferay.portal.kernel.exception.PortalException,
278                            com.liferay.portal.kernel.exception.SystemException {
279                    return getService()
280                                       .getFriendlyURLLayout(groupId, privateLayout, friendlyURL);
281            }
282    
283            public static com.liferay.portal.model.Layout getLayout(long groupId,
284                    boolean privateLayout, long layoutId)
285                    throws com.liferay.portal.kernel.exception.PortalException,
286                            com.liferay.portal.kernel.exception.SystemException {
287                    return getService().getLayout(groupId, privateLayout, layoutId);
288            }
289    
290            public static com.liferay.portal.model.Layout getLayoutByIconImageId(
291                    long iconImageId)
292                    throws com.liferay.portal.kernel.exception.PortalException,
293                            com.liferay.portal.kernel.exception.SystemException {
294                    return getService().getLayoutByIconImageId(iconImageId);
295            }
296    
297            public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
298                    long groupId, boolean privateLayout)
299                    throws com.liferay.portal.kernel.exception.SystemException {
300                    return getService().getLayouts(groupId, privateLayout);
301            }
302    
303            public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
304                    long groupId, boolean privateLayout, long parentLayoutId)
305                    throws com.liferay.portal.kernel.exception.SystemException {
306                    return getService().getLayouts(groupId, privateLayout, parentLayoutId);
307            }
308    
309            public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
310                    long groupId, boolean privateLayout, long parentLayoutId, int start,
311                    int end) throws com.liferay.portal.kernel.exception.SystemException {
312                    return getService()
313                                       .getLayouts(groupId, privateLayout, parentLayoutId, start,
314                            end);
315            }
316    
317            public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
318                    long groupId, boolean privateLayout, long[] layoutIds)
319                    throws com.liferay.portal.kernel.exception.PortalException,
320                            com.liferay.portal.kernel.exception.SystemException {
321                    return getService().getLayouts(groupId, privateLayout, layoutIds);
322            }
323    
324            public static java.util.List<com.liferay.portal.model.Layout> getLayouts(
325                    long groupId, boolean privateLayout, java.lang.String type)
326                    throws com.liferay.portal.kernel.exception.SystemException {
327                    return getService().getLayouts(groupId, privateLayout, type);
328            }
329    
330            public static com.liferay.portal.model.LayoutReference[] getLayouts(
331                    long companyId, java.lang.String portletId,
332                    java.lang.String preferencesKey, java.lang.String preferencesValue)
333                    throws com.liferay.portal.kernel.exception.SystemException {
334                    return getService()
335                                       .getLayouts(companyId, portletId, preferencesKey,
336                            preferencesValue);
337            }
338    
339            public static long getNextLayoutId(long groupId, boolean privateLayout)
340                    throws com.liferay.portal.kernel.exception.SystemException {
341                    return getService().getNextLayoutId(groupId, privateLayout);
342            }
343    
344            public static java.util.List<com.liferay.portal.model.Layout> getNullFriendlyURLLayouts()
345                    throws com.liferay.portal.kernel.exception.SystemException {
346                    return getService().getNullFriendlyURLLayouts();
347            }
348    
349            public static boolean hasLayouts(long groupId, boolean privateLayout,
350                    long parentLayoutId)
351                    throws com.liferay.portal.kernel.exception.SystemException {
352                    return getService().hasLayouts(groupId, privateLayout, parentLayoutId);
353            }
354    
355            public static void importLayouts(long userId, long groupId,
356                    boolean privateLayout,
357                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
358                    byte[] bytes)
359                    throws com.liferay.portal.kernel.exception.PortalException,
360                            com.liferay.portal.kernel.exception.SystemException {
361                    getService()
362                            .importLayouts(userId, groupId, privateLayout, parameterMap, bytes);
363            }
364    
365            public static void importLayouts(long userId, long groupId,
366                    boolean privateLayout,
367                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
368                    java.io.File file)
369                    throws com.liferay.portal.kernel.exception.PortalException,
370                            com.liferay.portal.kernel.exception.SystemException {
371                    getService()
372                            .importLayouts(userId, groupId, privateLayout, parameterMap, file);
373            }
374    
375            public static void importLayouts(long userId, long groupId,
376                    boolean privateLayout,
377                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
378                    java.io.InputStream is)
379                    throws com.liferay.portal.kernel.exception.PortalException,
380                            com.liferay.portal.kernel.exception.SystemException {
381                    getService()
382                            .importLayouts(userId, groupId, privateLayout, parameterMap, is);
383            }
384    
385            public static void importPortletInfo(long userId, long plid, long groupId,
386                    java.lang.String portletId,
387                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
388                    java.io.File file)
389                    throws com.liferay.portal.kernel.exception.PortalException,
390                            com.liferay.portal.kernel.exception.SystemException {
391                    getService()
392                            .importPortletInfo(userId, plid, groupId, portletId, parameterMap,
393                            file);
394            }
395    
396            public static void importPortletInfo(long userId, long plid, long groupId,
397                    java.lang.String portletId,
398                    java.util.Map<java.lang.String, java.lang.String[]> parameterMap,
399                    java.io.InputStream is)
400                    throws com.liferay.portal.kernel.exception.PortalException,
401                            com.liferay.portal.kernel.exception.SystemException {
402                    getService()
403                            .importPortletInfo(userId, plid, groupId, portletId, parameterMap,
404                            is);
405            }
406    
407            public static void setLayouts(long groupId, boolean privateLayout,
408                    long parentLayoutId, long[] layoutIds)
409                    throws com.liferay.portal.kernel.exception.PortalException,
410                            com.liferay.portal.kernel.exception.SystemException {
411                    getService()
412                            .setLayouts(groupId, privateLayout, parentLayoutId, layoutIds);
413            }
414    
415            public static com.liferay.portal.model.Layout updateFriendlyURL(long plid,
416                    java.lang.String friendlyURL)
417                    throws com.liferay.portal.kernel.exception.PortalException,
418                            com.liferay.portal.kernel.exception.SystemException {
419                    return getService().updateFriendlyURL(plid, friendlyURL);
420            }
421    
422            public static com.liferay.portal.model.Layout updateLayout(long groupId,
423                    boolean privateLayout, long layoutId, long parentLayoutId,
424                    java.util.Map<java.util.Locale, java.lang.String> localeNamesMap,
425                    java.util.Map<java.util.Locale, java.lang.String> localeTitlesMap,
426                    java.lang.String description, java.lang.String type, boolean hidden,
427                    java.lang.String friendlyURL, java.lang.Boolean iconImage,
428                    byte[] iconBytes,
429                    com.liferay.portal.service.ServiceContext serviceContext)
430                    throws com.liferay.portal.kernel.exception.PortalException,
431                            com.liferay.portal.kernel.exception.SystemException {
432                    return getService()
433                                       .updateLayout(groupId, privateLayout, layoutId,
434                            parentLayoutId, localeNamesMap, localeTitlesMap, description, type,
435                            hidden, friendlyURL, iconImage, iconBytes, serviceContext);
436            }
437    
438            public static com.liferay.portal.model.Layout updateLayout(long groupId,
439                    boolean privateLayout, long layoutId, long parentLayoutId,
440                    java.util.Map<java.util.Locale, java.lang.String> localeNamesMap,
441                    java.util.Map<java.util.Locale, java.lang.String> localeTitlesMap,
442                    java.lang.String description, java.lang.String type, boolean hidden,
443                    java.lang.String friendlyURL,
444                    com.liferay.portal.service.ServiceContext serviceContext)
445                    throws com.liferay.portal.kernel.exception.PortalException,
446                            com.liferay.portal.kernel.exception.SystemException {
447                    return getService()
448                                       .updateLayout(groupId, privateLayout, layoutId,
449                            parentLayoutId, localeNamesMap, localeTitlesMap, description, type,
450                            hidden, friendlyURL, serviceContext);
451            }
452    
453            public static com.liferay.portal.model.Layout updateLayout(long groupId,
454                    boolean privateLayout, long layoutId, java.lang.String typeSettings)
455                    throws com.liferay.portal.kernel.exception.PortalException,
456                            com.liferay.portal.kernel.exception.SystemException {
457                    return getService()
458                                       .updateLayout(groupId, privateLayout, layoutId, typeSettings);
459            }
460    
461            public static com.liferay.portal.model.Layout updateLookAndFeel(
462                    long groupId, boolean privateLayout, long layoutId,
463                    java.lang.String themeId, java.lang.String colorSchemeId,
464                    java.lang.String css, boolean wapTheme)
465                    throws com.liferay.portal.kernel.exception.PortalException,
466                            com.liferay.portal.kernel.exception.SystemException {
467                    return getService()
468                                       .updateLookAndFeel(groupId, privateLayout, layoutId,
469                            themeId, colorSchemeId, css, wapTheme);
470            }
471    
472            public static com.liferay.portal.model.Layout updateName(
473                    com.liferay.portal.model.Layout layout, java.lang.String name,
474                    java.lang.String languageId)
475                    throws com.liferay.portal.kernel.exception.PortalException,
476                            com.liferay.portal.kernel.exception.SystemException {
477                    return getService().updateName(layout, name, languageId);
478            }
479    
480            public static com.liferay.portal.model.Layout updateName(long groupId,
481                    boolean privateLayout, long layoutId, java.lang.String name,
482                    java.lang.String languageId)
483                    throws com.liferay.portal.kernel.exception.PortalException,
484                            com.liferay.portal.kernel.exception.SystemException {
485                    return getService()
486                                       .updateName(groupId, privateLayout, layoutId, name,
487                            languageId);
488            }
489    
490            public static com.liferay.portal.model.Layout updateName(long plid,
491                    java.lang.String name, java.lang.String languageId)
492                    throws com.liferay.portal.kernel.exception.PortalException,
493                            com.liferay.portal.kernel.exception.SystemException {
494                    return getService().updateName(plid, name, languageId);
495            }
496    
497            public static com.liferay.portal.model.Layout updateParentLayoutId(
498                    long groupId, boolean privateLayout, long layoutId, long parentLayoutId)
499                    throws com.liferay.portal.kernel.exception.PortalException,
500                            com.liferay.portal.kernel.exception.SystemException {
501                    return getService()
502                                       .updateParentLayoutId(groupId, privateLayout, layoutId,
503                            parentLayoutId);
504            }
505    
506            public static com.liferay.portal.model.Layout updateParentLayoutId(
507                    long plid, long parentPlid)
508                    throws com.liferay.portal.kernel.exception.PortalException,
509                            com.liferay.portal.kernel.exception.SystemException {
510                    return getService().updateParentLayoutId(plid, parentPlid);
511            }
512    
513            public static com.liferay.portal.model.Layout updatePriority(
514                    com.liferay.portal.model.Layout layout, int priority)
515                    throws com.liferay.portal.kernel.exception.SystemException {
516                    return getService().updatePriority(layout, priority);
517            }
518    
519            public static com.liferay.portal.model.Layout updatePriority(long groupId,
520                    boolean privateLayout, long layoutId, int priority)
521                    throws com.liferay.portal.kernel.exception.PortalException,
522                            com.liferay.portal.kernel.exception.SystemException {
523                    return getService()
524                                       .updatePriority(groupId, privateLayout, layoutId, priority);
525            }
526    
527            public static com.liferay.portal.model.Layout updatePriority(long plid,
528                    int priority)
529                    throws com.liferay.portal.kernel.exception.PortalException,
530                            com.liferay.portal.kernel.exception.SystemException {
531                    return getService().updatePriority(plid, priority);
532            }
533    
534            public static LayoutLocalService getService() {
535                    if (_service == null) {
536                            _service = (LayoutLocalService)PortalBeanLocatorUtil.locate(LayoutLocalService.class.getName());
537                    }
538    
539                    return _service;
540            }
541    
542            public void setService(LayoutLocalService service) {
543                    _service = service;
544            }
545    
546            private static LayoutLocalService _service;
547    }