1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portlet.documentlibrary.service;
24  
25  
26  /**
27   * <a href="DLFileShortcutLocalServiceUtil.java.html"><b><i>View Source</i></b></a>
28   *
29   * <p>
30   * ServiceBuilder generated this class. Modifications in this class will be
31   * overwritten the next time is generated.
32   * </p>
33   *
34   * <p>
35   * This class provides static methods for the
36   * <code>com.liferay.portlet.documentlibrary.service.DLFileShortcutLocalService</code>
37   * bean. The static methods of this class calls the same methods of the bean
38   * instance. It's convenient to be able to just write one line to call a method
39   * on a bean instead of writing a lookup call and a method call.
40   * </p>
41   *
42   * @author Brian Wing Shun Chan
43   *
44   * @see com.liferay.portlet.documentlibrary.service.DLFileShortcutLocalService
45   *
46   */
47  public class DLFileShortcutLocalServiceUtil {
48      public static com.liferay.portlet.documentlibrary.model.DLFileShortcut addDLFileShortcut(
49          com.liferay.portlet.documentlibrary.model.DLFileShortcut dlFileShortcut)
50          throws com.liferay.portal.SystemException {
51          return getService().addDLFileShortcut(dlFileShortcut);
52      }
53  
54      public static com.liferay.portlet.documentlibrary.model.DLFileShortcut createDLFileShortcut(
55          long fileShortcutId) {
56          return getService().createDLFileShortcut(fileShortcutId);
57      }
58  
59      public static void deleteDLFileShortcut(long fileShortcutId)
60          throws com.liferay.portal.PortalException,
61              com.liferay.portal.SystemException {
62          getService().deleteDLFileShortcut(fileShortcutId);
63      }
64  
65      public static void deleteDLFileShortcut(
66          com.liferay.portlet.documentlibrary.model.DLFileShortcut dlFileShortcut)
67          throws com.liferay.portal.SystemException {
68          getService().deleteDLFileShortcut(dlFileShortcut);
69      }
70  
71      public static java.util.List<Object> dynamicQuery(
72          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
73          throws com.liferay.portal.SystemException {
74          return getService().dynamicQuery(dynamicQuery);
75      }
76  
77      public static java.util.List<Object> dynamicQuery(
78          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
79          int end) throws com.liferay.portal.SystemException {
80          return getService().dynamicQuery(dynamicQuery, start, end);
81      }
82  
83      public static com.liferay.portlet.documentlibrary.model.DLFileShortcut getDLFileShortcut(
84          long fileShortcutId)
85          throws com.liferay.portal.PortalException,
86              com.liferay.portal.SystemException {
87          return getService().getDLFileShortcut(fileShortcutId);
88      }
89  
90      public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileShortcut> getDLFileShortcuts(
91          int start, int end) throws com.liferay.portal.SystemException {
92          return getService().getDLFileShortcuts(start, end);
93      }
94  
95      public static int getDLFileShortcutsCount()
96          throws com.liferay.portal.SystemException {
97          return getService().getDLFileShortcutsCount();
98      }
99  
100     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut updateDLFileShortcut(
101         com.liferay.portlet.documentlibrary.model.DLFileShortcut dlFileShortcut)
102         throws com.liferay.portal.SystemException {
103         return getService().updateDLFileShortcut(dlFileShortcut);
104     }
105 
106     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut addFileShortcut(
107         long userId, long folderId, long toFolderId, java.lang.String toName,
108         boolean addCommunityPermissions, boolean addGuestPermissions)
109         throws com.liferay.portal.PortalException,
110             com.liferay.portal.SystemException {
111         return getService()
112                    .addFileShortcut(userId, folderId, toFolderId, toName,
113             addCommunityPermissions, addGuestPermissions);
114     }
115 
116     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut addFileShortcut(
117         java.lang.String uuid, long userId, long folderId, long toFolderId,
118         java.lang.String toName, boolean addCommunityPermissions,
119         boolean addGuestPermissions)
120         throws com.liferay.portal.PortalException,
121             com.liferay.portal.SystemException {
122         return getService()
123                    .addFileShortcut(uuid, userId, folderId, toFolderId, toName,
124             addCommunityPermissions, addGuestPermissions);
125     }
126 
127     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut addFileShortcut(
128         long userId, long folderId, long toFolderId, java.lang.String toName,
129         java.lang.String[] communityPermissions,
130         java.lang.String[] guestPermissions)
131         throws com.liferay.portal.PortalException,
132             com.liferay.portal.SystemException {
133         return getService()
134                    .addFileShortcut(userId, folderId, toFolderId, toName,
135             communityPermissions, guestPermissions);
136     }
137 
138     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut addFileShortcut(
139         java.lang.String uuid, long userId, long folderId, long toFolderId,
140         java.lang.String toName, java.lang.Boolean addCommunityPermissions,
141         java.lang.Boolean addGuestPermissions,
142         java.lang.String[] communityPermissions,
143         java.lang.String[] guestPermissions)
144         throws com.liferay.portal.PortalException,
145             com.liferay.portal.SystemException {
146         return getService()
147                    .addFileShortcut(uuid, userId, folderId, toFolderId, toName,
148             addCommunityPermissions, addGuestPermissions, communityPermissions,
149             guestPermissions);
150     }
151 
152     public static void addFileShortcutResources(long fileShortcutId,
153         boolean addCommunityPermissions, boolean addGuestPermissions)
154         throws com.liferay.portal.PortalException,
155             com.liferay.portal.SystemException {
156         getService()
157             .addFileShortcutResources(fileShortcutId, addCommunityPermissions,
158             addGuestPermissions);
159     }
160 
161     public static void addFileShortcutResources(
162         com.liferay.portlet.documentlibrary.model.DLFolder folder,
163         com.liferay.portlet.documentlibrary.model.DLFileShortcut fileShortcut,
164         boolean addCommunityPermissions, boolean addGuestPermissions)
165         throws com.liferay.portal.PortalException,
166             com.liferay.portal.SystemException {
167         getService()
168             .addFileShortcutResources(folder, fileShortcut,
169             addCommunityPermissions, addGuestPermissions);
170     }
171 
172     public static void addFileShortcutResources(long fileShortcutId,
173         java.lang.String[] communityPermissions,
174         java.lang.String[] guestPermissions)
175         throws com.liferay.portal.PortalException,
176             com.liferay.portal.SystemException {
177         getService()
178             .addFileShortcutResources(fileShortcutId, communityPermissions,
179             guestPermissions);
180     }
181 
182     public static void addFileShortcutResources(
183         com.liferay.portlet.documentlibrary.model.DLFolder folder,
184         com.liferay.portlet.documentlibrary.model.DLFileShortcut fileShortcut,
185         java.lang.String[] communityPermissions,
186         java.lang.String[] guestPermissions)
187         throws com.liferay.portal.PortalException,
188             com.liferay.portal.SystemException {
189         getService()
190             .addFileShortcutResources(folder, fileShortcut,
191             communityPermissions, guestPermissions);
192     }
193 
194     public static void deleteFileShortcut(long fileShortcutId)
195         throws com.liferay.portal.PortalException,
196             com.liferay.portal.SystemException {
197         getService().deleteFileShortcut(fileShortcutId);
198     }
199 
200     public static void deleteFileShortcut(
201         com.liferay.portlet.documentlibrary.model.DLFileShortcut fileShortcut)
202         throws com.liferay.portal.PortalException,
203             com.liferay.portal.SystemException {
204         getService().deleteFileShortcut(fileShortcut);
205     }
206 
207     public static void deleteFileShortcuts(long toFolderId,
208         java.lang.String toName)
209         throws com.liferay.portal.PortalException,
210             com.liferay.portal.SystemException {
211         getService().deleteFileShortcuts(toFolderId, toName);
212     }
213 
214     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut getFileShortcut(
215         long fileShortcutId)
216         throws com.liferay.portal.PortalException,
217             com.liferay.portal.SystemException {
218         return getService().getFileShortcut(fileShortcutId);
219     }
220 
221     public static com.liferay.portlet.documentlibrary.model.DLFileShortcut updateFileShortcut(
222         long userId, long fileShortcutId, long folderId, long toFolderId,
223         java.lang.String toName)
224         throws com.liferay.portal.PortalException,
225             com.liferay.portal.SystemException {
226         return getService()
227                    .updateFileShortcut(userId, fileShortcutId, folderId,
228             toFolderId, toName);
229     }
230 
231     public static void updateFileShortcuts(long oldToFolderId,
232         java.lang.String oldToName, long newToFolderId,
233         java.lang.String newToName) throws com.liferay.portal.SystemException {
234         getService()
235             .updateFileShortcuts(oldToFolderId, oldToName, newToFolderId,
236             newToName);
237     }
238 
239     public static DLFileShortcutLocalService getService() {
240         if (_service == null) {
241             throw new RuntimeException("DLFileShortcutLocalService is not set");
242         }
243 
244         return _service;
245     }
246 
247     public void setService(DLFileShortcutLocalService service) {
248         _service = service;
249     }
250 
251     private static DLFileShortcutLocalService _service;
252 }