Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Added ProcessBaseData subroutine for processing METHOD.
authorSteve Brokenshire <sbrokenshire@xestia.co.uk>
Sat, 23 Jan 2016 14:25:26 +0000 (14:25 +0000)
committerSteve Brokenshire <sbrokenshire@xestia.co.uk>
Sat, 23 Jan 2016 14:25:26 +0000 (14:25 +0000)
source/objects/calendarobject/CalendarObject.cpp
source/objects/calendarobject/CalendarObject.h

index 01d939d..0925b45 100644 (file)
@@ -155,6 +155,7 @@ CalendarObjectLoadResult CalendarObject::LoadString(std::string *LoadStringData)
                
        }
        
+       ProcessBaseData();
        ProcessData();
        
        return StringProcResult;
@@ -255,4 +256,30 @@ CalendarObjectValidResult CalendarObject::ValidBaseObject(){
                
        }
        
+}
+
+void CalendarObject::ProcessBaseData(){
+       
+       // Process the base object data.
+       
+       multimap<string,string> DataReceived;
+       
+       // Get the method (METHOD).
+       
+       DataReceived = ProcessTextVectors(&ObjectName, &ObjectData, false, "METHOD");
+       
+       if (DataReceived.begin() != DataReceived.end()){
+               
+               try {
+                       MethodTokens = DataReceived.begin()->first.substr(7);
+               }
+               
+               catch(const out_of_range &oor){
+                       // Do nothing as there is no data.
+               }               
+               
+               MethodData = DataReceived.begin()->second;
+               
+       }
+       
 }
\ No newline at end of file
index 7404216..6d5b1ac 100644 (file)
@@ -30,6 +30,7 @@ class CalendarObject{
        CalendarObjectLoadResult LoadFile(std::string LoadFilename);
        CalendarObjectLoadResult LoadString(std::string *LoadStringData);
        CalendarObjectValidResult ValidBaseObject();
+       void ProcessBaseData();
        
        // Setup virtual subroutines for use by objects
        // inheriting from CalendarObject later on.
@@ -39,6 +40,9 @@ class CalendarObject{
        
        // Object data.
        
+       std::string MethodData;
+       std::string MethodTokens;
+       
        std::string UniqueID;
        std::string UniqueIDTokens;
        
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