@Produces(value="application/json") @Path(value="/calendar") public class CalendarWebService extends Object
Constructor and Description |
---|
CalendarWebService() |
Modifier and Type | Method and Description |
---|---|
ServiceResult |
delete(String sid,
Long id)
delete a calendar event
If the given SID is from an Administrator or Web-Service user, the user
can delete any appointment.
If the SID is assigned to a simple user, he can only delete appointments where he is also the owner/creator of the appointment |
AppointmentDTO |
getByRoom(String sid,
long roomid)
Load a calendar event by its room id
|
List<AppointmentDTO> |
getByTitle(String sid,
String title)
Search a calendar event for the current SID
|
AppointmentDTO |
next(String sid)
Get the next Calendar event for the current user of the SID
|
AppointmentDTO |
nextForUser(String sid,
long userid)
Get the next Calendar event for userId
|
List<AppointmentDTO> |
range(String sid,
Calendar start,
Calendar end)
Load appointments by a start / end range for the current SID
|
List<AppointmentDTO> |
rangeForUser(String sid,
long userid,
Calendar start,
Calendar end)
Load appointments by a start / end range for the userId
|
AppointmentDTO |
save(String sid,
AppointmentDTO appointment)
Save an appointment
|
@GET @Path(value="/{start}/{end}") public List<AppointmentDTO> range(@QueryParam(value="sid") String sid, @PathParam(value="start") Calendar start, @PathParam(value="end") Calendar end) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- The SID of the User. This SID must be marked as Loggedinstart
- start timeend
- end time{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@GET @Path(value="/{userid}/{start}/{end}") public List<AppointmentDTO> rangeForUser(@QueryParam(value="sid") String sid, @PathParam(value="userid") long userid, @PathParam(value="start") Calendar start, @PathParam(value="end") Calendar end) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- The SID of the User. This SID must be marked as Loggedinuserid
- the userId the calendar events should be loadedstart
- start timeend
- end time{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@GET @Path(value="/next") public AppointmentDTO next(@QueryParam(value="sid") String sid) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- The SID of the User. This SID must be marked as Loggedin{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@GET @Path(value="/next/{userid}") public AppointmentDTO nextForUser(@QueryParam(value="sid") String sid, @PathParam(value="userid") long userid) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- The SID of the User. This SID must be marked as Loggedinuserid
- the userId the calendar events should be loaded{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@GET @Path(value="/room/{roomid}") public AppointmentDTO getByRoom(@QueryParam(value="sid") String sid, @PathParam(value="roomid") long roomid) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- roomid
- {@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@GET @Path(value="/title/{title}") public List<AppointmentDTO> getByTitle(@QueryParam(value="sid") String sid, @PathParam(value="title") String title) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- The SID of the User. This SID must be marked as Loggedintitle
- the search string{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@POST @Path(value="/") public AppointmentDTO save(@QueryParam(value="sid") String sid, @FormParam(value="appointment") AppointmentDTO appointment) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- The SID of the User. This SID must be marked as Loggedinappointment
- calendar event{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
@DELETE @Path(value="/{id}") public ServiceResult delete(@QueryParam(value="sid") String sid, @PathParam(value="id") Long id) throws org.apache.openmeetings.webservice.error.ServiceException
sid
- an authenticated SIDid
- the id to deleteServiceResult
of type SUCCESS{@link
- ServiceException} in case of any errororg.apache.openmeetings.webservice.error.ServiceException
Copyright © 2012–2017 Apache Software Foundation. All rights reserved.