00001 00018 #ifndef __RECURRENCE_H__ 00019 #define __RECURRENCE_H__ 00020 00021 /* Headers */ 00022 #include<vector> 00023 #include <string> 00024 using std::string; 00025 using std::vector; 00026 00027 #include "CalendarLog.h" 00028 #include "CRecurrenceRule.h" 00029 00035 class CRecurrence { 00036 00037 public: 00038 00046 bool setRecurrenceRule(vector < CRecurrenceRule * >VRRuleList); 00047 00055 vector < CRecurrenceRule * >getRecurrenceRule(); 00056 00065 vector < string > getErule(); 00066 00076 vector < string > getRrule(); 00077 00082 CRecurrence(CRecurrence & ref); 00083 00092 bool setRrule(vector < string > vRRuleList); 00093 00103 bool setErule(vector < string > vERuleList); 00104 00114 bool setRDays(vector < string > vRecRuleList); 00115 00125 vector < string > getRDays(); 00126 00135 bool setEDays(vector < string > vExceptionDateList); 00136 00146 vector < string > getEDays(); 00147 00156 bool setRecurId(int iRId); 00157 00166 int getRecurId(); 00179 bool setRtype(int iRType); 00192 int getRtype(); 00193 00202 CRecurrence(vector < string > vRRuleList, int iRId); 00212 vector < time_t > generateInstanceTimes(time_t iViewBegin, time_t iViewEnd,time_t iDateStart,int eventSpan); 00213 00220 CRecurrence(); 00221 00222 /* overloaded assigment operator 00223 */ 00224 CRecurrence & operator=(const CRecurrence & right); 00225 00232 ~CRecurrence(); 00233 00234 private: 00235 00236 vector < CRecurrenceRule * >vRecrRuleList; 00238 vector < string > vExceptionDateList; 00240 vector < string > vRecRuleList; 00242 int iRType; 00244 int iRecurId; 00247 }; 00248 00249 #endif