From b41fb4a9705ea905f291dcca387272bece95f3b0 Mon Sep 17 00:00:00 2001 From: Steve Brokenshire Date: Sun, 31 Jan 2016 11:53:27 +0000 Subject: [PATCH] Added code to process ORGANIZER in CalendarTaskObject. --- source/objects/calendartask/CalendarTask.cpp | 58 ++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/source/objects/calendartask/CalendarTask.cpp b/source/objects/calendartask/CalendarTask.cpp index 5858ac6..d3ad6dd 100644 --- a/source/objects/calendartask/CalendarTask.cpp +++ b/source/objects/calendartask/CalendarTask.cpp @@ -427,4 +427,62 @@ void CalendarTaskObject::ProcessData(){ } + // Process the data from ORGANIZER. + + DataReceived = ProcessTextVectors(&ObjectName, &ObjectData, false, "ORGANIZER"); + + if (DataReceived.begin() != DataReceived.end()){ + + bool TokenData = false; + string PropertyTokens; + + PropertyNameData = (string*)&DataReceived.begin()->first; + + PropertyData = SplitValues(*PropertyNameData); + + for(map::iterator iter = PropertyData.begin(); + iter != PropertyData.end(); iter++){ + + if (iter->first == "CN"){ + + OrganiserDataCommonName = iter->second; + + } else if (iter->first == "DIR"){ + + OrganiserDataDirectoryEntry = iter->second; + + } else if (iter->first == "SENT-BY"){ + + OrganiserDataSentByParam = iter->second; + + } else if (iter->first == "LANGUAGE"){ + + OrganiserDataLanguage = iter->second; + + } else { + + if (TokenData == false){ + TokenData = true; + } else { + PropertyTokens += ";"; + } + + PropertyTokens += iter->first; + PropertyTokens += "="; + PropertyTokens += iter->second; + + } + + } + + if (PropertyTokens.size() > 0){ + + OrganiserDataTokens = PropertyTokens; + + } + + OrganiserData = DataReceived.begin()->second; + + } + } \ No newline at end of file -- 2.39.5