1 #ifndef __OBJECTS_CALENDAROBJECT_CALENDAROBJECT_H__
2 #define __OBJECTS_CALENDAROBJECT_CALENDAROBJECT_H__
12 #include "../../common/text.h"
16 enum CalendarObjectLoadResult {
17 CALENDAROBJECTLOAD_UNITTESTFAIL = -1,
18 CALENDAROBJECTLOAD_OK,
19 CALENDAROBJECTLOAD_MISSING,
20 CALENDAROBJECTLOAD_INVALIDFORMAT,
21 CALENDAROBJECTLOAD_CANNOTOPEN
24 enum CalendarObjectValidResult{
25 CALENDAROBJECTVALID_UNITTESTFAIL = -1,
26 CALENDAROBJECTVALID_OK,
27 CALENDAROBJECTVALID_INVALIDFORMAT
30 enum CalendarAlarmAction{
31 CALENDARALARM_UNSPECIFIED = -1,
33 CALENDARALARM_DISPLAY,
37 struct CalendarAlarmDataStruct{
39 CalendarAlarmAction AlarmType = CALENDARALARM_UNSPECIFIED;
42 string AlarmActionTokens;
46 string TriggerRelated;
49 string DescriptionData;
50 string DescriptionAltRep;
51 string DescriptionLanguage;
52 string DescriptionTokens;
59 string SummaryLanguage;
62 vector<string> AttendeeList;
63 vector<string> AttendeeListMember;
64 vector<string> AttendeeListDelegatedFrom;
65 vector<string> AttendeeListDelegatedTo;
66 vector<string> AttendeeListRole;
67 vector<string> AttendeeListRSVP;
68 vector<string> AttendeeListDirectoryEntry;
69 vector<string> AttendeeListSentBy;
70 vector<string> AttendeeListCommonName;
71 vector<string> AttendeeListCalendarUserType;
72 vector<string> AttendeeListParticipationStatus;
73 vector<string> AttendeeListLanguage;
74 vector<string> AttendeeListTokens;
77 string DurationTokens;
79 vector<string> AttachList;
80 vector<string> AttachListTokens;
81 vector<string> AttachListEncoding;
82 vector<string> AttachListFormatType;
83 vector<string> AttachListValue;
85 vector<string> XTokensData;
86 vector<string> XTokensDataTokens;
93 CalendarObjectLoadResult LoadFile(string LoadFilename);
94 CalendarObjectLoadResult LoadString(string *LoadStringData);
95 CalendarObjectValidResult ValidBaseObject();
96 void ProcessBaseData();
98 // Setup virtual subroutines for use by objects
99 // inheriting from CalendarObject later on.
101 virtual CalendarObjectValidResult ValidObject() { return CALENDAROBJECTVALID_OK; };
102 virtual void Clear() {};
109 string CalendarScaleData;
110 string CalendarScaleTokens;
113 string UniqueIDTokens;
115 vector<string> AttachList;
116 vector<string> AttachListTokens;
117 vector<string> AttachListEncoding;
118 vector<string> AttachListFormatType;
119 vector<string> AttachListValue;
121 vector<string> CategoriesList;
122 vector<string> CategoriesListLanguage;
123 vector<string> CategoriesListTokens;
126 string ClassDataTokens;
128 string CompletedData;
129 string CompletedDataTokens;
131 vector<string> CommentList;
132 vector<string> CommentListAltRep;
133 vector<string> CommentListLanguage;
134 vector<string> CommentListTokens;
136 vector<string> DescriptionList;
137 vector<string> DescriptionListAltRep;
138 vector<string> DescriptionListLanguage;
139 vector<string> DescriptionListTokens;
141 string GeographicData;
142 string GeographicTokens;
145 string LocationDataAltRep;
146 string LocationDataLanguage;
147 string LocationDataTokens;
149 string PercentCompleteData;
150 string PercentCompleteTokens;
152 int PriorityData = -1;
153 string PriorityTokens;
155 vector<string> ResourcesData;
156 vector<string> ResourcesDataAltRep;
157 vector<string> ResourcesDataLanguage;
158 vector<string> ResourcesDataTokens;
161 string StatusLanguage;
165 string SummaryDataAltRep;
166 string SummaryDataLanguage;
167 string SummaryDataTokens;
169 string DateTimeEndData;
170 string DateTimeEndDataValue;
171 string DateTimeEndDataTimeZoneID;
172 string DateTimeEndDataTokens;
176 string DueDataTimeZoneID;
177 string DueDataTokens;
179 string DateTimeStartData;
180 string DateTimeStartDataValue;
181 string DateTimeStartDataTimeZoneID;
182 string DateTimeStartDataTokens;
185 string DurationDataTokens;
187 vector<string> FreeBusyList;
188 vector<string> FreeBusyListType;
189 vector<string> FreeBusyListTokens;
191 string TimeTransparencyData;
192 string TimeTransparencyDataTokens;
195 string TimeZoneDataTokens;
197 vector<string> TimeZoneNameList;
198 vector<string> TimeZoneNameListLanguage;
199 vector<string> TimeZoneNameListTokens;
201 string TimeZoneOffsetFromData;
202 string TimeZoneOffsetFromDataTokens;
204 string TimeZoneOffsetToData;
205 string TimeZoneOffsetToDataTokens;
207 string TimeZoneURLData;
208 string TimeZoneURLTokens;
210 vector<string> AttendeeList;
211 vector<string> AttendeeListMember;
212 vector<string> AttendeeListDelegatedFrom;
213 vector<string> AttendeeListDelegatedTo;
214 vector<string> AttendeeListRole;
215 vector<string> AttendeeListRSVP;
216 vector<string> AttendeeListDirectoryEntry;
217 vector<string> AttendeeListSentBy;
218 vector<string> AttendeeListCommonName;
219 vector<string> AttendeeListCalendarUserType;
220 vector<string> AttendeeListParticipationStatus;
221 vector<string> AttendeeListLanguage;
222 vector<string> AttendeeListTokens;
224 vector<string> ContactList;
225 vector<string> ContactListAltRep;
226 vector<string> ContactListLanguage;
227 vector<string> ContactListTokens;
229 string OrganiserData;
230 string OrganiserDataCommonName;
231 string OrganiserDataDirectoryEntry;
232 string OrganiserDataSentByParam;
233 string OrganiserDataLanguage;
234 string OrganiserDataTokens;
236 string RecurranceIDData;
237 string RecurranceIDDataTimeZoneParam;
238 string RecurranceIDDataRangeParam;
239 string RecurranceIDDataValue;
240 string RecurranceIDDataTokens;
242 vector<string> RelatedToData;
243 vector<string> RelatedToDataRelationType;
244 vector<string> RelatedToDataTokens;
247 string URLDataTokens;
249 vector<string> ExcludeDateData;
250 vector<string> ExcludeDateDataValue;
251 vector<string> ExcludeDateDataTimeZoneParam;
252 vector<string> ExcludeDateDataTokens;
254 vector<string> RecurranceDateData;
255 vector<string> RecurranceDateDataValue;
256 vector<string> RecurranceDateDataTimeZoneParam;
257 vector<string> RecurranceDateDataTokens;
259 string RecurranceRuleData;
260 string RecurranceRuleDataTokens;
262 string TriggerDataList;
263 string TriggerDataValue;
264 string TriggerDataRelatedParam;
265 string TriggerDataTokens;
267 string DateTimeCreatedData;
268 string DateTimeCreatedTokens;
270 string DateTimeStampData;
271 string DateTimeStampTokens;
273 string LastModifiedData;
274 string LastModifiedTokens;
276 int SequenceData = -1;
277 string SequenceTokens;
279 vector<string> XTokensData;
280 vector<string> XTokensDataTokens;
282 vector<string> RequestStatusData;
283 vector<string> RequestStatusLanguage;
284 vector<string> RequestStatusTokens;
286 vector<CalendarAlarmDataStruct> CalendarAlarmData;
289 // Initial Loading Data.
290 vector<string> ObjectName;
291 vector<string> ObjectData;
293 vector<vector<string>> EventAlarmName;
294 vector<vector<string>> EventAlarmData;
297 virtual void ProcessData() {};