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