Class ICalService
- java.lang.Object
-
- fr.paris.lutece.plugins.workflow.modules.appointment.service.ICalService
-
public class ICalService extends Object
Service to send iCal appointments by email
-
-
Constructor Summary
Constructors Constructor Description ICalService()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddAlternativeHtmlDescription(net.fortuna.ical4j.model.component.VEvent event, String description)Add an alternative description to process and render HTML content properly.static StringformatICalendarDescription(String strDescription)Format the String containing the description of a calendar invite to respect the ICalendar specifications: 75 characters per line, CRLF + white-space at the start of new lines...static ICalServicegetService()Get an instance of the servicevoidsendAppointment(String strEmailAttendee, String strEmailOptionnal, String strSubject, String strBodyContent, String strLocation, String strSenderName, String strSenderEmail, fr.paris.lutece.plugins.appointment.web.dto.AppointmentDTO appointment, boolean bCreate)Send an appointment to a user by email.
-
-
-
Field Detail
-
BEAN_NAME
public static final String BEAN_NAME
The name of the bean of this service- See Also:
- Constant Field Values
-
-
Method Detail
-
getService
public static ICalService getService()
Get an instance of the service- Returns:
- An instance of the bean of this service
-
sendAppointment
public void sendAppointment(String strEmailAttendee, String strEmailOptionnal, String strSubject, String strBodyContent, String strLocation, String strSenderName, String strSenderEmail, fr.paris.lutece.plugins.appointment.web.dto.AppointmentDTO appointment, boolean bCreate)
Send an appointment to a user by email.- Parameters:
strEmailAttendee- Comma separated list of users that will attend the appointmentstrEmailOptionnal- Comma separated list of users that will be invited to the appointment, but who are not required.strSubject- The subject of the appointment.strBodyContent- The body content that describes the appointmentstrLocation- The location of the appointmentstrSenderName- The name of the senderstrSenderEmail- The email of the senderappointment- The appointmentbCreate- True to notify the creation of the appointment, false to notify its removal
-
formatICalendarDescription
public static String formatICalendarDescription(String strDescription)
Format the String containing the description of a calendar invite to respect the ICalendar specifications: 75 characters per line, CRLF + white-space at the start of new lines... ( c.f. iCalendar RFC5545 )- Parameters:
strDescription- The calendar's invite description to format- Returns:
- the formated description, or the value of the original description if the formatting was not necessary
-
addAlternativeHtmlDescription
public void addAlternativeHtmlDescription(net.fortuna.ical4j.model.component.VEvent event, String description)Add an alternative description to process and render HTML content properly. This should only be used if there is HTML in the description- Parameters:
event- The Calendar Event being createddescription- The description of the Event
-
-