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.portlet.documentlibrary.service;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    
019    /**
020     * <p>
021     * This class provides static methods for the
022     * {@link DLFolderLocalService} 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       DLFolderLocalService
030     * @generated
031     */
032    public class DLFolderLocalServiceUtil {
033            public static com.liferay.portlet.documentlibrary.model.DLFolder addDLFolder(
034                    com.liferay.portlet.documentlibrary.model.DLFolder dlFolder)
035                    throws com.liferay.portal.kernel.exception.SystemException {
036                    return getService().addDLFolder(dlFolder);
037            }
038    
039            public static com.liferay.portlet.documentlibrary.model.DLFolder createDLFolder(
040                    long folderId) {
041                    return getService().createDLFolder(folderId);
042            }
043    
044            public static void deleteDLFolder(long folderId)
045                    throws com.liferay.portal.kernel.exception.PortalException,
046                            com.liferay.portal.kernel.exception.SystemException {
047                    getService().deleteDLFolder(folderId);
048            }
049    
050            public static void deleteDLFolder(
051                    com.liferay.portlet.documentlibrary.model.DLFolder dlFolder)
052                    throws com.liferay.portal.kernel.exception.SystemException {
053                    getService().deleteDLFolder(dlFolder);
054            }
055    
056            @SuppressWarnings("unchecked")
057            public static java.util.List dynamicQuery(
058                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
059                    throws com.liferay.portal.kernel.exception.SystemException {
060                    return getService().dynamicQuery(dynamicQuery);
061            }
062    
063            @SuppressWarnings("unchecked")
064            public static java.util.List dynamicQuery(
065                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
066                    int end) throws com.liferay.portal.kernel.exception.SystemException {
067                    return getService().dynamicQuery(dynamicQuery, start, end);
068            }
069    
070            @SuppressWarnings("unchecked")
071            public static java.util.List dynamicQuery(
072                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
073                    int end,
074                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
075                    throws com.liferay.portal.kernel.exception.SystemException {
076                    return getService()
077                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
078            }
079    
080            public static long dynamicQueryCount(
081                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
082                    throws com.liferay.portal.kernel.exception.SystemException {
083                    return getService().dynamicQueryCount(dynamicQuery);
084            }
085    
086            public static com.liferay.portlet.documentlibrary.model.DLFolder getDLFolder(
087                    long folderId)
088                    throws com.liferay.portal.kernel.exception.PortalException,
089                            com.liferay.portal.kernel.exception.SystemException {
090                    return getService().getDLFolder(folderId);
091            }
092    
093            public static com.liferay.portlet.documentlibrary.model.DLFolder getDLFolderByUuidAndGroupId(
094                    java.lang.String uuid, long groupId)
095                    throws com.liferay.portal.kernel.exception.PortalException,
096                            com.liferay.portal.kernel.exception.SystemException {
097                    return getService().getDLFolderByUuidAndGroupId(uuid, groupId);
098            }
099    
100            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getDLFolders(
101                    int start, int end)
102                    throws com.liferay.portal.kernel.exception.SystemException {
103                    return getService().getDLFolders(start, end);
104            }
105    
106            public static int getDLFoldersCount()
107                    throws com.liferay.portal.kernel.exception.SystemException {
108                    return getService().getDLFoldersCount();
109            }
110    
111            public static com.liferay.portlet.documentlibrary.model.DLFolder updateDLFolder(
112                    com.liferay.portlet.documentlibrary.model.DLFolder dlFolder)
113                    throws com.liferay.portal.kernel.exception.SystemException {
114                    return getService().updateDLFolder(dlFolder);
115            }
116    
117            public static com.liferay.portlet.documentlibrary.model.DLFolder updateDLFolder(
118                    com.liferay.portlet.documentlibrary.model.DLFolder dlFolder,
119                    boolean merge)
120                    throws com.liferay.portal.kernel.exception.SystemException {
121                    return getService().updateDLFolder(dlFolder, merge);
122            }
123    
124            public static com.liferay.portlet.documentlibrary.model.DLFolder addFolder(
125                    long userId, long groupId, long parentFolderId, java.lang.String name,
126                    java.lang.String description,
127                    com.liferay.portal.service.ServiceContext serviceContext)
128                    throws com.liferay.portal.kernel.exception.PortalException,
129                            com.liferay.portal.kernel.exception.SystemException {
130                    return getService()
131                                       .addFolder(userId, groupId, parentFolderId, name,
132                            description, serviceContext);
133            }
134    
135            public static void addFolderResources(
136                    com.liferay.portlet.documentlibrary.model.DLFolder folder,
137                    boolean addCommunityPermissions, boolean addGuestPermissions)
138                    throws com.liferay.portal.kernel.exception.PortalException,
139                            com.liferay.portal.kernel.exception.SystemException {
140                    getService()
141                            .addFolderResources(folder, addCommunityPermissions,
142                            addGuestPermissions);
143            }
144    
145            public static void addFolderResources(
146                    com.liferay.portlet.documentlibrary.model.DLFolder folder,
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(folder, communityPermissions, guestPermissions);
153            }
154    
155            public static void addFolderResources(long folderId,
156                    boolean addCommunityPermissions, boolean addGuestPermissions)
157                    throws com.liferay.portal.kernel.exception.PortalException,
158                            com.liferay.portal.kernel.exception.SystemException {
159                    getService()
160                            .addFolderResources(folderId, addCommunityPermissions,
161                            addGuestPermissions);
162            }
163    
164            public static void addFolderResources(long folderId,
165                    java.lang.String[] communityPermissions,
166                    java.lang.String[] guestPermissions)
167                    throws com.liferay.portal.kernel.exception.PortalException,
168                            com.liferay.portal.kernel.exception.SystemException {
169                    getService()
170                            .addFolderResources(folderId, communityPermissions, guestPermissions);
171            }
172    
173            public static void deleteFolder(
174                    com.liferay.portlet.documentlibrary.model.DLFolder folder)
175                    throws com.liferay.portal.kernel.exception.PortalException,
176                            com.liferay.portal.kernel.exception.SystemException {
177                    getService().deleteFolder(folder);
178            }
179    
180            public static void deleteFolder(long folderId)
181                    throws com.liferay.portal.kernel.exception.PortalException,
182                            com.liferay.portal.kernel.exception.SystemException {
183                    getService().deleteFolder(folderId);
184            }
185    
186            public static void deleteFolders(long groupId)
187                    throws com.liferay.portal.kernel.exception.PortalException,
188                            com.liferay.portal.kernel.exception.SystemException {
189                    getService().deleteFolders(groupId);
190            }
191    
192            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getCompanyFolders(
193                    long companyId, int start, int end)
194                    throws com.liferay.portal.kernel.exception.SystemException {
195                    return getService().getCompanyFolders(companyId, start, end);
196            }
197    
198            public static int getCompanyFoldersCount(long companyId)
199                    throws com.liferay.portal.kernel.exception.SystemException {
200                    return getService().getCompanyFoldersCount(companyId);
201            }
202    
203            public static java.util.List<java.lang.Object> getFileEntriesAndFileShortcuts(
204                    long groupId, java.util.List<java.lang.Long> folderIds, int status,
205                    int start, int end)
206                    throws com.liferay.portal.kernel.exception.SystemException {
207                    return getService()
208                                       .getFileEntriesAndFileShortcuts(groupId, folderIds, status,
209                            start, end);
210            }
211    
212            public static java.util.List<java.lang.Object> getFileEntriesAndFileShortcuts(
213                    long groupId, long folderId, int status, int start, int end)
214                    throws com.liferay.portal.kernel.exception.SystemException {
215                    return getService()
216                                       .getFileEntriesAndFileShortcuts(groupId, folderId, status,
217                            start, end);
218            }
219    
220            public static int getFileEntriesAndFileShortcutsCount(long groupId,
221                    java.util.List<java.lang.Long> folderIds, int status)
222                    throws com.liferay.portal.kernel.exception.SystemException {
223                    return getService()
224                                       .getFileEntriesAndFileShortcutsCount(groupId, folderIds,
225                            status);
226            }
227    
228            public static int getFileEntriesAndFileShortcutsCount(long groupId,
229                    long folderId, int status)
230                    throws com.liferay.portal.kernel.exception.SystemException {
231                    return getService()
232                                       .getFileEntriesAndFileShortcutsCount(groupId, folderId,
233                            status);
234            }
235    
236            public static com.liferay.portlet.documentlibrary.model.DLFolder getFolder(
237                    long folderId)
238                    throws com.liferay.portal.kernel.exception.PortalException,
239                            com.liferay.portal.kernel.exception.SystemException {
240                    return getService().getFolder(folderId);
241            }
242    
243            public static com.liferay.portlet.documentlibrary.model.DLFolder getFolder(
244                    long groupId, long parentFolderId, java.lang.String name)
245                    throws com.liferay.portal.kernel.exception.PortalException,
246                            com.liferay.portal.kernel.exception.SystemException {
247                    return getService().getFolder(groupId, parentFolderId, name);
248            }
249    
250            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getFolders(
251                    long companyId)
252                    throws com.liferay.portal.kernel.exception.SystemException {
253                    return getService().getFolders(companyId);
254            }
255    
256            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getFolders(
257                    long groupId, long parentFolderId)
258                    throws com.liferay.portal.kernel.exception.SystemException {
259                    return getService().getFolders(groupId, parentFolderId);
260            }
261    
262            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFolder> getFolders(
263                    long groupId, long parentFolderId, int start, int end)
264                    throws com.liferay.portal.kernel.exception.SystemException {
265                    return getService().getFolders(groupId, parentFolderId, start, end);
266            }
267    
268            public static java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
269                    long groupId, java.util.List<java.lang.Long> folderIds, int status,
270                    int start, int end)
271                    throws com.liferay.portal.kernel.exception.SystemException {
272                    return getService()
273                                       .getFoldersAndFileEntriesAndFileShortcuts(groupId,
274                            folderIds, status, start, end);
275            }
276    
277            public static java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
278                    long groupId, long folderId, int status, int start, int end)
279                    throws com.liferay.portal.kernel.exception.SystemException {
280                    return getService()
281                                       .getFoldersAndFileEntriesAndFileShortcuts(groupId, folderId,
282                            status, start, end);
283            }
284    
285            public static int getFoldersAndFileEntriesAndFileShortcutsCount(
286                    long groupId, java.util.List<java.lang.Long> folderIds, int status)
287                    throws com.liferay.portal.kernel.exception.SystemException {
288                    return getService()
289                                       .getFoldersAndFileEntriesAndFileShortcutsCount(groupId,
290                            folderIds, status);
291            }
292    
293            public static int getFoldersAndFileEntriesAndFileShortcutsCount(
294                    long groupId, long folderId, int status)
295                    throws com.liferay.portal.kernel.exception.SystemException {
296                    return getService()
297                                       .getFoldersAndFileEntriesAndFileShortcutsCount(groupId,
298                            folderId, status);
299            }
300    
301            public static int getFoldersCount(long groupId, long parentFolderId)
302                    throws com.liferay.portal.kernel.exception.SystemException {
303                    return getService().getFoldersCount(groupId, parentFolderId);
304            }
305    
306            public static void getSubfolderIds(
307                    java.util.List<java.lang.Long> folderIds, long groupId, long folderId)
308                    throws com.liferay.portal.kernel.exception.SystemException {
309                    getService().getSubfolderIds(folderIds, groupId, folderId);
310            }
311    
312            public static com.liferay.portlet.documentlibrary.model.DLFolder updateFolder(
313                    long folderId, long parentFolderId, java.lang.String name,
314                    java.lang.String description,
315                    com.liferay.portal.service.ServiceContext serviceContext)
316                    throws com.liferay.portal.kernel.exception.PortalException,
317                            com.liferay.portal.kernel.exception.SystemException {
318                    return getService()
319                                       .updateFolder(folderId, parentFolderId, name, description,
320                            serviceContext);
321            }
322    
323            public static DLFolderLocalService getService() {
324                    if (_service == null) {
325                            _service = (DLFolderLocalService)PortalBeanLocatorUtil.locate(DLFolderLocalService.class.getName());
326                    }
327    
328                    return _service;
329            }
330    
331            public void setService(DLFolderLocalService service) {
332                    _service = service;
333            }
334    
335            private static DLFolderLocalService _service;
336    }