1   /**
2    * Copyright (c) 2000-2007 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.imagegallery.service;
24  
25  /**
26   * <a href="IGFolderLocalServiceUtil.java.html"><b><i>View Source</i></b></a>
27   *
28   * <p>
29   * ServiceBuilder generated this class. Modifications in this class will be overwritten
30   * the next time is generated.
31   * </p>
32   *
33   * <p>
34   * This class provides static methods for the <code>com.liferay.portlet.imagegallery.service.IGFolderLocalService</code>
35   * bean. The static methods of this class calls the same methods of the bean instance.
36   * It's convenient to be able to just write one line to call a method on a bean
37   * instead of writing a lookup call and a method call.
38   * </p>
39   *
40   * <p>
41   * <code>com.liferay.portlet.imagegallery.service.IGFolderLocalServiceFactory</code>
42   * is responsible for the lookup of the bean.
43   * </p>
44   *
45   * @author Brian Wing Shun Chan
46   *
47   * @see com.liferay.portlet.imagegallery.service.IGFolderLocalService
48   * @see com.liferay.portlet.imagegallery.service.IGFolderLocalServiceFactory
49   *
50   */
51  public class IGFolderLocalServiceUtil {
52      public static com.liferay.portlet.imagegallery.model.IGFolder addIGFolder(
53          com.liferay.portlet.imagegallery.model.IGFolder model)
54          throws com.liferay.portal.SystemException {
55          IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
56  
57          return igFolderLocalService.addIGFolder(model);
58      }
59  
60      public static java.util.List dynamicQuery(
61          com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
62          throws com.liferay.portal.SystemException {
63          IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
64  
65          return igFolderLocalService.dynamicQuery(queryInitializer);
66      }
67  
68      public static java.util.List dynamicQuery(
69          com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
70          int begin, int end) throws com.liferay.portal.SystemException {
71          IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
72  
73          return igFolderLocalService.dynamicQuery(queryInitializer, begin, end);
74      }
75  
76      public static com.liferay.portlet.imagegallery.model.IGFolder updateIGFolder(
77          com.liferay.portlet.imagegallery.model.IGFolder model)
78          throws com.liferay.portal.SystemException {
79          IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
80  
81          return igFolderLocalService.updateIGFolder(model);
82      }
83  
84      public static com.liferay.portlet.imagegallery.model.IGFolder addFolder(
85          long userId, long plid, long parentFolderId, java.lang.String name,
86          java.lang.String description, boolean addCommunityPermissions,
87          boolean addGuestPermissions)
88          throws com.liferay.portal.PortalException, 
89              com.liferay.portal.SystemException {
90          IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
91  
92          return igFolderLocalService.addFolder(userId, plid, parentFolderId,
93              name, description, addCommunityPermissions, addGuestPermissions);
94      }
95  
96      public static com.liferay.portlet.imagegallery.model.IGFolder addFolder(
97          long userId, long plid, long parentFolderId, java.lang.String name,
98          java.lang.String description, java.lang.String[] communityPermissions,
99          java.lang.String[] guestPermissions)
100         throws com.liferay.portal.PortalException, 
101             com.liferay.portal.SystemException {
102         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
103 
104         return igFolderLocalService.addFolder(userId, plid, parentFolderId,
105             name, description, communityPermissions, guestPermissions);
106     }
107 
108     public static com.liferay.portlet.imagegallery.model.IGFolder addFolder(
109         long userId, long plid, long parentFolderId, java.lang.String name,
110         java.lang.String description,
111         java.lang.Boolean addCommunityPermissions,
112         java.lang.Boolean addGuestPermissions,
113         java.lang.String[] communityPermissions,
114         java.lang.String[] guestPermissions)
115         throws com.liferay.portal.PortalException, 
116             com.liferay.portal.SystemException {
117         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
118 
119         return igFolderLocalService.addFolder(userId, plid, parentFolderId,
120             name, description, addCommunityPermissions, addGuestPermissions,
121             communityPermissions, guestPermissions);
122     }
123 
124     public static com.liferay.portlet.imagegallery.model.IGFolder addFolderToGroup(
125         long userId, long groupId, long parentFolderId, java.lang.String name,
126         java.lang.String description,
127         java.lang.Boolean addCommunityPermissions,
128         java.lang.Boolean addGuestPermissions,
129         java.lang.String[] communityPermissions,
130         java.lang.String[] guestPermissions)
131         throws com.liferay.portal.PortalException, 
132             com.liferay.portal.SystemException {
133         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
134 
135         return igFolderLocalService.addFolderToGroup(userId, groupId,
136             parentFolderId, name, description, addCommunityPermissions,
137             addGuestPermissions, communityPermissions, guestPermissions);
138     }
139 
140     public static void addFolderResources(long folderId,
141         boolean addCommunityPermissions, boolean addGuestPermissions)
142         throws com.liferay.portal.PortalException, 
143             com.liferay.portal.SystemException {
144         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
145         igFolderLocalService.addFolderResources(folderId,
146             addCommunityPermissions, addGuestPermissions);
147     }
148 
149     public static void addFolderResources(
150         com.liferay.portlet.imagegallery.model.IGFolder folder,
151         boolean addCommunityPermissions, boolean addGuestPermissions)
152         throws com.liferay.portal.PortalException, 
153             com.liferay.portal.SystemException {
154         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
155         igFolderLocalService.addFolderResources(folder,
156             addCommunityPermissions, addGuestPermissions);
157     }
158 
159     public static void addFolderResources(long folderId,
160         java.lang.String[] communityPermissions,
161         java.lang.String[] guestPermissions)
162         throws com.liferay.portal.PortalException, 
163             com.liferay.portal.SystemException {
164         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
165         igFolderLocalService.addFolderResources(folderId, communityPermissions,
166             guestPermissions);
167     }
168 
169     public static void addFolderResources(
170         com.liferay.portlet.imagegallery.model.IGFolder folder,
171         java.lang.String[] communityPermissions,
172         java.lang.String[] guestPermissions)
173         throws com.liferay.portal.PortalException, 
174             com.liferay.portal.SystemException {
175         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
176         igFolderLocalService.addFolderResources(folder, communityPermissions,
177             guestPermissions);
178     }
179 
180     public static void deleteFolder(long folderId)
181         throws com.liferay.portal.PortalException, 
182             com.liferay.portal.SystemException {
183         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
184         igFolderLocalService.deleteFolder(folderId);
185     }
186 
187     public static void deleteFolder(
188         com.liferay.portlet.imagegallery.model.IGFolder folder)
189         throws com.liferay.portal.PortalException, 
190             com.liferay.portal.SystemException {
191         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
192         igFolderLocalService.deleteFolder(folder);
193     }
194 
195     public static void deleteFolders(long groupId)
196         throws com.liferay.portal.PortalException, 
197             com.liferay.portal.SystemException {
198         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
199         igFolderLocalService.deleteFolders(groupId);
200     }
201 
202     public static com.liferay.portlet.imagegallery.model.IGFolder getFolder(
203         long folderId)
204         throws com.liferay.portal.PortalException, 
205             com.liferay.portal.SystemException {
206         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
207 
208         return igFolderLocalService.getFolder(folderId);
209     }
210 
211     public static java.util.List getFolders(long groupId)
212         throws com.liferay.portal.SystemException {
213         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
214 
215         return igFolderLocalService.getFolders(groupId);
216     }
217 
218     public static java.util.List getFolders(long groupId, long parentFolderId)
219         throws com.liferay.portal.SystemException {
220         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
221 
222         return igFolderLocalService.getFolders(groupId, parentFolderId);
223     }
224 
225     public static java.util.List getFolders(long groupId, long parentFolderId,
226         int begin, int end) throws com.liferay.portal.SystemException {
227         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
228 
229         return igFolderLocalService.getFolders(groupId, parentFolderId, begin,
230             end);
231     }
232 
233     public static int getFoldersCount(long groupId, long parentFolderId)
234         throws com.liferay.portal.SystemException {
235         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
236 
237         return igFolderLocalService.getFoldersCount(groupId, parentFolderId);
238     }
239 
240     public static void getSubfolderIds(java.util.List folderIds, long groupId,
241         long folderId) throws com.liferay.portal.SystemException {
242         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
243         igFolderLocalService.getSubfolderIds(folderIds, groupId, folderId);
244     }
245 
246     public static com.liferay.portlet.imagegallery.model.IGFolder updateFolder(
247         long folderId, long parentFolderId, java.lang.String name,
248         java.lang.String description, boolean mergeWithParentFolder)
249         throws com.liferay.portal.PortalException, 
250             com.liferay.portal.SystemException {
251         IGFolderLocalService igFolderLocalService = IGFolderLocalServiceFactory.getService();
252 
253         return igFolderLocalService.updateFolder(folderId, parentFolderId,
254             name, description, mergeWithParentFolder);
255     }
256 }