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.documentlibrary.service;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  
19  /**
20   * <a href="DLFolderLocalServiceUtil.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 DLFolderLocalService} 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       DLFolderLocalService
37   * @generated
38   */
39  public class DLFolderLocalServiceUtil {
40      public static com.liferay.portlet.documentlibrary.model.DLFolder addDLFolder(
41          com.liferay.portlet.documentlibrary.model.DLFolder dlFolder)
42          throws com.liferay.portal.kernel.exception.SystemException {
43          return getService().addDLFolder(dlFolder);
44      }
45  
46      public static com.liferay.portlet.documentlibrary.model.DLFolder createDLFolder(
47          long folderId) {
48          return getService().createDLFolder(folderId);
49      }
50  
51      public static void deleteDLFolder(long folderId)
52          throws com.liferay.portal.kernel.exception.PortalException,
53              com.liferay.portal.kernel.exception.SystemException {
54          getService().deleteDLFolder(folderId);
55      }
56  
57      public static void deleteDLFolder(
58          com.liferay.portlet.documentlibrary.model.DLFolder dlFolder)
59          throws com.liferay.portal.kernel.exception.SystemException {
60          getService().deleteDLFolder(dlFolder);
61      }
62  
63      public static java.util.List<Object> dynamicQuery(
64          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
65          throws com.liferay.portal.kernel.exception.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.kernel.exception.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.kernel.exception.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.kernel.exception.SystemException {
87          return getService().dynamicQueryCount(dynamicQuery);
88      }
89  
90      public static com.liferay.portlet.documentlibrary.model.DLFolder getDLFolder(
91          long folderId)
92          throws com.liferay.portal.kernel.exception.PortalException,
93              com.liferay.portal.kernel.exception.SystemException {
94          return getService().getDLFolder(folderId);
95      }
96  
97      public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getDLFolders(
98          int start, int end)
99          throws com.liferay.portal.kernel.exception.SystemException {
100         return getService().getDLFolders(start, end);
101     }
102 
103     public static int getDLFoldersCount()
104         throws com.liferay.portal.kernel.exception.SystemException {
105         return getService().getDLFoldersCount();
106     }
107 
108     public static com.liferay.portlet.documentlibrary.model.DLFolder updateDLFolder(
109         com.liferay.portlet.documentlibrary.model.DLFolder dlFolder)
110         throws com.liferay.portal.kernel.exception.SystemException {
111         return getService().updateDLFolder(dlFolder);
112     }
113 
114     public static com.liferay.portlet.documentlibrary.model.DLFolder updateDLFolder(
115         com.liferay.portlet.documentlibrary.model.DLFolder dlFolder,
116         boolean merge)
117         throws com.liferay.portal.kernel.exception.SystemException {
118         return getService().updateDLFolder(dlFolder, merge);
119     }
120 
121     public static com.liferay.portlet.documentlibrary.model.DLFolder addFolder(
122         java.lang.String uuid, long userId, long groupId, long parentFolderId,
123         java.lang.String name, java.lang.String description,
124         com.liferay.portal.service.ServiceContext serviceContext)
125         throws com.liferay.portal.kernel.exception.PortalException,
126             com.liferay.portal.kernel.exception.SystemException {
127         return getService()
128                    .addFolder(uuid, userId, groupId, parentFolderId, name,
129             description, serviceContext);
130     }
131 
132     public static void addFolderResources(
133         com.liferay.portlet.documentlibrary.model.DLFolder folder,
134         boolean addCommunityPermissions, boolean addGuestPermissions)
135         throws com.liferay.portal.kernel.exception.PortalException,
136             com.liferay.portal.kernel.exception.SystemException {
137         getService()
138             .addFolderResources(folder, addCommunityPermissions,
139             addGuestPermissions);
140     }
141 
142     public static void addFolderResources(
143         com.liferay.portlet.documentlibrary.model.DLFolder folder,
144         java.lang.String[] communityPermissions,
145         java.lang.String[] guestPermissions)
146         throws com.liferay.portal.kernel.exception.PortalException,
147             com.liferay.portal.kernel.exception.SystemException {
148         getService()
149             .addFolderResources(folder, communityPermissions, guestPermissions);
150     }
151 
152     public static void addFolderResources(long folderId,
153         boolean addCommunityPermissions, boolean addGuestPermissions)
154         throws com.liferay.portal.kernel.exception.PortalException,
155             com.liferay.portal.kernel.exception.SystemException {
156         getService()
157             .addFolderResources(folderId, addCommunityPermissions,
158             addGuestPermissions);
159     }
160 
161     public static void addFolderResources(long folderId,
162         java.lang.String[] communityPermissions,
163         java.lang.String[] guestPermissions)
164         throws com.liferay.portal.kernel.exception.PortalException,
165             com.liferay.portal.kernel.exception.SystemException {
166         getService()
167             .addFolderResources(folderId, communityPermissions, guestPermissions);
168     }
169 
170     public static void deleteFolder(
171         com.liferay.portlet.documentlibrary.model.DLFolder folder)
172         throws com.liferay.portal.kernel.exception.PortalException,
173             com.liferay.portal.kernel.exception.SystemException {
174         getService().deleteFolder(folder);
175     }
176 
177     public static void deleteFolder(long folderId)
178         throws com.liferay.portal.kernel.exception.PortalException,
179             com.liferay.portal.kernel.exception.SystemException {
180         getService().deleteFolder(folderId);
181     }
182 
183     public static void deleteFolders(long groupId)
184         throws com.liferay.portal.kernel.exception.PortalException,
185             com.liferay.portal.kernel.exception.SystemException {
186         getService().deleteFolders(groupId);
187     }
188 
189     public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getCompanyFolders(
190         long companyId, int start, int end)
191         throws com.liferay.portal.kernel.exception.SystemException {
192         return getService().getCompanyFolders(companyId, start, end);
193     }
194 
195     public static int getCompanyFoldersCount(long companyId)
196         throws com.liferay.portal.kernel.exception.SystemException {
197         return getService().getCompanyFoldersCount(companyId);
198     }
199 
200     public static java.util.List<Object> getFileEntriesAndFileShortcuts(
201         long groupId, java.util.List<Long> folderIds, int status, int start,
202         int end) throws com.liferay.portal.kernel.exception.SystemException {
203         return getService()
204                    .getFileEntriesAndFileShortcuts(groupId, folderIds, status,
205             start, end);
206     }
207 
208     public static java.util.List<Object> getFileEntriesAndFileShortcuts(
209         long groupId, long folderId, int status, int start, int end)
210         throws com.liferay.portal.kernel.exception.SystemException {
211         return getService()
212                    .getFileEntriesAndFileShortcuts(groupId, folderId, status,
213             start, end);
214     }
215 
216     public static int getFileEntriesAndFileShortcutsCount(long groupId,
217         java.util.List<Long> folderIds, int status)
218         throws com.liferay.portal.kernel.exception.SystemException {
219         return getService()
220                    .getFileEntriesAndFileShortcutsCount(groupId, folderIds,
221             status);
222     }
223 
224     public static int getFileEntriesAndFileShortcutsCount(long groupId,
225         long folderId, int status)
226         throws com.liferay.portal.kernel.exception.SystemException {
227         return getService()
228                    .getFileEntriesAndFileShortcutsCount(groupId, folderId,
229             status);
230     }
231 
232     public static com.liferay.portlet.documentlibrary.model.DLFolder getFolder(
233         long folderId)
234         throws com.liferay.portal.kernel.exception.PortalException,
235             com.liferay.portal.kernel.exception.SystemException {
236         return getService().getFolder(folderId);
237     }
238 
239     public static com.liferay.portlet.documentlibrary.model.DLFolder getFolder(
240         long groupId, long parentFolderId, java.lang.String name)
241         throws com.liferay.portal.kernel.exception.PortalException,
242             com.liferay.portal.kernel.exception.SystemException {
243         return getService().getFolder(groupId, parentFolderId, name);
244     }
245 
246     public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getFolders(
247         long companyId)
248         throws com.liferay.portal.kernel.exception.SystemException {
249         return getService().getFolders(companyId);
250     }
251 
252     public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getFolders(
253         long groupId, long parentFolderId)
254         throws com.liferay.portal.kernel.exception.SystemException {
255         return getService().getFolders(groupId, parentFolderId);
256     }
257 
258     public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getFolders(
259         long groupId, long parentFolderId, int start, int end)
260         throws com.liferay.portal.kernel.exception.SystemException {
261         return getService().getFolders(groupId, parentFolderId, start, end);
262     }
263 
264     public static java.util.List<Object> getFoldersAndFileEntriesAndFileShortcuts(
265         long groupId, java.util.List<Long> folderIds, int status, int start,
266         int end) throws com.liferay.portal.kernel.exception.SystemException {
267         return getService()
268                    .getFoldersAndFileEntriesAndFileShortcuts(groupId,
269             folderIds, status, start, end);
270     }
271 
272     public static java.util.List<Object> getFoldersAndFileEntriesAndFileShortcuts(
273         long groupId, long folderId, int status, int start, int end)
274         throws com.liferay.portal.kernel.exception.SystemException {
275         return getService()
276                    .getFoldersAndFileEntriesAndFileShortcuts(groupId, folderId,
277             status, start, end);
278     }
279 
280     public static int getFoldersAndFileEntriesAndFileShortcutsCount(
281         long groupId, java.util.List<Long> folderIds, int status)
282         throws com.liferay.portal.kernel.exception.SystemException {
283         return getService()
284                    .getFoldersAndFileEntriesAndFileShortcutsCount(groupId,
285             folderIds, status);
286     }
287 
288     public static int getFoldersAndFileEntriesAndFileShortcutsCount(
289         long groupId, long folderId, int status)
290         throws com.liferay.portal.kernel.exception.SystemException {
291         return getService()
292                    .getFoldersAndFileEntriesAndFileShortcutsCount(groupId,
293             folderId, status);
294     }
295 
296     public static int getFoldersCount(long groupId, long parentFolderId)
297         throws com.liferay.portal.kernel.exception.SystemException {
298         return getService().getFoldersCount(groupId, parentFolderId);
299     }
300 
301     public static void getSubfolderIds(java.util.List<Long> folderIds,
302         long groupId, long folderId)
303         throws com.liferay.portal.kernel.exception.SystemException {
304         getService().getSubfolderIds(folderIds, groupId, folderId);
305     }
306 
307     public static com.liferay.portlet.documentlibrary.model.DLFolder updateFolder(
308         long folderId, long parentFolderId, java.lang.String name,
309         java.lang.String description,
310         com.liferay.portal.service.ServiceContext serviceContext)
311         throws com.liferay.portal.kernel.exception.PortalException,
312             com.liferay.portal.kernel.exception.SystemException {
313         return getService()
314                    .updateFolder(folderId, parentFolderId, name, description,
315             serviceContext);
316     }
317 
318     public static DLFolderLocalService getService() {
319         if (_service == null) {
320             _service = (DLFolderLocalService)PortalBeanLocatorUtil.locate(DLFolderLocalService.class.getName());
321         }
322 
323         return _service;
324     }
325 
326     public void setService(DLFolderLocalService service) {
327         _service = service;
328     }
329 
330     private static DLFolderLocalService _service;
331 }