X-Git-Url: http://Server1/repobrowser/?a=blobdiff_plain;f=source%2Fobjects%2Fcalendarevent%2FCalendarEvent-Save.cpp;h=a5afcd5d27c82a032ea50882335f6e0e7044fd3c;hb=3b462406bd52d9c05c86d2099ec9ffaaa7f2de95;hp=1d1edcc770a9dc50b1a948f30cc7633bcdd50499;hpb=d6db59a2eeae6311abbb40783aae2221661b664c;p=xestiacalendar%2F.git diff --git a/source/objects/calendarevent/CalendarEvent-Save.cpp b/source/objects/calendarevent/CalendarEvent-Save.cpp index 1d1edcc..a5afcd5 100644 --- a/source/objects/calendarevent/CalendarEvent-Save.cpp +++ b/source/objects/calendarevent/CalendarEvent-Save.cpp @@ -186,7 +186,7 @@ void CalendarEventObject::SaveObjectData(string *SaveData){ } - // Process the CLASS. + // Process the CLASS value. if (ClassData.size() > 0){ @@ -214,6 +214,132 @@ void CalendarEventObject::SaveObjectData(string *SaveData){ } + // Process the CREATED value. + + if (DateTimeCreatedData.size() > 0){ + + if (DateTimeCreatedTokens.size() > 0){ + + DataLine += "CREATED;"; + DataLine += DateTimeCreatedTokens; + + } else { + + DataLine += "CREATED"; + + } + + DataLine += ":"; + DataLine += DateTimeCreatedData; + DataLine += "\n"; + + DataLineProcessed = OutputText(&DataLine); + + *SaveData += DataLineProcessed; + + DataLine.clear(); + DataLineProcessed.clear(); + + } + + // Process the DESCRIPTION values. Write out the + // first DESCRPITION only as per RFC5545 specifcation. + + if (DescriptionList.size() > 0){ + + DataLine += "DESCRIPTION"; + + if (DescriptionListAltRep[0].size() > 0){ + + DataLine += ";ALTREP=\""; + DataLine += DescriptionListAltRep[0]; + DataLine += "\""; + + } + + if (DescriptionListLanguage[0].size() > 0){ + + DataLine += ";LANGUAGE="; + DataLine += DescriptionListLanguage[0]; + + } + + if (DescriptionListTokens[0].size() > 0){ + + DataLine += ";"; + DataLine += DescriptionListTokens[0]; + + } + + DataLine += ":"; + DataLine += DescriptionList[0]; + DataLine += "\n"; + + DataLineProcessed = OutputText(&DataLine); + + *SaveData += DataLineProcessed; + + DataLine.clear(); + DataLineProcessed.clear(); + + } + + // Process the GEO value. + + if (GeographicData.size() > 0){ + + if (GeographicTokens.size() > 0){ + + DataLine += "GEO;"; + DataLine += GeographicTokens; + + } else { + + DataLine += "GEO"; + + } + + DataLine += ":"; + DataLine += GeographicData; + DataLine += "\n"; + + DataLineProcessed = OutputText(&DataLine); + + *SaveData += DataLineProcessed; + + DataLine.clear(); + DataLineProcessed.clear(); + + } + + // Process the LAST-MODIFIED value. + + if (LastModifiedData.size() > 0){ + + if (LastModifiedTokens.size() > 0){ + + DataLine += "LAST-MODIFIED;"; + DataLine += LastModifiedTokens; + + } else { + + DataLine += "LAST-MODIFIED"; + + } + + DataLine += ":"; + DataLine += LastModifiedData; + DataLine += "\n"; + + DataLineProcessed = OutputText(&DataLine); + + *SaveData += DataLineProcessed; + + DataLine.clear(); + DataLineProcessed.clear(); + + } + *SaveData += "END:VEVENT\n"; } \ No newline at end of file