1   /**
2    * Copyright (c) 2000-2008 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.calendar.service;
24  
25  import com.liferay.portal.PortalException;
26  import com.liferay.portal.SystemException;
27  import com.liferay.portal.kernel.annotation.Propagation;
28  import com.liferay.portal.kernel.annotation.Transactional;
29  
30  /**
31   * <a href="CalEventLocalService.java.html"><b><i>View Source</i></b></a>
32   *
33   * <p>
34   * ServiceBuilder generated this class. Modifications in this class will be
35   * overwritten the next time is generated.
36   * </p>
37   *
38   * <p>
39   * This interface defines the service. The default implementation is
40   * <code>com.liferay.portlet.calendar.service.impl.CalEventLocalServiceImpl</code>.
41   * Modify methods in that class and rerun ServiceBuilder to populate this class
42   * and all other generated classes.
43   * </p>
44   *
45   * <p>
46   * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
47   * </p>
48   *
49   * @author Brian Wing Shun Chan
50   *
51   * @see com.liferay.portlet.calendar.service.CalEventLocalServiceUtil
52   *
53   */
54  @Transactional(rollbackFor =  {
55      PortalException.class, SystemException.class})
56  public interface CalEventLocalService {
57      public com.liferay.portlet.calendar.model.CalEvent addCalEvent(
58          com.liferay.portlet.calendar.model.CalEvent calEvent)
59          throws com.liferay.portal.SystemException;
60  
61      public com.liferay.portlet.calendar.model.CalEvent createCalEvent(
62          long eventId);
63  
64      public void deleteCalEvent(long eventId)
65          throws com.liferay.portal.SystemException,
66              com.liferay.portal.PortalException;
67  
68      public void deleteCalEvent(
69          com.liferay.portlet.calendar.model.CalEvent calEvent)
70          throws com.liferay.portal.SystemException;
71  
72      public java.util.List<Object> dynamicQuery(
73          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
74          throws com.liferay.portal.SystemException;
75  
76      public java.util.List<Object> dynamicQuery(
77          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
78          int end) throws com.liferay.portal.SystemException;
79  
80      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
81      public com.liferay.portlet.calendar.model.CalEvent getCalEvent(long eventId)
82          throws com.liferay.portal.SystemException,
83              com.liferay.portal.PortalException;
84  
85      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
86      public java.util.List<com.liferay.portlet.calendar.model.CalEvent> getCalEvents(
87          int start, int end) throws com.liferay.portal.SystemException;
88  
89      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
90      public int getCalEventsCount() throws com.liferay.portal.SystemException;
91  
92      public com.liferay.portlet.calendar.model.CalEvent updateCalEvent(
93          com.liferay.portlet.calendar.model.CalEvent calEvent)
94          throws com.liferay.portal.SystemException;
95  
96      public com.liferay.portlet.calendar.model.CalEvent addEvent(long userId,
97          long plid, java.lang.String title, java.lang.String description,
98          int startDateMonth, int startDateDay, int startDateYear,
99          int startDateHour, int startDateMinute, int endDateMonth,
100         int endDateDay, int endDateYear, int durationHour, int durationMinute,
101         boolean allDay, boolean timeZoneSensitive, java.lang.String type,
102         boolean repeating,
103         com.liferay.portal.kernel.cal.TZSRecurrence recurrence,
104         java.lang.String remindBy, int firstReminder, int secondReminder,
105         boolean addCommunityPermissions, boolean addGuestPermissions)
106         throws com.liferay.portal.PortalException,
107             com.liferay.portal.SystemException;
108 
109     public com.liferay.portlet.calendar.model.CalEvent addEvent(
110         java.lang.String uuid, long userId, long plid, java.lang.String title,
111         java.lang.String description, int startDateMonth, int startDateDay,
112         int startDateYear, int startDateHour, int startDateMinute,
113         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
114         int durationMinute, boolean allDay, boolean timeZoneSensitive,
115         java.lang.String type, boolean repeating,
116         com.liferay.portal.kernel.cal.TZSRecurrence recurrence,
117         java.lang.String remindBy, int firstReminder, int secondReminder,
118         boolean addCommunityPermissions, boolean addGuestPermissions)
119         throws com.liferay.portal.PortalException,
120             com.liferay.portal.SystemException;
121 
122     public com.liferay.portlet.calendar.model.CalEvent addEvent(long userId,
123         long plid, java.lang.String title, java.lang.String description,
124         int startDateMonth, int startDateDay, int startDateYear,
125         int startDateHour, int startDateMinute, int endDateMonth,
126         int endDateDay, int endDateYear, int durationHour, int durationMinute,
127         boolean allDay, boolean timeZoneSensitive, java.lang.String type,
128         boolean repeating,
129         com.liferay.portal.kernel.cal.TZSRecurrence recurrence,
130         java.lang.String remindBy, int firstReminder, int secondReminder,
131         java.lang.String[] communityPermissions,
132         java.lang.String[] guestPermissions)
133         throws com.liferay.portal.PortalException,
134             com.liferay.portal.SystemException;
135 
136     public com.liferay.portlet.calendar.model.CalEvent addEvent(
137         java.lang.String uuid, long userId, long plid, java.lang.String title,
138         java.lang.String description, int startDateMonth, int startDateDay,
139         int startDateYear, int startDateHour, int startDateMinute,
140         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
141         int durationMinute, boolean allDay, boolean timeZoneSensitive,
142         java.lang.String type, boolean repeating,
143         com.liferay.portal.kernel.cal.TZSRecurrence recurrence,
144         java.lang.String remindBy, int firstReminder, int secondReminder,
145         java.lang.Boolean addCommunityPermissions,
146         java.lang.Boolean addGuestPermissions,
147         java.lang.String[] communityPermissions,
148         java.lang.String[] guestPermissions)
149         throws com.liferay.portal.PortalException,
150             com.liferay.portal.SystemException;
151 
152     public void addEventResources(long eventId,
153         boolean addCommunityPermissions, boolean addGuestPermissions)
154         throws com.liferay.portal.PortalException,
155             com.liferay.portal.SystemException;
156 
157     public void addEventResources(
158         com.liferay.portlet.calendar.model.CalEvent event,
159         boolean addCommunityPermissions, boolean addGuestPermissions)
160         throws com.liferay.portal.PortalException,
161             com.liferay.portal.SystemException;
162 
163     public void addEventResources(long eventId,
164         java.lang.String[] communityPermissions,
165         java.lang.String[] guestPermissions)
166         throws com.liferay.portal.PortalException,
167             com.liferay.portal.SystemException;
168 
169     public void addEventResources(
170         com.liferay.portlet.calendar.model.CalEvent event,
171         java.lang.String[] communityPermissions,
172         java.lang.String[] guestPermissions)
173         throws com.liferay.portal.PortalException,
174             com.liferay.portal.SystemException;
175 
176     public void checkEvents()
177         throws com.liferay.portal.PortalException,
178             com.liferay.portal.SystemException;
179 
180     public void deleteEvent(long eventId)
181         throws com.liferay.portal.PortalException,
182             com.liferay.portal.SystemException;
183 
184     public void deleteEvent(com.liferay.portlet.calendar.model.CalEvent event)
185         throws com.liferay.portal.PortalException,
186             com.liferay.portal.SystemException;
187 
188     public void deleteEvents(long groupId)
189         throws com.liferay.portal.PortalException,
190             com.liferay.portal.SystemException;
191 
192     public java.io.File exportEvent(long userId, long eventId)
193         throws com.liferay.portal.PortalException,
194             com.liferay.portal.SystemException;
195 
196     public java.io.File exportGroupEvents(long userId, long plid,
197         java.lang.String fileName)
198         throws com.liferay.portal.PortalException,
199             com.liferay.portal.SystemException;
200 
201     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
202     public com.liferay.portlet.calendar.model.CalEvent getEvent(long eventId)
203         throws com.liferay.portal.PortalException,
204             com.liferay.portal.SystemException;
205 
206     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
207     public java.util.List<com.liferay.portlet.calendar.model.CalEvent> getEvents(
208         long groupId, java.lang.String type, int start, int end)
209         throws com.liferay.portal.SystemException;
210 
211     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
212     public java.util.List<com.liferay.portlet.calendar.model.CalEvent> getEvents(
213         long groupId, java.util.Calendar cal)
214         throws com.liferay.portal.SystemException;
215 
216     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
217     public java.util.List<com.liferay.portlet.calendar.model.CalEvent> getEvents(
218         long groupId, java.util.Calendar cal, java.lang.String type)
219         throws com.liferay.portal.SystemException;
220 
221     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
222     public int getEventsCount(long groupId, java.lang.String type)
223         throws com.liferay.portal.SystemException;
224 
225     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
226     public java.util.List<com.liferay.portlet.calendar.model.CalEvent> getRepeatingEvents(
227         long groupId) throws com.liferay.portal.SystemException;
228 
229     public boolean hasEvents(long groupId, java.util.Calendar cal)
230         throws com.liferay.portal.SystemException;
231 
232     public boolean hasEvents(long groupId, java.util.Calendar cal,
233         java.lang.String type) throws com.liferay.portal.SystemException;
234 
235     public void importICal4j(long userId, long plid, java.io.File file)
236         throws com.liferay.portal.PortalException,
237             com.liferay.portal.SystemException;
238 
239     public com.liferay.portlet.calendar.model.CalEvent updateEvent(
240         long userId, long eventId, java.lang.String title,
241         java.lang.String description, int startDateMonth, int startDateDay,
242         int startDateYear, int startDateHour, int startDateMinute,
243         int endDateMonth, int endDateDay, int endDateYear, int durationHour,
244         int durationMinute, boolean allDay, boolean timeZoneSensitive,
245         java.lang.String type, boolean repeating,
246         com.liferay.portal.kernel.cal.TZSRecurrence recurrence,
247         java.lang.String remindBy, int firstReminder, int secondReminder)
248         throws com.liferay.portal.PortalException,
249             com.liferay.portal.SystemException;
250 }