]> err.no Git - sope/blob - sope-ical/NGiCal/iCalRepeatableEntityObject.h
minor bugfix
[sope] / sope-ical / NGiCal / iCalRepeatableEntityObject.h
1 /*
2   Copyright (C) 2004-2005 SKYRIX Software AG
3
4   This file is part of SOPE.
5
6   SOPE is free software; you can redistribute it and/or modify it under
7   the terms of the GNU Lesser General Public License as published by the
8   Free Software Foundation; either version 2, or (at your option) any
9   later version.
10
11   SOPE is distributed in the hope that it will be useful, but WITHOUT ANY
12   WARRANTY; without even the implied warranty of MERCHANTABILITY or
13   FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
14   License for more details.
15
16   You should have received a copy of the GNU Lesser General Public
17   License along with SOPE; see the file COPYING.  If not, write to the
18   Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
19   02111-1307, USA.
20 */
21
22 #ifndef __NGiCal_iCalRepeatableEntityObject_H_
23 #define __NGiCal_iCalRepeatableEntityObject_H_
24
25 #include <NGiCal/iCalEntityObject.h>
26
27 /*
28  iCalRepeatableEntityObject
29
30  Specifies an iCal entity object which can bear a (possibly complex) set
31  of recurrence rules and exceptions thereof. According to RFC 2445 these
32  are VEVENT, VTODO and VJOURNAL.
33 */
34
35 @class NSMutableArray, NGCalendarDateRange;
36
37 @interface iCalRepeatableEntityObject : iCalEntityObject
38 {
39   NSMutableArray *rRules;
40   NSMutableArray *exRules;
41   NSMutableArray *exDates;
42 }
43
44 - (void)removeAllRecurrenceRules;
45 - (void)addToRecurrenceRules:(id)_rrule;
46 - (BOOL)hasRecurrenceRules;
47 - (NSArray *)recurrenceRules;
48
49 - (void)removeAllExceptionRules;
50 - (void)addToExceptionRules:(id)_rrule;
51 - (BOOL)hasExceptionRules;
52 - (NSArray *)exceptionRules;
53
54 - (void)removeAllExceptionDates;
55 - (void)addToExceptionDates:(id)_date;
56 - (BOOL)hasExceptionDates;
57 - (NSArray *)exceptionDates;
58
59 - (BOOL)isRecurrent;
60 - (BOOL)isWithinCalendarDateRange:(NGCalendarDateRange *)_range
61   firstInstanceCalendarDateRange:(NGCalendarDateRange *)_fir;
62 - (NSArray *)recurrenceRangesWithinCalendarDateRange:(NGCalendarDateRange *)_r
63   firstInstanceCalendarDateRange:(NGCalendarDateRange *)_fir;
64
65 /* this is the outmost bound possible, not necessarily the real last date */
66 - (NSCalendarDate *)lastPossibleRecurrenceStartDateUsingFirstInstanceCalendarDateRange:(NGCalendarDateRange *)_r;
67
68 @end
69
70 #endif  /* __NGiCal_iCalRepeatableEntityObject_H_ */