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.portlet.bookmarks.service;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  
19  /**
20   * <a href="BookmarksFolderLocalServiceUtil.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 BookmarksFolderLocalService} 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       BookmarksFolderLocalService
37   * @generated
38   */
39  public class BookmarksFolderLocalServiceUtil {
40      public static com.liferay.portlet.bookmarks.model.BookmarksFolder addBookmarksFolder(
41          com.liferay.portlet.bookmarks.model.BookmarksFolder bookmarksFolder)
42          throws com.liferay.portal.kernel.exception.SystemException {
43          return getService().addBookmarksFolder(bookmarksFolder);
44      }
45  
46      public static com.liferay.portlet.bookmarks.model.BookmarksFolder createBookmarksFolder(
47          long folderId) {
48          return getService().createBookmarksFolder(folderId);
49      }
50  
51      public static void deleteBookmarksFolder(long folderId)
52          throws com.liferay.portal.kernel.exception.PortalException,
53              com.liferay.portal.kernel.exception.SystemException {
54          getService().deleteBookmarksFolder(folderId);
55      }
56  
57      public static void deleteBookmarksFolder(
58          com.liferay.portlet.bookmarks.model.BookmarksFolder bookmarksFolder)
59          throws com.liferay.portal.kernel.exception.SystemException {
60          getService().deleteBookmarksFolder(bookmarksFolder);
61      }
62  
63      @SuppressWarnings("unchecked")
64      public static java.util.List dynamicQuery(
65          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
66          throws com.liferay.portal.kernel.exception.SystemException {
67          return getService().dynamicQuery(dynamicQuery);
68      }
69  
70      @SuppressWarnings("unchecked")
71      public static java.util.List dynamicQuery(
72          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
73          int end) throws com.liferay.portal.kernel.exception.SystemException {
74          return getService().dynamicQuery(dynamicQuery, start, end);
75      }
76  
77      @SuppressWarnings("unchecked")
78      public static java.util.List dynamicQuery(
79          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
80          int end,
81          com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
82          throws com.liferay.portal.kernel.exception.SystemException {
83          return getService()
84                     .dynamicQuery(dynamicQuery, start, end, orderByComparator);
85      }
86  
87      public static long dynamicQueryCount(
88          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
89          throws com.liferay.portal.kernel.exception.SystemException {
90          return getService().dynamicQueryCount(dynamicQuery);
91      }
92  
93      public static com.liferay.portlet.bookmarks.model.BookmarksFolder getBookmarksFolder(
94          long folderId)
95          throws com.liferay.portal.kernel.exception.PortalException,
96              com.liferay.portal.kernel.exception.SystemException {
97          return getService().getBookmarksFolder(folderId);
98      }
99  
100     public static com.liferay.portlet.bookmarks.model.BookmarksFolder getBookmarksFolderByUuidAndGroupId(
101         java.lang.String uuid, long groupId)
102         throws com.liferay.portal.kernel.exception.PortalException,
103             com.liferay.portal.kernel.exception.SystemException {
104         return getService().getBookmarksFolderByUuidAndGroupId(uuid, groupId);
105     }
106 
107     public static java.util.List<com.liferay.portlet.bookmarks.model.BookmarksFolder> getBookmarksFolders(
108         int start, int end)
109         throws com.liferay.portal.kernel.exception.SystemException {
110         return getService().getBookmarksFolders(start, end);
111     }
112 
113     public static int getBookmarksFoldersCount()
114         throws com.liferay.portal.kernel.exception.SystemException {
115         return getService().getBookmarksFoldersCount();
116     }
117 
118     public static com.liferay.portlet.bookmarks.model.BookmarksFolder updateBookmarksFolder(
119         com.liferay.portlet.bookmarks.model.BookmarksFolder bookmarksFolder)
120         throws com.liferay.portal.kernel.exception.SystemException {
121         return getService().updateBookmarksFolder(bookmarksFolder);
122     }
123 
124     public static com.liferay.portlet.bookmarks.model.BookmarksFolder updateBookmarksFolder(
125         com.liferay.portlet.bookmarks.model.BookmarksFolder bookmarksFolder,
126         boolean merge)
127         throws com.liferay.portal.kernel.exception.SystemException {
128         return getService().updateBookmarksFolder(bookmarksFolder, merge);
129     }
130 
131     public static com.liferay.portlet.bookmarks.model.BookmarksFolder addFolder(
132         java.lang.String uuid, long userId, long parentFolderId,
133         java.lang.String name, java.lang.String description,
134         com.liferay.portal.service.ServiceContext serviceContext)
135         throws com.liferay.portal.kernel.exception.PortalException,
136             com.liferay.portal.kernel.exception.SystemException {
137         return getService()
138                    .addFolder(uuid, userId, parentFolderId, name, description,
139             serviceContext);
140     }
141 
142     public static void addFolderResources(
143         com.liferay.portlet.bookmarks.model.BookmarksFolder folder,
144         boolean addCommunityPermissions, boolean addGuestPermissions)
145         throws com.liferay.portal.kernel.exception.PortalException,
146             com.liferay.portal.kernel.exception.SystemException {
147         getService()
148             .addFolderResources(folder, addCommunityPermissions,
149             addGuestPermissions);
150     }
151 
152     public static void addFolderResources(
153         com.liferay.portlet.bookmarks.model.BookmarksFolder folder,
154         java.lang.String[] communityPermissions,
155         java.lang.String[] guestPermissions)
156         throws com.liferay.portal.kernel.exception.PortalException,
157             com.liferay.portal.kernel.exception.SystemException {
158         getService()
159             .addFolderResources(folder, communityPermissions, guestPermissions);
160     }
161 
162     public static void addFolderResources(long folderId,
163         boolean addCommunityPermissions, boolean addGuestPermissions)
164         throws com.liferay.portal.kernel.exception.PortalException,
165             com.liferay.portal.kernel.exception.SystemException {
166         getService()
167             .addFolderResources(folderId, addCommunityPermissions,
168             addGuestPermissions);
169     }
170 
171     public static void addFolderResources(long folderId,
172         java.lang.String[] communityPermissions,
173         java.lang.String[] guestPermissions)
174         throws com.liferay.portal.kernel.exception.PortalException,
175             com.liferay.portal.kernel.exception.SystemException {
176         getService()
177             .addFolderResources(folderId, communityPermissions, guestPermissions);
178     }
179 
180     public static void deleteFolder(
181         com.liferay.portlet.bookmarks.model.BookmarksFolder folder)
182         throws com.liferay.portal.kernel.exception.PortalException,
183             com.liferay.portal.kernel.exception.SystemException {
184         getService().deleteFolder(folder);
185     }
186 
187     public static void deleteFolder(long folderId)
188         throws com.liferay.portal.kernel.exception.PortalException,
189             com.liferay.portal.kernel.exception.SystemException {
190         getService().deleteFolder(folderId);
191     }
192 
193     public static void deleteFolders(long groupId)
194         throws com.liferay.portal.kernel.exception.PortalException,
195             com.liferay.portal.kernel.exception.SystemException {
196         getService().deleteFolders(groupId);
197     }
198 
199     public static java.util.List<com.liferay.portlet.bookmarks.model.BookmarksFolder> getCompanyFolders(
200         long companyId, int start, int end)
201         throws com.liferay.portal.kernel.exception.SystemException {
202         return getService().getCompanyFolders(companyId, start, end);
203     }
204 
205     public static int getCompanyFoldersCount(long companyId)
206         throws com.liferay.portal.kernel.exception.SystemException {
207         return getService().getCompanyFoldersCount(companyId);
208     }
209 
210     public static com.liferay.portlet.bookmarks.model.BookmarksFolder getFolder(
211         long folderId)
212         throws com.liferay.portal.kernel.exception.PortalException,
213             com.liferay.portal.kernel.exception.SystemException {
214         return getService().getFolder(folderId);
215     }
216 
217     public static java.util.List<com.liferay.portlet.bookmarks.model.BookmarksFolder> getFolders(
218         long groupId)
219         throws com.liferay.portal.kernel.exception.SystemException {
220         return getService().getFolders(groupId);
221     }
222 
223     public static java.util.List<com.liferay.portlet.bookmarks.model.BookmarksFolder> getFolders(
224         long groupId, long parentFolderId)
225         throws com.liferay.portal.kernel.exception.SystemException {
226         return getService().getFolders(groupId, parentFolderId);
227     }
228 
229     public static java.util.List<com.liferay.portlet.bookmarks.model.BookmarksFolder> getFolders(
230         long groupId, long parentFolderId, int start, int end)
231         throws com.liferay.portal.kernel.exception.SystemException {
232         return getService().getFolders(groupId, parentFolderId, start, end);
233     }
234 
235     public static int getFoldersCount(long groupId, long parentFolderId)
236         throws com.liferay.portal.kernel.exception.SystemException {
237         return getService().getFoldersCount(groupId, parentFolderId);
238     }
239 
240     public static void getSubfolderIds(
241         java.util.List<java.lang.Long> folderIds, long groupId, long folderId)
242         throws com.liferay.portal.kernel.exception.SystemException {
243         getService().getSubfolderIds(folderIds, groupId, folderId);
244     }
245 
246     public static com.liferay.portlet.bookmarks.model.BookmarksFolder updateFolder(
247         long folderId, long parentFolderId, java.lang.String name,
248         java.lang.String description, boolean mergeWithParentFolder,
249         com.liferay.portal.service.ServiceContext serviceContext)
250         throws com.liferay.portal.kernel.exception.PortalException,
251             com.liferay.portal.kernel.exception.SystemException {
252         return getService()
253                    .updateFolder(folderId, parentFolderId, name, description,
254             mergeWithParentFolder, serviceContext);
255     }
256 
257     public static BookmarksFolderLocalService getService() {
258         if (_service == null) {
259             _service = (BookmarksFolderLocalService)PortalBeanLocatorUtil.locate(BookmarksFolderLocalService.class.getName());
260         }
261 
262         return _service;
263     }
264 
265     public void setService(BookmarksFolderLocalService service) {
266         _service = service;
267     }
268 
269     private static BookmarksFolderLocalService _service;
270 }