1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   * 
13   */
14  
15  package com.liferay.portlet.calendar.service;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  
19  /**
20   * <a href="CalEventLocalServiceUtil.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 CalEventLocalService} 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       CalEventLocalService
37   * @generated
38   */
39  public class CalEventLocalServiceUtil {
40      public static com.liferay.portlet.calendar.model.CalEvent addCalEvent(
41          com.liferay.portlet.calendar.model.CalEvent calEvent)
42          throws com.liferay.portal.SystemException {
43          return getService().addCalEvent(calEvent);
44      }
45  
46      public static com.liferay.portlet.calendar.model.CalEvent createCalEvent(
47          long eventId) {
48          return getService().createCalEvent(eventId);
49      }
50  
51      public static void deleteCalEvent(long eventId)
52          throws com.liferay.portal.PortalException,
53              com.liferay.portal.SystemException {
54          getService().deleteCalEvent(eventId);
55      }
56  
57      public static void deleteCalEvent(
58          com.liferay.portlet.calendar.model.CalEvent calEvent)
59          throws com.liferay.portal.SystemException {
60          getService().deleteCalEvent(calEvent);
61      }
62  
63      public static java.util.List<Object> dynamicQuery(
64          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
65          throws com.liferay.portal.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.SystemException {
72          return getService().dynamicQuery(dynamicQuery, start, end);
73      }
74  
75      public static com.liferay.portlet.calendar.model.CalEvent getCalEvent(
76          long eventId)
77          throws com.liferay.portal.PortalException,
78              com.liferay.portal.SystemException {
79          return getService().getCalEvent(eventId);
80      }
81  
82      public static java.util.List<com.liferay.portlet.calendar.model.CalEvent> getCalEvents(
83          int start, int end) throws com.liferay.portal.SystemException {
84          return getService().getCalEvents(start, end);
85      }
86  
87      public static int getCalEventsCount()
88          throws com.liferay.portal.SystemException {
89          return getService().getCalEventsCount();
90      }
91  
92      public static com.liferay.portlet.calendar.model.CalEvent updateCalEvent(
93          com.liferay.portlet.calendar.model.CalEvent calEvent)
94          throws com.liferay.portal.SystemException {
95          return getService().updateCalEvent(calEvent);
96      }
97  
98      public static com.liferay.portlet.calendar.model.CalEvent updateCalEvent(
99          com.liferay.portlet.calendar.model.CalEvent calEvent, boolean merge)
100         throws com.liferay.portal.SystemException {
101         return getService().updateCalEvent(calEvent, merge);
102     }
103 
104     public static com.liferay.portlet.calendar.model.CalEvent addEvent(
105         long userId, long plid, java.lang.String title,
106         java.lang.String description, int startDateMonth, int startDateDay,
107         int startDateYear, int startDateHour, int startDateMinute,
108         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
109         int durationMinute, boolean allDay, boolean timeZoneSensitive,
110         java.lang.String type, boolean repeating,
111         com.liferay.portal.kernel.cal.TZSRecurrence recurrence, int remindBy,
112         int firstReminder, int secondReminder, boolean addCommunityPermissions,
113         boolean addGuestPermissions)
114         throws com.liferay.portal.PortalException,
115             com.liferay.portal.SystemException {
116         return getService()
117                    .addEvent(userId, plid, title, description, startDateMonth,
118             startDateDay, startDateYear, startDateHour, startDateMinute,
119             endDateMonth, endDateDay, endDateYear, durationHour,
120             durationMinute, allDay, timeZoneSensitive, type, repeating,
121             recurrence, remindBy, firstReminder, secondReminder,
122             addCommunityPermissions, addGuestPermissions);
123     }
124 
125     public static com.liferay.portlet.calendar.model.CalEvent addEvent(
126         long userId, long plid, java.lang.String title,
127         java.lang.String description, int startDateMonth, int startDateDay,
128         int startDateYear, int startDateHour, int startDateMinute,
129         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
130         int durationMinute, boolean allDay, boolean timeZoneSensitive,
131         java.lang.String type, boolean repeating,
132         com.liferay.portal.kernel.cal.TZSRecurrence recurrence, int remindBy,
133         int firstReminder, int secondReminder,
134         java.lang.String[] communityPermissions,
135         java.lang.String[] guestPermissions)
136         throws com.liferay.portal.PortalException,
137             com.liferay.portal.SystemException {
138         return getService()
139                    .addEvent(userId, plid, title, description, startDateMonth,
140             startDateDay, startDateYear, startDateHour, startDateMinute,
141             endDateMonth, endDateDay, endDateYear, durationHour,
142             durationMinute, allDay, timeZoneSensitive, type, repeating,
143             recurrence, remindBy, firstReminder, secondReminder,
144             communityPermissions, guestPermissions);
145     }
146 
147     public static com.liferay.portlet.calendar.model.CalEvent addEvent(
148         java.lang.String uuid, long userId, long plid, java.lang.String title,
149         java.lang.String description, int startDateMonth, int startDateDay,
150         int startDateYear, int startDateHour, int startDateMinute,
151         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
152         int durationMinute, boolean allDay, boolean timeZoneSensitive,
153         java.lang.String type, boolean repeating,
154         com.liferay.portal.kernel.cal.TZSRecurrence recurrence, int remindBy,
155         int firstReminder, int secondReminder, boolean addCommunityPermissions,
156         boolean addGuestPermissions)
157         throws com.liferay.portal.PortalException,
158             com.liferay.portal.SystemException {
159         return getService()
160                    .addEvent(uuid, userId, plid, title, description,
161             startDateMonth, startDateDay, startDateYear, startDateHour,
162             startDateMinute, endDateMonth, endDateDay, endDateYear,
163             durationHour, durationMinute, allDay, timeZoneSensitive, type,
164             repeating, recurrence, remindBy, firstReminder, secondReminder,
165             addCommunityPermissions, addGuestPermissions);
166     }
167 
168     public static com.liferay.portlet.calendar.model.CalEvent addEvent(
169         java.lang.String uuid, long userId, long plid, java.lang.String title,
170         java.lang.String description, int startDateMonth, int startDateDay,
171         int startDateYear, int startDateHour, int startDateMinute,
172         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
173         int durationMinute, boolean allDay, boolean timeZoneSensitive,
174         java.lang.String type, boolean repeating,
175         com.liferay.portal.kernel.cal.TZSRecurrence recurrence, int remindBy,
176         int firstReminder, int secondReminder,
177         java.lang.Boolean addCommunityPermissions,
178         java.lang.Boolean addGuestPermissions,
179         java.lang.String[] communityPermissions,
180         java.lang.String[] guestPermissions)
181         throws com.liferay.portal.PortalException,
182             com.liferay.portal.SystemException {
183         return getService()
184                    .addEvent(uuid, userId, plid, title, description,
185             startDateMonth, startDateDay, startDateYear, startDateHour,
186             startDateMinute, endDateMonth, endDateDay, endDateYear,
187             durationHour, durationMinute, allDay, timeZoneSensitive, type,
188             repeating, recurrence, remindBy, firstReminder, secondReminder,
189             addCommunityPermissions, addGuestPermissions, communityPermissions,
190             guestPermissions);
191     }
192 
193     public static void addEventResources(
194         com.liferay.portlet.calendar.model.CalEvent event,
195         boolean addCommunityPermissions, boolean addGuestPermissions)
196         throws com.liferay.portal.PortalException,
197             com.liferay.portal.SystemException {
198         getService()
199             .addEventResources(event, addCommunityPermissions,
200             addGuestPermissions);
201     }
202 
203     public static void addEventResources(
204         com.liferay.portlet.calendar.model.CalEvent event,
205         java.lang.String[] communityPermissions,
206         java.lang.String[] guestPermissions)
207         throws com.liferay.portal.PortalException,
208             com.liferay.portal.SystemException {
209         getService()
210             .addEventResources(event, communityPermissions, guestPermissions);
211     }
212 
213     public static void addEventResources(long eventId,
214         boolean addCommunityPermissions, boolean addGuestPermissions)
215         throws com.liferay.portal.PortalException,
216             com.liferay.portal.SystemException {
217         getService()
218             .addEventResources(eventId, addCommunityPermissions,
219             addGuestPermissions);
220     }
221 
222     public static void addEventResources(long eventId,
223         java.lang.String[] communityPermissions,
224         java.lang.String[] guestPermissions)
225         throws com.liferay.portal.PortalException,
226             com.liferay.portal.SystemException {
227         getService()
228             .addEventResources(eventId, communityPermissions, guestPermissions);
229     }
230 
231     public static void checkEvents()
232         throws com.liferay.portal.PortalException,
233             com.liferay.portal.SystemException {
234         getService().checkEvents();
235     }
236 
237     public static void deleteEvent(
238         com.liferay.portlet.calendar.model.CalEvent event)
239         throws com.liferay.portal.PortalException,
240             com.liferay.portal.SystemException {
241         getService().deleteEvent(event);
242     }
243 
244     public static void deleteEvent(long eventId)
245         throws com.liferay.portal.PortalException,
246             com.liferay.portal.SystemException {
247         getService().deleteEvent(eventId);
248     }
249 
250     public static void deleteEvents(long groupId)
251         throws com.liferay.portal.PortalException,
252             com.liferay.portal.SystemException {
253         getService().deleteEvents(groupId);
254     }
255 
256     public static java.io.File exportEvent(long userId, long eventId)
257         throws com.liferay.portal.PortalException,
258             com.liferay.portal.SystemException {
259         return getService().exportEvent(userId, eventId);
260     }
261 
262     public static java.io.File exportGroupEvents(long userId, long plid,
263         java.lang.String fileName)
264         throws com.liferay.portal.PortalException,
265             com.liferay.portal.SystemException {
266         return getService().exportGroupEvents(userId, plid, fileName);
267     }
268 
269     public static com.liferay.portlet.calendar.model.CalEvent getEvent(
270         long eventId)
271         throws com.liferay.portal.PortalException,
272             com.liferay.portal.SystemException {
273         return getService().getEvent(eventId);
274     }
275 
276     public static java.util.List<com.liferay.portlet.calendar.model.CalEvent> getEvents(
277         long groupId, java.util.Calendar cal)
278         throws com.liferay.portal.SystemException {
279         return getService().getEvents(groupId, cal);
280     }
281 
282     public static java.util.List<com.liferay.portlet.calendar.model.CalEvent> getEvents(
283         long groupId, java.util.Calendar cal, java.lang.String type)
284         throws com.liferay.portal.SystemException {
285         return getService().getEvents(groupId, cal, type);
286     }
287 
288     public static java.util.List<com.liferay.portlet.calendar.model.CalEvent> getEvents(
289         long groupId, java.lang.String type, int start, int end)
290         throws com.liferay.portal.SystemException {
291         return getService().getEvents(groupId, type, start, end);
292     }
293 
294     public static int getEventsCount(long groupId, java.lang.String type)
295         throws com.liferay.portal.SystemException {
296         return getService().getEventsCount(groupId, type);
297     }
298 
299     public static java.util.List<com.liferay.portlet.calendar.model.CalEvent> getRepeatingEvents(
300         long groupId) throws com.liferay.portal.SystemException {
301         return getService().getRepeatingEvents(groupId);
302     }
303 
304     public static boolean hasEvents(long groupId, java.util.Calendar cal)
305         throws com.liferay.portal.SystemException {
306         return getService().hasEvents(groupId, cal);
307     }
308 
309     public static boolean hasEvents(long groupId, java.util.Calendar cal,
310         java.lang.String type) throws com.liferay.portal.SystemException {
311         return getService().hasEvents(groupId, cal, type);
312     }
313 
314     public static void importICal4j(long userId, long plid, java.io.File file)
315         throws com.liferay.portal.PortalException,
316             com.liferay.portal.SystemException {
317         getService().importICal4j(userId, plid, file);
318     }
319 
320     public static com.liferay.portlet.calendar.model.CalEvent updateEvent(
321         long userId, long eventId, java.lang.String title,
322         java.lang.String description, int startDateMonth, int startDateDay,
323         int startDateYear, int startDateHour, int startDateMinute,
324         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
325         int durationMinute, boolean allDay, boolean timeZoneSensitive,
326         java.lang.String type, boolean repeating,
327         com.liferay.portal.kernel.cal.TZSRecurrence recurrence, int remindBy,
328         int firstReminder, int secondReminder)
329         throws com.liferay.portal.PortalException,
330             com.liferay.portal.SystemException {
331         return getService()
332                    .updateEvent(userId, eventId, title, description,
333             startDateMonth, startDateDay, startDateYear, startDateHour,
334             startDateMinute, endDateMonth, endDateDay, endDateYear,
335             durationHour, durationMinute, allDay, timeZoneSensitive, type,
336             repeating, recurrence, remindBy, firstReminder, secondReminder);
337     }
338 
339     public static CalEventLocalService getService() {
340         if (_service == null) {
341             _service = (CalEventLocalService)PortalBeanLocatorUtil.locate(CalEventLocalService.class.getName());
342         }
343 
344         return _service;
345     }
346 
347     public void setService(CalEventLocalService service) {
348         _service = service;
349     }
350 
351     private static CalEventLocalService _service;
352 }