Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Removed std:: as now using namespace std in CalendarObject.h
[xestiacalendar/.git] / source / objects / calendartimezone / CalendarTimezone.cpp
index cf25c18..893e8d0 100644 (file)
@@ -46,7 +46,7 @@ CalendarObjectValidResult CalendarTimezoneObject::ValidObject(){
                iter != ObjectName.end(); iter++){
                        
                try{
-                       PropertyName = ObjectName[SeekCount].substr(0,7);
+                       PropertyName = ObjectName[SeekCount].substr(0,4);
                }
                        
                catch(const out_of_range& oor){
@@ -107,6 +107,49 @@ CalendarObjectValidResult CalendarTimezoneObject::ValidObject(){
 
 void CalendarTimezoneObject::ProcessData(){
 
+       // Process the data.
        
+       multimap<string,string> DataReceived;
+       map<string,string> PropertyData;
+       string *PropertyNameData = nullptr;
+       int ObjectSeekCount = 0;
+       
+       // Get the Date Time Stamp (DTSTAMP).
+       
+       DataReceived = ProcessTextVectors(&ObjectName, &ObjectData, false, "TZID");
+       
+       // Process the data from DTSTAMP.
+       
+       if (DataReceived.begin() != DataReceived.end()){
+       
+               try {
+                       TimeZoneDataTokens = DataReceived.begin()->first.substr(5);
+               }
+               
+               catch(const out_of_range &oor){
+                       // Do nothing as there is no data.
+               }               
+               
+               TimeZoneData = DataReceived.begin()->second;
+               
+       }
+       
+       // Process the data from LAST-MODIFIED.
+       
+       DataReceived = ProcessTextVectors(&ObjectName, &ObjectData, false, "LAST-MODIFIED");
+       
+       if (DataReceived.begin() != DataReceived.end()){
+       
+               try {
+                       LastModifiedTokens = DataReceived.begin()->first.substr(14);
+               }
+               
+               catch(const out_of_range &oor){
+                       // Do nothing as there is no data.
+               }               
+               
+               LastModifiedData = DataReceived.begin()->second;
+               
+       }
        
 }
\ No newline at end of file
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy