#include <CRecurrenceRule.h>
Public Member Functions | |
CRecurrenceRule (CRecurrenceRule &ref) | |
CRecurrenceRule & | operator= (CRecurrenceRule &right) |
CRecurrenceRule () | |
~CRecurrenceRule () | |
bool | setRuleType (RuleType iType) |
RuleType | getRuleType () |
bool | rruleParser (string szRule) |
bool | setRrule (string szRRule) |
string | getRrule () |
bool | setFrequency (FREQUENCY iValue) |
FREQUENCY | getFrequency () |
bool | setUntil (time_t iUntil) |
time_t | getUntil () |
bool | setCount (int iCount) |
int | getCount () |
bool | setSecond (vector< short > vSec) |
vector< short > | getSecond () |
bool | setMinute (vector< short > vMinute) |
vector< short > | getMinute () |
bool | setHour (vector< short > vHour) |
vector< short > | getHour () |
bool | setWeekDay (vector< short > vByWeekDay) |
vector< short > | getWeekDay () |
bool | setMonthDay (vector< short > vByMonthDay) |
vector< short > | getMonthDay () |
bool | setYearDay (vector< short > vByYearDay) |
vector< short > | getYearDay () |
bool | setWeekNumber (vector< short > vByWeekNumber) |
vector< short > | getWeekNumber () |
bool | setMonth (vector< short > vMonth) |
vector< short > | getMonth () |
bool | setPos (vector< short > vPosition) |
vector< short > | getPos () |
bool | setWeekStart (icalrecurrencetype_weekday start) |
icalrecurrencetype_weekday | getWeekStart () |
bool | setInterval (short interval) |
short | getInterval () |
string | toString () |
CRecurrenceRule (int iType, string szRRule) | |
bool | checkRuleIsComplex () |
Private Member Functions | |
vector< short > | convertArrayToVector (short array[], int iLengthMax) |
Private Attributes | |
FREQUENCY | iFreq |
string | szRule |
int | iCount |
short | interval |
time_t | iUntil |
RuleType | iType |
icalrecurrencetype_weekday | weekStart |
vector< short > | vBySecond |
vector< short > | vByMinute |
vector< short > | vByHour |
vector< short > | vByWeekDay |
vector< short > | vByMonthDay |
vector< short > | vByYearDay |
vector< short > | vByWeekNumber |
vector< short > | vByMonth |
vector< short > | vBySetPos |
CRecurrenceRule class
CRecurrenceRule::CRecurrenceRule | ( | CRecurrenceRule & | ref | ) |
Copy Constructor
References iCount, iFreq, interval, iType, iUntil, szRule, vByHour, vByMinute, vByMonth, vByMonthDay, vBySecond, vBySetPos, vByWeekDay, vByWeekNumber, vByYearDay, and weekStart.
CRecurrenceRule::CRecurrenceRule | ( | ) |
Default constructor
References iCount, iFreq, interval, iType, iUntil, vByHour, vByMinute, vByMonth, vByMonthDay, vBySecond, vBySetPos, vByWeekDay, vByWeekNumber, vByYearDay, and weekStart.
CRecurrenceRule::~CRecurrenceRule | ( | ) |
Destructor of the class
CRecurrenceRule::CRecurrenceRule | ( | int | iType, | |
string | szRRule | |||
) |
overloaded Constructor type 0-rrule ,1 -exrule
References iCount, iFreq, interval, iUntil, szRule, vByHour, vByMinute, vByMonth, vByMonthDay, vBySecond, vBySetPos, vByWeekDay, vByWeekNumber, vByYearDay, and weekStart.
CRecurrenceRule & CRecurrenceRule::operator= | ( | CRecurrenceRule & | right | ) |
overloaded assignment operator
References iCount, iFreq, interval, iType, iUntil, szRule, vByHour, vByMinute, vByMonth, vByMonthDay, vBySecond, vBySetPos, vByWeekDay, vByWeekNumber, vByYearDay, and weekStart.
bool CRecurrenceRule::setRuleType | ( | RuleType | iType | ) |
setRuleType
RuleType | type of recurrence rule 0 - RecurrenceRule ;1 -Exception Rule |
setRuleType
int | type of recurrence rule 0 - RecurrenceRule ;1 -Exception Rule |
Referenced by ICalConverter::getRecurrence().
RuleType CRecurrenceRule::getRuleType | ( | ) |
getRuleType
NONE |
getRuleType
NONE |
References iType.
Referenced by ICalConverter::localToIcalVcal().
bool CRecurrenceRule::rruleParser | ( | string | szRule | ) |
string | szRule recurrence rule, can be recurrence rule or exception rule |
string | : recurrence rule, can be recurrence rule or exception rule |
currently libical is used later this dependency has to be removed and Funambol API should be used
References convertArrayToVector(), iCount, iFreq, interval, vByHour, vByMinute, vByMonth, vByMonthDay, vBySecond, vBySetPos, vByWeekDay, vByWeekNumber, and vByYearDay.
Referenced by ICalConverter::importEventRecurrence().
bool CRecurrenceRule::setRrule | ( | string | szRRule | ) |
: | string szRRule - recurrence rule / exception rule |
setRrule
: | string rrule - recurrence rule / exception rule |
References szRule.
Referenced by ICalConverter::getRecurrenceRule().
string CRecurrenceRule::getRrule | ( | ) |
: | NONE |
: | NONE |
References szRule.
Referenced by ICalConverter::localToIcalVcal(), and toString().
bool CRecurrenceRule::setFrequency | ( | FREQUENCY | iValue | ) |
FREQUENCY | : ivaluea frequebncy can be daily,monthly etc, valid values defined in FREQUENCY enumeration. |
setFrequency
FREQUENCY | : ivalue |
References iFreq.
FREQUENCY CRecurrenceRule::getFrequency | ( | ) |
NONE |
getFREQUENCY
NONE |
References iFreq.
Referenced by toString().
bool CRecurrenceRule::setUntil | ( | time_t | iUntil | ) |
time_t | : until value in rrule as time_t |
time_t | : until value in rrule as time_t |
time_t CRecurrenceRule::getUntil | ( | ) |
: | NONE |
: | NONE |
References iUntil.
bool CRecurrenceRule::setCount | ( | int | iCount | ) |
: | integer Count of occurances |
setCount
: | integer Count of occurances |
int CRecurrenceRule::getCount | ( | ) |
: | NONE |
getCount
: | NONE |
References iCount.
bool CRecurrenceRule::setSecond | ( | vector< short > | vSec | ) |
vector<short>,: | seconds list on which the events should occur |
setSecond
vector<short>,: | seconds list on which the events should occur |
References vBySecond.
vector< short > CRecurrenceRule::getSecond | ( | ) |
NONE |
getSecond
NONE |
References vBySecond.
bool CRecurrenceRule::setMinute | ( | vector< short > | vMinute | ) |
vector<short>,: | Minute list on which the events should occur |
setMinute
vector<short>,: | Minute list on which the events should occur |
References vByMinute.
vector< short > CRecurrenceRule::getMinute | ( | ) |
NONE | Function used to get Minutes in CRecurrenceRule class |
NONE | Function used to get Minutes in CRecurrenceRule class |
References vByMinute.
bool CRecurrenceRule::setHour | ( | vector< short > | vHour | ) |
vector<short>,: | Hour list on which the events should occur |
setHour
vector<short>,: | Hour list on which the events should occur |
References vByHour.
vector< short > CRecurrenceRule::getHour | ( | ) |
NONE |
getHour
NONE |
References vByHour.
bool CRecurrenceRule::setWeekDay | ( | vector< short > | vByWeekDay | ) |
vector<short>,: | WeekDay list on which the events should occur |
setWeekDay
vector<short>,: | WeekDay list on which the events should occur |
vector< short > CRecurrenceRule::getWeekDay | ( | ) |
NONE |
getWeekDay
NONE |
References vByWeekDay.
bool CRecurrenceRule::setMonthDay | ( | vector< short > | vMonthDays | ) |
vector<short>,: | MonthDay list on which the events should occur |
setMonthDay
vector<short> | : month days 0-31 |
References vByMonthDay.
vector< short > CRecurrenceRule::getMonthDay | ( | ) |
NONE |
getMonthDay
NONE |
References vByMonthDay.
bool CRecurrenceRule::setYearDay | ( | vector< short > | vByYearDay | ) |
vector<short>,: | YearDay list on which the events should occur |
setYearDay
vector<short>,: | YearDay list on which the events should occur |
vector< short > CRecurrenceRule::getYearDay | ( | ) |
NONE |
getYearDay
NONE |
References vByYearDay.
bool CRecurrenceRule::setWeekNumber | ( | vector< short > | vByWeekNumber | ) |
vector<short>,: | WeekNumeber list on which the events should occur |
setWeekNumber
vector<short>,: | WeekNumeber list on which the events should occur |
vector< short > CRecurrenceRule::getWeekNumber | ( | ) |
NONE |
getWeekNumber
NONE |
References vByWeekNumber.
bool CRecurrenceRule::setMonth | ( | vector< short > | vMonth | ) |
vector<short>,: | Month list on which the events should occur |
setMonth
vector<short>,: | Month list on which the events should occur |
References vByMonth.
vector< short > CRecurrenceRule::getMonth | ( | ) |
NONE |
getMonth
NONE |
References vByMonth.
bool CRecurrenceRule::setPos | ( | vector< short > | vPosition | ) |
vector<short>,: | Position list on which the events should occur |
setPos
vector<short>,: | Position list on which the events should occur |
References vBySetPos.
vector< short > CRecurrenceRule::getPos | ( | ) |
NONE |
getPos
NONE |
References vBySetPos.
bool CRecurrenceRule::setWeekStart | ( | icalrecurrencetype_weekday | start | ) |
int | : weekstart offset day from which week starts in Calendar in our calendar it is either SUNDAY or MONDAY |
setPos
int | : weekstart offset day from which week starts in Calendar in our calendar it is either SUNDAY or MONDAY |
References weekStart.
icalrecurrencetype_weekday CRecurrenceRule::getWeekStart | ( | ) |
@ int : weekstart offset day from which week starts in Calendar in our calendar it is either SUNDAY or MONDAY
getPos
int | : weekstart offset day from which week starts in Calendar in our calendar it is either SUNDAY or MONDAY |
References weekStart.
Referenced by toString().
bool CRecurrenceRule::setInterval | ( | short | interval | ) |
short | : interval between two instances |
short | : interval between two instances |
short CRecurrenceRule::getInterval | ( | ) |
NONE |
getInterval
NONE |
References interval.
string CRecurrenceRule::toString | ( | ) |
toString
References getFrequency(), getRrule(), getWeekStart(), iCount, interval, iUntil, vByHour, vByMinute, vByMonthDay, vBySecond, vBySetPos, vByWeekDay, vByWeekNumber, and vByYearDay.
bool CRecurrenceRule::checkRuleIsComplex | ( | ) |
Function used for checking whether rule is complex
References vByMonth, vByMonthDay, vBySetPos, vByWeekDay, vByWeekNumber, and vByYearDay.
Referenced by ICalConverter::importEventRecurrence().
vector< short > CRecurrenceRule::convertArrayToVector | ( | short | array[], | |
int | iLengthMax | |||
) | [private] |
array | of short |
array | of short |
After parsing Recurrence rule using ICAL API all arrays are populated with default value of 32639 , to save memory consumption we have filtered out default values
Referenced by rruleParser().
FREQUENCY CRecurrenceRule::iFreq [private] |
Frequency
Referenced by CRecurrenceRule(), getFrequency(), operator=(), rruleParser(), and setFrequency().
string CRecurrenceRule::szRule [private] |
RRule or Exception Rule
Referenced by CRecurrenceRule(), getRrule(), operator=(), and setRrule().
int CRecurrenceRule::iCount [private] |
integer value
Referenced by CRecurrenceRule(), getCount(), operator=(), rruleParser(), and toString().
short CRecurrenceRule::interval [private] |
interval appearing in rrule
Referenced by CRecurrenceRule(), getInterval(), operator=(), rruleParser(), and toString().
time_t CRecurrenceRule::iUntil [private] |
Until value
Referenced by CRecurrenceRule(), getUntil(), operator=(), and toString().
RuleType CRecurrenceRule::iType [private] |
Rule type
Referenced by CRecurrenceRule(), getRuleType(), and operator=().
icalrecurrencetype_weekday CRecurrenceRule::weekStart [private] |
week start as per rfc Ical is week day from which recuurenc has to start. Our Calendar app supports SU or MO for week start.
Referenced by CRecurrenceRule(), getWeekStart(), operator=(), and setWeekStart().
vector< short > CRecurrenceRule::vBySecond [private] |
(0-60) second values
Referenced by CRecurrenceRule(), getSecond(), operator=(), rruleParser(), setSecond(), and toString().
vector< short > CRecurrenceRule::vByMinute [private] |
(0-60) Minute values
Referenced by CRecurrenceRule(), getMinute(), operator=(), rruleParser(), setMinute(), and toString().
vector< short > CRecurrenceRule::vByHour [private] |
(0-24) Hour values
Referenced by CRecurrenceRule(), getHour(), operator=(), rruleParser(), setHour(), and toString().
vector< short > CRecurrenceRule::vByWeekDay [private] |
(SU,MO,TU,WE,TH,FR,ST) WeekDay values
Referenced by checkRuleIsComplex(), CRecurrenceRule(), getWeekDay(), operator=(), rruleParser(), and toString().
vector< short > CRecurrenceRule::vByMonthDay [private] |
(1-31) Month values
Referenced by checkRuleIsComplex(), CRecurrenceRule(), getMonthDay(), operator=(), rruleParser(), setMonthDay(), and toString().
vector< short > CRecurrenceRule::vByYearDay [private] |
(0-365) Year day values
Referenced by checkRuleIsComplex(), CRecurrenceRule(), getYearDay(), operator=(), rruleParser(), and toString().
vector< short > CRecurrenceRule::vByWeekNumber [private] |
(1-52) Week Number values
Referenced by checkRuleIsComplex(), CRecurrenceRule(), getWeekNumber(), operator=(), rruleParser(), and toString().
vector< short > CRecurrenceRule::vByMonth [private] |
(1-12) Month values
Referenced by checkRuleIsComplex(), CRecurrenceRule(), getMonth(), operator=(), rruleParser(), and setMonth().
vector< short > CRecurrenceRule::vBySetPos [private] |
(1-366) SetPosition values
Referenced by checkRuleIsComplex(), CRecurrenceRule(), getPos(), operator=(), rruleParser(), setPos(), and toString().