| org.sakaiproject.calendar.api.Calendar
Calendar | public interface Calendar extends Entity(Code) | | Calendar is the base interface for Calendar service calendars.
Calendars contains collections of CalendarEvents.
|
Method Summary | |
public CalendarEvent | addEvent(TimeRange range, String displayName, String description, String type, String location, EventAccess access, Collection groups, List attachments) Add a new event to this calendar.
Parameters: range - The event's time range. Parameters: displayName - The event's display name (PROP_DISPLAY_NAME) property value. Parameters: description - The event's description (PROP_DESCRIPTION) property value. Parameters: type - The event's calendar event type (PROP_CALENDAR_TYPE) property value. Parameters: location - The event's calendar event location (PROP_CALENDAR_LOCATION) property value. Parameters: access - The event's access type site or grouped Parameters: groups - The groups which can access this event Parameters: attachments - The event attachments, a vector of Reference objects. | public CalendarEvent | addEvent(TimeRange range, String displayName, String description, String type, String location, List attachments) Add a new event to this calendar.
Parameters: range - The event's time range. Parameters: displayName - The event's display name (PROP_DISPLAY_NAME) property value. Parameters: description - The event's description (PROP_DESCRIPTION) property value. Parameters: type - The event's calendar event type (PROP_CALENDAR_TYPE) property value. Parameters: location - The event's calendar event location (PROP_CALENDAR_LOCATION) property value. Parameters: attachments - The event attachments, a vector of Reference objects. | public CalendarEventEdit | addEvent() Add a new event to this calendar. | boolean | allowAddCalendarEvent() Check if the user has permission to add a calendar-wide (not grouped) message. | public boolean | allowAddEvent() check permissions for addEvent(). | public boolean | allowEditEvent(String eventId) check permissions for editEvent()
Parameters: id - The event id. | public boolean | allowGetEvent(String eventId) check permissions for getEvent() for a particular event. | public boolean | allowGetEvents() check permissions for getEvents() and getEvent() on a SITE / calendar level. | public boolean | allowRemoveEvent(CalendarEvent event) check permissions for removeEvent().
Parameters: event - The event from this calendar to remove. | public void | cancelEvent(CalendarEventEdit edit) Cancel the changes made to a CalendarEventEdit object, and release the lock. | public void | commitEvent(CalendarEventEdit edit, int intention) Commit the changes made to a CalendarEventEdit object, and release the lock. | public void | commitEvent(CalendarEventEdit edit) Commit the changes made to a CalendarEventEdit object, and release the lock. | public String | getContext() Access the context of the resource. | public CalendarEventEdit | getEditEvent(String eventId, String editType) Return a specific calendar event, as specified by event name, locked for update. | public CalendarEvent | getEvent(String eventId) Return a specific calendar event, as specified by event name.
Parameters: eventId - The id of the event to get. | public String | getEventFields() Return the extra fields kept for each event in this calendar.
the extra fields kept for each event in this calendar, formatted into a single string. | public List | getEvents(TimeRange range, Filter filter) Return a List of all or filtered events in the calendar.
The order in which the events will be found in the iteration is by event start date.
Parameters: range - A time range to limit the iterated events. | Collection | getGroupsAllowAddEvent() Get the collection of Groups defined for the context of this calendar that the end user has add event permissions in. | Collection | getGroupsAllowGetEvent() Get the collection of Group defined for the context of this calendar that the end user has get event permissions in. | Collection | getGroupsAllowRemoveEvent(boolean own) Get the collection of Group defined for the context of this channel that the end user has remove event permissions in. | public CalendarEventEdit | mergeEvent(Element el) Merge in a new event as defined in the xml. | public void | removeEvent(CalendarEventEdit edit, int intention) Remove an event from the calendar, one locked for edit. | public void | removeEvent(CalendarEventEdit edit) Remove an event from the calendar, one locked for edit. |
addEvent | public CalendarEvent addEvent(TimeRange range, String displayName, String description, String type, String location, EventAccess access, Collection groups, List attachments) throws PermissionException(Code) | | Add a new event to this calendar.
Parameters: range - The event's time range. Parameters: displayName - The event's display name (PROP_DISPLAY_NAME) property value. Parameters: description - The event's description (PROP_DESCRIPTION) property value. Parameters: type - The event's calendar event type (PROP_CALENDAR_TYPE) property value. Parameters: location - The event's calendar event location (PROP_CALENDAR_LOCATION) property value. Parameters: access - The event's access type site or grouped Parameters: groups - The groups which can access this event Parameters: attachments - The event attachments, a vector of Reference objects. The newly added event. exception: PermissionException - If the user does not have permission to modify the calendar. |
addEvent | public CalendarEvent addEvent(TimeRange range, String displayName, String description, String type, String location, List attachments) throws PermissionException(Code) | | Add a new event to this calendar.
Parameters: range - The event's time range. Parameters: displayName - The event's display name (PROP_DISPLAY_NAME) property value. Parameters: description - The event's description (PROP_DESCRIPTION) property value. Parameters: type - The event's calendar event type (PROP_CALENDAR_TYPE) property value. Parameters: location - The event's calendar event location (PROP_CALENDAR_LOCATION) property value. Parameters: attachments - The event attachments, a vector of Reference objects. The newly added event. exception: PermissionException - If the user does not have permission to modify the calendar. |
addEvent | public CalendarEventEdit addEvent() throws PermissionException(Code) | | Add a new event to this calendar.
Must commitEvent() to make official, or cancelEvent() when done!
The newly added event, locked for update. exception: PermissionException - If the user does not have write permission to the calendar. |
allowAddCalendarEvent | boolean allowAddCalendarEvent()(Code) | | Check if the user has permission to add a calendar-wide (not grouped) message.
true if the user has permission to add a calendar-wide (not grouped) message. |
allowAddEvent | public boolean allowAddEvent()(Code) | | check permissions for addEvent().
true if the user is allowed to addEvent(...), false if not. |
allowEditEvent | public boolean allowEditEvent(String eventId)(Code) | | check permissions for editEvent()
Parameters: id - The event id. true if the user is allowed to update the event, false if not. |
allowGetEvent | public boolean allowGetEvent(String eventId)(Code) | | check permissions for getEvent() for a particular event.
true if the user is allowed to get the event from the calendar, false if not. |
allowGetEvents | public boolean allowGetEvents()(Code) | | check permissions for getEvents() and getEvent() on a SITE / calendar level.
true if the user is allowed to get events from the calendar, false if not. |
allowRemoveEvent | public boolean allowRemoveEvent(CalendarEvent event)(Code) | | check permissions for removeEvent().
Parameters: event - The event from this calendar to remove. true if the user is allowed to removeEvent(event), false if not. |
cancelEvent | public void cancelEvent(CalendarEventEdit edit)(Code) | | Cancel the changes made to a CalendarEventEdit object, and release the lock.
The CalendarEventEdit is disabled, and not to be used after this call.
Parameters: edit - The CalendarEventEdit object to commit. |
commitEvent | public void commitEvent(CalendarEventEdit edit, int intention)(Code) | | Commit the changes made to a CalendarEventEdit object, and release the lock.
The CalendarEventEdit is disabled, and not to be used after this call.
Parameters: edit - The CalendarEventEdit object to commit. Parameters: intention - The recurring event modification intention,based on values in the GenericCalendarService "MOD_*",used if the event is part of a recurring event sequence to determine how much of the sequence is changed by this commmit. |
commitEvent | public void commitEvent(CalendarEventEdit edit)(Code) | | Commit the changes made to a CalendarEventEdit object, and release the lock.
The CalendarEventEdit is disabled, and not to be used after this call.
Note: if the event is a recurring event, the entire sequence is modified by this commit (MOD_ALL).
Parameters: edit - The CalendarEventEdit object to commit. |
getContext | public String getContext()(Code) | | Access the context of the resource.
The context. |
getEditEvent | public CalendarEventEdit getEditEvent(String eventId, String editType) throws IdUnusedException, PermissionException, InUseException(Code) | | Return a specific calendar event, as specified by event name, locked for update.
Must commitEvent() to make official, or cancelEvent(), or removeEvent() when done!
Parameters: eventId - The id of the event to get. Parameters: editType - add, remove or modifying calendar? the Event that has the specified id. exception: IdUnusedException - If this name is not a defined event in this calendar. exception: PermissionException - If the user does not have any permissions to edit the event. exception: InUseException - if the event is locked for edit by someone else. |
getEventFields | public String getEventFields()(Code) | | Return the extra fields kept for each event in this calendar.
the extra fields kept for each event in this calendar, formatted into a single string. %%% |
getEvents | public List getEvents(TimeRange range, Filter filter) throws PermissionException(Code) | | Return a List of all or filtered events in the calendar.
The order in which the events will be found in the iteration is by event start date.
Parameters: range - A time range to limit the iterated events. May be null; all events will be returned. Parameters: filter - A filtering object to accept events into the iterator, or null if no filtering is desired. a List of all or filtered CalendarEvents in the calendar (may be empty). exception: PermissionException - if the user does not have read permission to the calendar. |
getGroupsAllowAddEvent | Collection getGroupsAllowAddEvent()(Code) | | Get the collection of Groups defined for the context of this calendar that the end user has add event permissions in.
The Collection (Group) of groups defined for the context of this calendar that the end user has add event permissions in, empty if none. |
getGroupsAllowGetEvent | Collection getGroupsAllowGetEvent()(Code) | | Get the collection of Group defined for the context of this calendar that the end user has get event permissions in.
The Collection (Group) of groups defined for the context of this calendar that the end user has get event permissions in, empty if none. |
getGroupsAllowRemoveEvent | Collection getGroupsAllowRemoveEvent(boolean own)(Code) | | Get the collection of Group defined for the context of this channel that the end user has remove event permissions in.
Parameters: own - boolean flag indicating whether user owns event The Collection (Group) of groups defined for the context of this channel that the end user has remove event permissions in, empty if none. |
removeEvent | public void removeEvent(CalendarEventEdit edit, int intention) throws PermissionException(Code) | | Remove an event from the calendar, one locked for edit.
Parameters: edit - The event from this calendar to remove. Parameters: intention - The recurring event modification intention,based on values in the GenericCalendarService "MOD_*",used if the event is part of a recurring event sequence to determine how much of the sequence is removed. throws: PermissionException - if the end user does not have permission to remove. |
removeEvent | public void removeEvent(CalendarEventEdit edit) throws PermissionException(Code) | | Remove an event from the calendar, one locked for edit.
Note: if the event is a recurring event, the entire sequence is removed by this commit (MOD_ALL).
Parameters: edit - The event from this calendar to remove. throws: PermissionException - if the end user does not have permission to remove. |
|
|