Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Added code to process the ATTENDEE property in CalendarJournalObject.
authorSteve Brokenshire <sbrokenshire@xestia.co.uk>
Sun, 31 Jan 2016 15:08:28 +0000 (15:08 +0000)
committerSteve Brokenshire <sbrokenshire@xestia.co.uk>
Sun, 31 Jan 2016 15:08:28 +0000 (15:08 +0000)
source/objects/calendarjournal/CalendarJournal.cpp

index f174df3..6f87e50 100644 (file)
@@ -601,4 +601,108 @@ void CalendarJournalObject::ProcessData(){
                
        }
        
+       // Process the data from ATTENDEE.
+       
+       DataReceived = ProcessTextVectors(&ObjectName, &ObjectData, true, "ATTENDEE");
+       
+       ObjectSeekCount = 0;
+       
+       for(multimap<string,string>::iterator iter = DataReceived.begin(); 
+               iter != DataReceived.end(); 
+               ++iter){
+                       
+               AttendeeListMember.push_back("");
+               AttendeeListDelegatedFrom.push_back("");
+               AttendeeListDelegatedTo.push_back("");
+               AttendeeListRole.push_back("");
+               AttendeeListRSVP.push_back("");
+               AttendeeListDirectoryEntry.push_back("");
+               AttendeeListSentBy.push_back("");
+               AttendeeListCommonName.push_back("");
+               AttendeeListCalendarUserType.push_back("");
+               AttendeeListParticipationStatus.push_back("");
+               AttendeeListLanguage.push_back("");
+               AttendeeListTokens.push_back("");
+               AttendeeList.push_back("");
+                       
+               bool TokenData = false;
+               string PropertyTokens;
+               
+               PropertyNameData = (string*)&iter->first;
+               
+               PropertyData = SplitValues(*PropertyNameData);
+                       
+               for(map<string,string>::iterator dataiter = PropertyData.begin();
+                       dataiter != PropertyData.end(); dataiter++){
+                       
+                       if (dataiter->first == "CUTYPE"){
+                               
+                               AttendeeListCalendarUserType[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "MEMBER"){
+                               
+                               AttendeeListMember[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "ROLE"){
+                               
+                               AttendeeListRole[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "PARTSTAT"){
+                               
+                               AttendeeListParticipationStatus[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "RSVP"){
+                               
+                               AttendeeListRSVP[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "DELEGATED-TO"){
+                               
+                               AttendeeListDelegatedTo[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "DELEGATED-FROM"){
+                               
+                               AttendeeListDelegatedFrom[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "SENT-BY"){
+                               
+                               AttendeeListSentBy[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "CN"){
+                               
+                               AttendeeListCommonName[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "DIR"){
+                               
+                               AttendeeListDirectoryEntry[ObjectSeekCount] = dataiter->second;
+                               
+                       } else if (dataiter->first == "LANGUAGE"){
+                               
+                               AttendeeListLanguage[ObjectSeekCount] = dataiter->second;
+                               
+                       } else {
+                               
+                               if (TokenData == false){
+                                       TokenData = true;
+                               } else {
+                                       PropertyTokens += ";";
+                               }
+                               
+                               PropertyTokens += dataiter->first;
+                               PropertyTokens += "=";
+                               PropertyTokens += dataiter->second;
+                               
+                       }
+                               
+               }
+               
+               if (PropertyTokens.size() > 0){
+                       AttendeeListTokens[ObjectSeekCount] = PropertyTokens;
+               }
+                       
+               AttendeeList[ObjectSeekCount] = iter->second;
+               
+               ObjectSeekCount++;
+               
+       }
+       
 }
\ 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