REPORT Method
The REPORT method allows for flexible querying of CalDAV collections. The full range of its power is beyond the scope of this document, so just one of the most common use cases will be demonstrated - querying a collection for VEVENTS within a given time-range.
There are several different types of REPORT requests, but the most common one and the only one supported right now in CalDAV4j is the <calendar-query>. The <calendar-query> we would like to create looks like this:
<?xml version="1.0"?>
<C:calendar-query xmlns:C="urn:ietf:params:xml:ns:caldav">
<D:prop xmlns:D="DAV:">
<C:calendar-data/>
</D:prop>
<C:filter>
<C:comp-filter name="VCALENDAR">
<C:comp-filter name="VEVENT">
<C:time-range start="20060101T000000Z" end="20060107T000000Z"/>
</C:comp-filter>
</C:comp-filter>
</C:filter>
</C:calendar-query>
Basically, what this query is saying is "give me all the calendar data for VEVENT's in VCALENDAR's which occur between 1/1/2006 and 1/7/2006 exclusive"