Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: DAViCal: General

Retrieving recurring appointment instances through CalDAV library

 

 

DAViCal general RSS feed   Index | Next | Previous | View Threaded


ben at dalby

Mar 23, 2012, 3:42 AM

Post #1 of 2 (367 views)
Permalink
Retrieving recurring appointment instances through CalDAV library

Hello there,

I have a calendar with a recurring appointment, which is sometimes cancelled, and I want to be able to retrieve appointment instances through a CalDAV library.

Let's say the appointment is every week day, but in a certain week, Thursday's instance is cancelled. So we have
MON
TUE
WED
FRI

I'm trying to use the IP*Works .NET library to query DAViCal for just such a calendar, but my problem is that although DAViCal sends back the EXDATE parameter for the cancelled Thursday, it does not return RDATE, EXRULE or RECURRENCE-ID.

Example data returned from DAViCal:
BEGIN:VEVENT
UID:ff47aab4-9178-46e9-bcf5-253d10e61687
DTSTART;TZID="GMT Standard Time":20120126T120000 DTEND;TZID="GMT Standard Time":20120126T123000 TRANSP:OPAQUE
X-OUTLOOK-BUSY-STATUS:2
LAST-MODIFIED:20120321T142655Z
DTSTAMP:20120321T142655Z
CREATED:20120125T140343Z
SUMMARY:Test Recurring Event
CLASS:PUBLIC
RRULE:FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR
LOCATION:Test One Recurring One
SEQUENCE:2
DESCRIPTION:Test One Recurring One Description
EXDATE;TZID="GMT Standard Time":20120202T120000
END:VEVENT

So at the moment it looks like I'd have to manually implement the RRULE property to work out the instance dates myself, using EXDATE as a filter on that list.

So my questions are:
1. Would it be possible/feasible to change DAViCal so that it sends more information back, particularly RDATE?
2. Has anyone used a CalDAV API library in any langugage that can handle this scenario?

I should say that I've already tried DDay.iCal, and it doesn't handled EXDATE correctly. It must be possible, because the eM Client windows app shows the right instances quite happily.

Best wishes,

Ben

B R Dalby Consulting Ltd
Information Systems Consulting for Growing Businesses
http://www.brdalby.co.uk/
Mob: +44(0)778 842 7868
Tel: +44 (0)23 8065 8223
Fax: +44 (0)8700 115 915



------------------------------------------------------------------------------
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here
http://p.sf.net/sfu/sfd2d-msazure
_______________________________________________
Davical-general mailing list
Davical-general [at] lists
https://lists.sourceforge.net/lists/listinfo/davical-general


andrew at morphoss

Mar 25, 2012, 3:39 PM

Post #2 of 2 (341 views)
Permalink
Re: Retrieving recurring appointment instances through CalDAV library [In reply to]

On Fri, 2012-03-23 at 10:42 +0000, Ben Dalby wrote:
> Hello there,
>
> I have a calendar with a recurring appointment, which is sometimes
> cancelled, and I want to be able to retrieve appointment instances
> through a CalDAV library.
>
> Let's say the appointment is every week day, but in a certain week,
> Thursday's instance is cancelled. So we have
> MON
> TUE
> WED
> FRI
>
> I'm trying to use the IP*Works .NET library to query DAViCal for just
> such a calendar, but my problem is that although DAViCal sends back
> the EXDATE parameter for the cancelled Thursday, it does not return
> RDATE, EXRULE or RECURRENCE-ID.
>
> Example data returned from DAViCal:
> BEGIN:VEVENT
> UID:ff47aab4-9178-46e9-bcf5-253d10e61687
> DTSTART;TZID="GMT Standard Time":20120126T120000 DTEND;TZID="GMT Standard Time":20120126T123000 TRANSP:OPAQUE
> X-OUTLOOK-BUSY-STATUS:2
> LAST-MODIFIED:20120321T142655Z
> DTSTAMP:20120321T142655Z
> CREATED:20120125T140343Z
> SUMMARY:Test Recurring Event
> CLASS:PUBLIC
> RRULE:FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR
> LOCATION:Test One Recurring One
> SEQUENCE:2
> DESCRIPTION:Test One Recurring One Description
> EXDATE;TZID="GMT Standard Time":20120202T120000
> END:VEVENT
>
> So at the moment it looks like I'd have to manually implement the
> RRULE property to work out the instance dates myself, using EXDATE as
> a filter on that list.
>
> So my questions are:
> 1. Would it be possible/feasible to change DAViCal so that it sends
> more information back, particularly RDATE?
> 2. Has anyone used a CalDAV API library in any langugage that can
> handle this scenario?
>
> I should say that I've already tried DDay.iCal, and it doesn't handled
> EXDATE correctly. It must be possible, because the eM Client windows
> app shows the right instances quite happily.

Hi Ben,

You can make a REPORT request for a period of time and receive the
events with the RRULE/EXDATE/RDATE expanded server-side. Not sure if
that's helpful to you.

You claim that "although DAViCal sends back the EXDATE parameter for the
cancelled Thursday, it does not return RDATE, EXRULE or RECURRENCE-ID"
but normally DAViCal sends back exactly what data it has been given.

Note that "EXRULE" is not supported by DAViCal in the server-side
expansion of repeat rules - this is deprecated by RFC5545 and very
little (if any) software supports it.

RECURRENCE-ID only applies to instances which have been overridden, so
most events don't contain a RECURRENCE-ID at all, especially if the
override is simply a cancellation as that is handled by adding a date
into the EXDATE property - as in the example you sent.

I suspect that the "expand" property of the calendar-query report,
defined in section 7.8 of RFC4791 is what you are after, though that
will return you all instances of all events in a range, rather than the
single event. But maybe that's also what you're after... :-)

Cheers,
Andrew.

--
------------------------------------------------------------------------
andrew (AT) morphoss (DOT) com +64(272)DEBIAN
I just asked myself... what would John DeLorean do?
-- Raoul Duke

------------------------------------------------------------------------
Attachments: signature.asc (0.82 KB)

DAViCal general RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.