Diffstat (limited to 'libopie2/opiepim/core/orecur.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libopie2/opiepim/core/orecur.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libopie2/opiepim/core/orecur.h b/libopie2/opiepim/core/orecur.h index 7750c12..d7ecd90 100644 --- a/libopie2/opiepim/core/orecur.h +++ b/libopie2/opiepim/core/orecur.h | |||
@@ -1,37 +1,42 @@ | |||
1 | /* | 1 | /* |
2 | * GPL from TT | 2 | * GPL from TT |
3 | */ | 3 | */ |
4 | 4 | ||
5 | #ifndef OPIE_RECUR_H | 5 | #ifndef OPIE_RECUR_H |
6 | #define OPIE_RECUR_H | 6 | #define OPIE_RECUR_H |
7 | 7 | ||
8 | #include <sys/types.h> | 8 | #include <sys/types.h> |
9 | 9 | ||
10 | #include <qdatetime.h> | 10 | #include <qdatetime.h> |
11 | #include <qvaluelist.h> | 11 | #include <qvaluelist.h> |
12 | #include <qmap.h> | 12 | #include <qmap.h> |
13 | 13 | ||
14 | |||
15 | /** | ||
16 | * Class to handle Recurrencies.. | ||
17 | */ | ||
18 | |||
14 | class ORecur { | 19 | class ORecur { |
15 | public: | 20 | public: |
16 | typedef QValueList<QDate> ExceptionList; | 21 | typedef QValueList<QDate> ExceptionList; |
17 | enum RepeatType{ NoRepeat = -1, Daily, Weekly, MonthlyDay, | 22 | enum RepeatType{ NoRepeat = -1, Daily, Weekly, MonthlyDay, |
18 | MonthlyDate, Yearly }; | 23 | MonthlyDate, Yearly }; |
19 | enum Days { MON = 0x01, TUE = 0x02, WED = 0x04, THU = 0x08, | 24 | enum Days { MON = 0x01, TUE = 0x02, WED = 0x04, THU = 0x08, |
20 | FRI = 0x10, SAT = 0x20, SUN = 0x40 }; | 25 | FRI = 0x10, SAT = 0x20, SUN = 0x40 }; |
21 | enum Fields{ RType = 0, RWeekdays, RPosition, RFreq, RHasEndDate, | 26 | enum Fields{ RType = 0, RWeekdays, RPosition, RFreq, RHasEndDate, |
22 | EndDate, Created, Exceptions }; | 27 | EndDate, Created, Exceptions }; |
23 | 28 | ||
24 | ORecur(); | 29 | ORecur(); |
25 | ORecur( const QMap<int, QString>& map ); | 30 | ORecur( const QMap<int, QString>& map ); |
26 | ORecur( const ORecur& ); | 31 | ORecur( const ORecur& ); |
27 | ~ORecur(); | 32 | ~ORecur(); |
28 | 33 | ||
29 | ORecur &operator=( const ORecur& ); | 34 | ORecur &operator=( const ORecur& ); |
30 | bool operator==(const ORecur& )const; | 35 | bool operator==(const ORecur& )const; |
31 | 36 | ||
32 | bool doesRecur()const; | 37 | bool doesRecur()const; |
33 | /* if it recurrs on that day */ | 38 | /* if it recurrs on that day */ |
34 | bool doesRecur( const QDate& ); | 39 | bool doesRecur( const QDate& ); |
35 | RepeatType type()const; | 40 | RepeatType type()const; |
36 | int frequency()const; | 41 | int frequency()const; |
37 | int position()const; | 42 | int position()const; |