public Object createServiceObjectWithServiceParam( ExchangeService srv) throws Exception { return new MeetingRequest(srv); } }, new ICreateServiceObjectWithAttachmentParam() {
/** * Binds to an existing meeting response and loads the specified set of * property. Calling this method results in a call to EWS. * * @param service The service to use to bind to the meeting request. * @param id The Id of the meeting request to bind to. * @return A MeetingResponse instance representing the meeting request * corresponding to the specified Id. */ public static MeetingRequest bind(ExchangeService service, ItemId id) { return MeetingRequest.bind(service, id, PropertySet .getFirstClassProperties()); }
private AppointmentDto convertToAppointmentDto(final MeetingRequest meeting) throws ServiceLocalException { final AppointmentDto appointmentDto = new AppointmentDto(); appointmentDto.setExchangeId(meeting.getId().getUniqueId()); appointmentDto.setLastModified(convertToJodaDateTime(meeting.getLastModifiedTime())); appointmentDto.setSummary(meeting.getSubject()); try { appointmentDto.setDescription(MessageBody.getStringFromMessageBody(meeting.getBody())); } catch (final Exception e) { LOG.error("Unable to retrieve appointment body from Exchange", e); appointmentDto.setStart(convertToJodaDateTime(meeting.getStart())); appointmentDto.setEnd(convertToJodaDateTime(meeting.getEnd())); appointmentDto.setAllDay(meeting.getIsAllDayEvent()); appointmentDto.setLocation(meeting.getLocation()); if (meeting.getOrganizer() != null) { appointmentDto.setOrganizer(convertToPersonDto(meeting.getOrganizer(), false)); if (meeting.getRequiredAttendees() != null) { for (final Attendee exchangeAttendee : meeting.getRequiredAttendees()) { attendees.add(convertToPersonDto(exchangeAttendee, false)); if (meeting.getOptionalAttendees() != null) { for (final Attendee exchangeAttendee : meeting.getOptionalAttendees()) { attendees.add(convertToPersonDto(exchangeAttendee, true)); appointmentDto.setReminderMinutesBeforeStart(meeting.getReminderMinutesBeforeStart()); if (meeting.getRecurrence() != null) { if (meeting.getRecurrence() instanceof Recurrence.DailyPattern) { appointmentDto.setRecurrenceType(RecurrenceType.DAILY); } else if (meeting.getRecurrence() instanceof Recurrence.WeeklyPattern) {
/** * Declines the meeting invitation. Calling this method results in a call to * EWS. * * @param sendResponse Indicates whether to send a response to the organizer. * @return A CalendarActionResults object containing the various item that * were created or modified as a results of this operation. * @throws Exception throws Exception */ public CalendarActionResults decline(boolean sendResponse) throws Exception { DeclineMeetingInvitationMessage decline = this.createDeclineMessage(); if (sendResponse) { return decline.calendarSendAndSaveCopy(); } else { return decline.calendarSave(); } }
/** * Accepts the meeting. * * @param tentative True if tentative accept. * @param sendResponse Indicates whether to send a response to the organizer. * @return A CalendarActionResults object containing the various item that * were created or modified as a results of this operation. * @throws Exception throws Exception */ protected CalendarActionResults internalAccept(boolean tentative, boolean sendResponse) throws Exception { AcceptMeetingInvitationMessage accept = this .createAcceptMessage(tentative); if (sendResponse) { return accept.calendarSendAndSaveCopy(); } else { return accept.calendarSave(); } }
/** * Declines the meeting invitation. Calling this method results in a call to * EWS. * * @param sendResponse Indicates whether to send a response to the organizer. * @return A CalendarActionResults object containing the various item that * were created or modified as a results of this operation. * @throws Exception throws Exception */ public CalendarActionResults decline(boolean sendResponse) throws Exception { DeclineMeetingInvitationMessage decline = this.createDeclineMessage(); if (sendResponse) { return decline.calendarSendAndSaveCopy(); } else { return decline.calendarSave(); } }
/** * Accepts the meeting. * * @param tentative True if tentative accept. * @param sendResponse Indicates whether to send a response to the organizer. * @return A CalendarActionResults object containing the various item that * were created or modified as a results of this operation. * @throws Exception throws Exception */ protected CalendarActionResults internalAccept(boolean tentative, boolean sendResponse) throws Exception { AcceptMeetingInvitationMessage accept = this .createAcceptMessage(tentative); if (sendResponse) { return accept.calendarSendAndSaveCopy(); } else { return accept.calendarSave(); } }
public Object createServiceObjectWithAttachmentParam( ItemAttachment itemAttachment, boolean isNew) throws Exception { return new MeetingRequest(itemAttachment); } });
/** * Binds to an existing meeting response and loads the specified set of * property. Calling this method results in a call to EWS. * * @param service The service to use to bind to the meeting request. * @param id The Id of the meeting request to bind to. * @return A MeetingResponse instance representing the meeting request * corresponding to the specified Id. */ public static MeetingRequest bind(ExchangeService service, ItemId id) { return MeetingRequest.bind(service, id, PropertySet .getFirstClassProperties()); }
public Object createServiceObjectWithAttachmentParam( ItemAttachment itemAttachment, boolean isNew) throws Exception { return new MeetingRequest(itemAttachment); } });
public Object createServiceObjectWithServiceParam( ExchangeService srv) throws Exception { return new MeetingRequest(srv); } }, new ICreateServiceObjectWithAttachmentParam() {