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.tasks.service;
24  
25  
26  /**
27   * <a href="TasksProposalLocalServiceUtil.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.tasks.service.TasksProposalLocalService</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.tasks.service.TasksProposalLocalService
45   *
46   */
47  public class TasksProposalLocalServiceUtil {
48      public static com.liferay.portlet.tasks.model.TasksProposal addTasksProposal(
49          com.liferay.portlet.tasks.model.TasksProposal tasksProposal)
50          throws com.liferay.portal.SystemException {
51          return getService().addTasksProposal(tasksProposal);
52      }
53  
54      public static com.liferay.portlet.tasks.model.TasksProposal createTasksProposal(
55          long proposalId) {
56          return getService().createTasksProposal(proposalId);
57      }
58  
59      public static void deleteTasksProposal(long proposalId)
60          throws com.liferay.portal.PortalException,
61              com.liferay.portal.SystemException {
62          getService().deleteTasksProposal(proposalId);
63      }
64  
65      public static void deleteTasksProposal(
66          com.liferay.portlet.tasks.model.TasksProposal tasksProposal)
67          throws com.liferay.portal.SystemException {
68          getService().deleteTasksProposal(tasksProposal);
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.tasks.model.TasksProposal getTasksProposal(
84          long proposalId)
85          throws com.liferay.portal.PortalException,
86              com.liferay.portal.SystemException {
87          return getService().getTasksProposal(proposalId);
88      }
89  
90      public static java.util.List<com.liferay.portlet.tasks.model.TasksProposal> getTasksProposals(
91          int start, int end) throws com.liferay.portal.SystemException {
92          return getService().getTasksProposals(start, end);
93      }
94  
95      public static int getTasksProposalsCount()
96          throws com.liferay.portal.SystemException {
97          return getService().getTasksProposalsCount();
98      }
99  
100     public static com.liferay.portlet.tasks.model.TasksProposal updateTasksProposal(
101         com.liferay.portlet.tasks.model.TasksProposal tasksProposal)
102         throws com.liferay.portal.SystemException {
103         return getService().updateTasksProposal(tasksProposal);
104     }
105 
106     public static com.liferay.portlet.tasks.model.TasksProposal updateTasksProposal(
107         com.liferay.portlet.tasks.model.TasksProposal tasksProposal,
108         boolean merge) throws com.liferay.portal.SystemException {
109         return getService().updateTasksProposal(tasksProposal, merge);
110     }
111 
112     public static com.liferay.portlet.tasks.model.TasksProposal addProposal(
113         long userId, long groupId, java.lang.String className,
114         java.lang.String classPK, java.lang.String name,
115         java.lang.String description, long reviewUserId,
116         boolean addCommunityPermissions, boolean addGuestPermissions)
117         throws com.liferay.portal.PortalException,
118             com.liferay.portal.SystemException {
119         return getService()
120                    .addProposal(userId, groupId, className, classPK, name,
121             description, reviewUserId, addCommunityPermissions,
122             addGuestPermissions);
123     }
124 
125     public static com.liferay.portlet.tasks.model.TasksProposal addProposal(
126         long userId, long groupId, java.lang.String className,
127         java.lang.String classPK, java.lang.String name,
128         java.lang.String description, long reviewUserId,
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                    .addProposal(userId, groupId, className, classPK, name,
135             description, reviewUserId, communityPermissions, guestPermissions);
136     }
137 
138     public static com.liferay.portlet.tasks.model.TasksProposal addProposal(
139         long userId, long groupId, java.lang.String className,
140         java.lang.String classPK, java.lang.String name,
141         java.lang.String description, long reviewUserId,
142         java.lang.Boolean addCommunityPermissions,
143         java.lang.Boolean addGuestPermissions,
144         java.lang.String[] communityPermissions,
145         java.lang.String[] guestPermissions)
146         throws com.liferay.portal.PortalException,
147             com.liferay.portal.SystemException {
148         return getService()
149                    .addProposal(userId, groupId, className, classPK, name,
150             description, reviewUserId, addCommunityPermissions,
151             addGuestPermissions, communityPermissions, guestPermissions);
152     }
153 
154     public static void addProposalResources(long proposalId,
155         boolean addCommunityPermissions, boolean addGuestPermissions)
156         throws com.liferay.portal.PortalException,
157             com.liferay.portal.SystemException {
158         getService()
159             .addProposalResources(proposalId, addCommunityPermissions,
160             addGuestPermissions);
161     }
162 
163     public static void addProposalResources(
164         com.liferay.portlet.tasks.model.TasksProposal proposal,
165         boolean addCommunityPermissions, boolean addGuestPermissions)
166         throws com.liferay.portal.PortalException,
167             com.liferay.portal.SystemException {
168         getService()
169             .addProposalResources(proposal, addCommunityPermissions,
170             addGuestPermissions);
171     }
172 
173     public static void addProposalResources(long proposalId,
174         java.lang.String[] communityPermissions,
175         java.lang.String[] guestPermissions)
176         throws com.liferay.portal.PortalException,
177             com.liferay.portal.SystemException {
178         getService()
179             .addProposalResources(proposalId, communityPermissions,
180             guestPermissions);
181     }
182 
183     public static void addProposalResources(
184         com.liferay.portlet.tasks.model.TasksProposal proposal,
185         java.lang.String[] communityPermissions,
186         java.lang.String[] guestPermissions)
187         throws com.liferay.portal.PortalException,
188             com.liferay.portal.SystemException {
189         getService()
190             .addProposalResources(proposal, communityPermissions,
191             guestPermissions);
192     }
193 
194     public static void deleteProposal(java.lang.String className,
195         java.lang.String classPK)
196         throws com.liferay.portal.PortalException,
197             com.liferay.portal.SystemException {
198         getService().deleteProposal(className, classPK);
199     }
200 
201     public static void deleteProposal(long classNameId, java.lang.String classPK)
202         throws com.liferay.portal.PortalException,
203             com.liferay.portal.SystemException {
204         getService().deleteProposal(classNameId, classPK);
205     }
206 
207     public static void deleteProposal(long proposalId)
208         throws com.liferay.portal.PortalException,
209             com.liferay.portal.SystemException {
210         getService().deleteProposal(proposalId);
211     }
212 
213     public static void deleteProposal(
214         com.liferay.portlet.tasks.model.TasksProposal proposal)
215         throws com.liferay.portal.PortalException,
216             com.liferay.portal.SystemException {
217         getService().deleteProposal(proposal);
218     }
219 
220     public static void deleteProposals(long groupId)
221         throws com.liferay.portal.SystemException {
222         getService().deleteProposals(groupId);
223     }
224 
225     public static com.liferay.portlet.tasks.model.TasksProposal getProposal(
226         long proposalId)
227         throws com.liferay.portal.PortalException,
228             com.liferay.portal.SystemException {
229         return getService().getProposal(proposalId);
230     }
231 
232     public static com.liferay.portlet.tasks.model.TasksProposal getProposal(
233         java.lang.String className, java.lang.String classPK)
234         throws com.liferay.portal.PortalException,
235             com.liferay.portal.SystemException {
236         return getService().getProposal(className, classPK);
237     }
238 
239     public static com.liferay.portlet.tasks.model.TasksProposal getProposal(
240         long classNameId, java.lang.String classPK)
241         throws com.liferay.portal.PortalException,
242             com.liferay.portal.SystemException {
243         return getService().getProposal(classNameId, classPK);
244     }
245 
246     public static java.util.List<com.liferay.portlet.tasks.model.TasksProposal> getProposals(
247         long groupId, int start, int end)
248         throws com.liferay.portal.SystemException {
249         return getService().getProposals(groupId, start, end);
250     }
251 
252     public static int getProposalsCount(long groupId)
253         throws com.liferay.portal.SystemException {
254         return getService().getProposalsCount(groupId);
255     }
256 
257     public static java.util.List<com.liferay.portlet.tasks.model.TasksProposal> getReviewProposals(
258         long groupId, long userId, int start, int end)
259         throws com.liferay.portal.SystemException {
260         return getService().getReviewProposals(groupId, userId, start, end);
261     }
262 
263     public static int getReviewProposalsCount(long groupId, long userId)
264         throws com.liferay.portal.SystemException {
265         return getService().getReviewProposalsCount(groupId, userId);
266     }
267 
268     public static java.util.List<com.liferay.portlet.tasks.model.TasksProposal> getUserProposals(
269         long groupId, long userId, int start, int end)
270         throws com.liferay.portal.SystemException {
271         return getService().getUserProposals(groupId, userId, start, end);
272     }
273 
274     public static int getUserProposalsCount(long groupId, long userId)
275         throws com.liferay.portal.SystemException {
276         return getService().getUserProposalsCount(groupId, userId);
277     }
278 
279     public static com.liferay.portlet.tasks.model.TasksProposal updateProposal(
280         long userId, long proposalId, java.lang.String description,
281         int dueDateMonth, int dueDateDay, int dueDateYear, int dueDateHour,
282         int dueDateMinute)
283         throws com.liferay.portal.PortalException,
284             com.liferay.portal.SystemException {
285         return getService()
286                    .updateProposal(userId, proposalId, description,
287             dueDateMonth, dueDateDay, dueDateYear, dueDateHour, dueDateMinute);
288     }
289 
290     public static TasksProposalLocalService getService() {
291         if (_service == null) {
292             throw new RuntimeException("TasksProposalLocalService is not set");
293         }
294 
295         return _service;
296     }
297 
298     public void setService(TasksProposalLocalService service) {
299         _service = service;
300     }
301 
302     private static TasksProposalLocalService _service;
303 }