Chapter 144. iCal DataFormat
Available as of Camel version 2.12
The ICal dataformat is used for working with iCalendar messages.
A typical iCalendar message looks like:
BEGIN:VCALENDAR VERSION:2.0 PRODID:-//Events Calendar//iCal4j 1.0//EN CALSCALE:GREGORIAN BEGIN:VEVENT DTSTAMP:20130324T180000Z DTSTART:20130401T170000 DTEND:20130401T210000 SUMMARY:Progress Meeting TZID:America/New_York UID:00000000 ATTENDEE;ROLE=REQ-PARTICIPANT;CN=Developer 1:mailto:dev1@mycompany.com ATTENDEE;ROLE=OPT-PARTICIPANT;CN=Developer 2:mailto:dev2@mycompany.com END:VEVENT END:VCALENDAR
144.1. Options
The iCal dataformat supports 2 options which are listed below.
| Name | Default | Java Type | Description |
|---|---|---|---|
| validating |
|
| Whether to validate. |
| contentTypeHeader |
|
| Whether the data format should set the Content-Type header with the type from the data format if the data format is capable of doing so. For example application/xml for data formats marshalling to XML, or application/json for data formats marshalling to JSon etc. |
144.2. Basic Usage
To unmarshal and marshal the message shown above, your route will look like the following:
from("direct:ical-unmarshal")
.unmarshal("ical")
.to("mock:unmarshaled")
.marshal("ical")
.to("mock:marshaled");
Maven users will need to add the following dependency to their pom.xml for this component:
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-ical</artifactId>
<version>x.x.x</version>
<!-- use the same version as your Camel core version -->
</dependency>144.3. See Also
- Configuring Camel
- Component
- Endpoint
- Getting Started

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.