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