Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
camelCase: Converted remaining code that was missed
[xestiacalendar/.git] / source / objects / CalDAV / CalDAV-XMLProcessing.cpp
1 // CalDAV-XMLProcessing.cpp - CalDAV Connection Object - XML Processing.
2 //
3 // (c) 2016-2017 Xestia Software Development.
4 //
5 // This file is part of Xestia Calendar.
6 //
7 // Xestia Calendar is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by the
9 // Free Software Foundation, version 3 of the license.
10 //
11 // Xestia Calendar is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License along
17 // with Xestia Calendar. If not, see <http://www.gnu.org/licenses/>
19 #include "CalDAV.h"
21 using namespace std;
22  
23 string CalDAV::ProcessXMLUserPrincipal(){
25         string userPrincipalURI;
26         
27         xmlDocPtr xmlCalDAVDoc;
28         xmlCalDAVDoc = xmlReadMemory(serverData.c_str(), (int)serverData.size(), "noname.xml", NULL, 0);
30         xmlNodePtr nodeSeek;
31         bool nodeFound = false;
32         
33         // Start with the first node, look for multistatus.
34         
35         for (nodeSeek = xmlCalDAVDoc->children;
36                 nodeSeek != NULL;
37                 nodeSeek = nodeSeek->next)
38         {
39         
40                 if (!xmlStrcmp(nodeSeek->name, (const xmlChar *)"multistatus") ||
41                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"d:multistatus") ||
42                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"D:multistatus")
43                 ){
44                         
45                         nodeFound = true;
46                         break;
47                         
48                 }
49                 
50         }
51         
52         if (nodeFound == false){
53         
54                 return userPrincipalURI;
56         }
57         
58         // Look for response.
60         if (nodeFound == false){ return userPrincipalURI; } else { nodeFound = false; }
61         nodeFound = MatchXMLNameTransverse(&nodeSeek, "response");
63         // Look for propstat.
64         
65         if (nodeFound == false){ return userPrincipalURI; } else { nodeFound = false; }
66         nodeFound = MatchXMLNameTransverse(&nodeSeek, "propstat");
68         // Look for prop.
69         
70         if (nodeFound == false){ return userPrincipalURI; } else { nodeFound = false; }
71         nodeFound = MatchXMLNameTransverse(&nodeSeek, "prop");
72         
73         // Look for current-user-principal.
74         
75         if (nodeFound == false){ return userPrincipalURI; } else { nodeFound = false; }
76         nodeFound = MatchXMLNameTransverse(&nodeSeek, "current-user-principal");
77         
78         // Look for href.       
79         
80         if (nodeFound == false){ return userPrincipalURI; } else { nodeFound = false; }
81         nodeFound = MatchXMLNameTransverse(&nodeSeek, "href");
83         // Get the data from href.
84         
85         userPrincipalURI = FetchXMLData(&nodeSeek);
86         
87         xmlFreeDoc(xmlCalDAVDoc);
88         
89         return userPrincipalURI;
90         
91 }
93 string CalDAV::ProcessXMLCalendarHome(){
95         string calendarHomeURI;
96         
97         xmlDocPtr xmlCalDAVDoc;
98         xmlCalDAVDoc = xmlReadMemory(serverData.c_str(), (int)serverData.size(), "noname.xml", NULL, 0);
100         xmlNodePtr nodeSeek;
101         bool nodeFound = false;
102         
103         // Start with the first node, look for multistatus.
104         
105         for (nodeSeek = xmlCalDAVDoc->children;
106                 nodeSeek != NULL;
107                 nodeSeek = nodeSeek->next)
108         {
109         
110                 if (!xmlStrcmp(nodeSeek->name, (const xmlChar *)"multistatus") ||
111                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"d:multistatus") ||
112                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"D:multistatus")
113                 ){
114                         
115                         nodeFound = true;
116                         break;
117                         
118                 }
119                 
120         }
121         
122         if (nodeFound == false){
123         
124                 return calendarHomeURI;
126         }
127         
128         // Look for response.
130         if (nodeFound == false){ return calendarHomeURI; } else { nodeFound = false; }
131         nodeFound = MatchXMLNameTransverse(&nodeSeek, "response");
133         // Look for propstat.
134         
135         if (nodeFound == false){ return calendarHomeURI; } else { nodeFound = false; }
136         nodeFound = MatchXMLNameTransverse(&nodeSeek, "propstat");
138         // Look for prop.
139         
140         if (nodeFound == false){ return calendarHomeURI; } else { nodeFound = false; }
141         nodeFound = MatchXMLNameTransverse(&nodeSeek, "prop");
142         
143         // Look for calendar-home-set.
144         
145         if (nodeFound == false){ return calendarHomeURI; } else { nodeFound = false; }
146         nodeFound = MatchXMLNameTransverse(&nodeSeek, "calendar-home-set");
147         
148         // Look for href.       
149         
150         if (nodeFound == false){ return calendarHomeURI; } else { nodeFound = false; }
151         nodeFound = MatchXMLNameTransverse(&nodeSeek, "href");
153         // Get the data from href.
154         
155         calendarHomeURI = FetchXMLData(&nodeSeek);
156         
157         xmlFreeDoc(xmlCalDAVDoc);
158         
159         return calendarHomeURI;
160         
163 CalDAVCalendarList CalDAV::ProcessXMLCalendarList(){
164         
165         CalDAVCalendarList calendarList;
166         
167         xmlDocPtr xmlCalDAVDoc;
168         xmlCalDAVDoc = xmlReadMemory(serverData.c_str(), (int)serverData.size(), "noname.xml", NULL, 0);
170         xmlNodePtr nodeSeek = NULL;
171         xmlNodePtr nodeResponse = NULL;
172         xmlNodePtr nodeMatch = NULL;
173         xmlNodePtr nodeData = NULL;
174         bool nodeFound = false;
175         int responseCount = 0;
176         
177         // Start with the first node, look for multistatus.
178         
179         for (nodeSeek = xmlCalDAVDoc->children;
180                 nodeSeek != NULL;
181                 nodeSeek = nodeSeek->next)
182         {
183         
184                 if (!xmlStrcmp(nodeSeek->name, (const xmlChar *)"multistatus") ||
185                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"d:multistatus") ||
186                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"D:multistatus")
187                 ){
188                 
189                         nodeResponse = nodeSeek->children;      
190                         nodeFound = true;
191                         break;
192                         
193                 }
194                 
195         }
196         
197         if (nodeFound == false){
198         
199                 return calendarList;
201         }
202         
203         for (nodeResponse = nodeSeek->children;
204                 nodeResponse != nullptr;
205                 nodeResponse = nodeResponse->next)
206         {
207         
208                 // Go through each of the responses and find the calendars.
210                 nodeMatch = xmlCopyNode(nodeResponse, 1);
211                 
212                 if (MatchXMLName(&nodeMatch, "response")){
214                         nodeData = xmlCopyNode(nodeMatch, 1);
215                         
216                         // Check the resource type is a calendar.
217                         
218                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
219                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
220                         if (!MatchXMLNameTransverse(&nodeData, "resourcetype")){ continue; }                    
221                         if (!MatchXMLNameTransverse(&nodeData, "calendar")){ continue; }
222                         
223                         // Get the HREF.
224                         
225                         nodeData = xmlCopyNode(nodeMatch, 1);
226                         
227                         if (!MatchXMLNameTransverse(&nodeData, "href")){ continue; }
228                                                 
229                         string hrefAddress = FetchXMLData(&nodeData);
230                         
231                         // Get the calendar name.
233                         nodeData = xmlCopyNode(nodeMatch, 1);
234                         
235                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
236                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
237                         if (!MatchXMLNameTransverse(&nodeData, "displayname")){ continue; }
238                         
239                         string calendarName = FetchXMLData(&nodeData);
240                         
241                         // Get the calendar description.
242                         
243                         nodeData = xmlCopyNode(nodeMatch, 1);
244                         
245                         string calendarDescription = "";
246                         
247                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
248                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
249                         if (MatchXMLNameTransverse(&nodeData, "calendar-description")){ 
250                         
251                                 calendarDescription = FetchXMLData(&nodeData);
252                                 
253                         }
254                         
255                         // Get the calendar colour.
256                         
257                         nodeData = xmlCopyNode(nodeMatch, 1);
259                         Colour calendarColour;
260                         bool colourResult = false;
261                         
262                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
263                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
264                         if (MatchXMLNameTransverse(&nodeData, "calendar-color")){ 
265                         
266                                 string calendarColourString = "";
267                                 string calendarColourHexValue = "";
268                                 int colourNumber;
269                                 bool keepRunning = true;
270                                 
271                                 calendarColourString = FetchXMLData(&nodeData);
272                                 
273                                 while(keepRunning == true){
274                                 
275                                         if (calendarColourString.substr(0,1) == "#" && calendarColourString.length() == 9){
276                                                 
277                                                 // Get the red colour.
278                                                 
279                                                 calendarColourHexValue = calendarColourString.substr(1,2);
280                                                 if (!HexToInt(&calendarColourHexValue, &colourNumber)){ break; }
281                                                 calendarColour.red = colourNumber;
282                                                 
283                                                 // Get the green colour.
285                                                 calendarColourHexValue = calendarColourString.substr(3,2);
286                                                 if (!HexToInt(&calendarColourHexValue, &colourNumber)){ break; }
287                                                 calendarColour.green = colourNumber;
288                                                 
289                                                 // Get the blue colour.
290                                                 
291                                                 calendarColourHexValue = calendarColourString.substr(5,2);
292                                                 if (!HexToInt(&calendarColourHexValue, &colourNumber)){ break; };
293                                                 calendarColour.blue = colourNumber;
294                                                 
295                                                 // Get the alpha.
297                                                 calendarColourHexValue = calendarColourString.substr(7,2);
298                                                 if (!HexToInt(&calendarColourHexValue, &colourNumber)){ break; };
299                                                 calendarColour.alpha = colourNumber;
300                                                 
301                                                 colourResult = true;
302                                                 
303                                         } else {
305                                                 colourResult = false;
306                                         
307                                         }
308                                         
309                                         break;
310                                         
311                                 }
312                                 
313                         }
314                         
315                         if (colourResult == false){
316                                         
317                                         calendarColour.red = 0;
318                                         calendarColour.blue = 0;
319                                         calendarColour.green = 0;
320                                         calendarColour.alpha = 0;
321                                         
322                         }
323                         
324                         // Get the calendar order.
326                         nodeData = xmlCopyNode(nodeMatch, 1);
327                         
328                         int calendarOrder = 0;
329                         
330                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
331                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
332                         if (MatchXMLNameTransverse(&nodeData, "calendar-order")){
333                                 
334                                 string calendarOrderString = FetchXMLData(&nodeData);
335                                 if (!HexToInt(&calendarOrderString, &calendarOrder)){
336                                         calendarOrder = 0;
337                                 }
338                                 
339                         }
340                         
341                         // Get the calendar tag.
342                         
343                         nodeData = xmlCopyNode(nodeMatch, 1);
344                         
345                         string calendarTag = "";
346                         
347                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
348                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
349                         if (MatchXMLNameTransverse(&nodeData, "getctag")){ 
350                                 
351                                 calendarTag = FetchXMLData(&nodeData);
352                                 
353                         }
354                         
355                         // Get the calendar tag URL.
356                         
357                         nodeData = xmlCopyNode(nodeMatch, 1);
358                         
359                         string calendarTagURL = "";
360                         
361                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
362                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
363                         if (MatchXMLNameTransverse(&nodeData, "sync-token")){ 
364                                 
365                                 calendarTagURL = FetchXMLData(&nodeData);
366                                 
367                         }
368                         
369                         // Insert the calendar information into the
370                         // list if all the information is there.
371                         
372                         calendarList.name.insert(make_pair(responseCount, calendarName));
373                         calendarList.description.insert(make_pair(responseCount, calendarDescription));
374                         calendarList.href.insert(make_pair(responseCount, hrefAddress));
375                         calendarList.calColour.insert(make_pair(responseCount, calendarColour));
376                         calendarList.order.insert(make_pair(responseCount, calendarOrder));
377                         calendarList.tag.insert(make_pair(responseCount, calendarTag));
378                         calendarList.tagURL.insert(make_pair(responseCount, calendarTagURL));
379                         
380                         responseCount++;
381                         
382                 }
383                 
384         }
385         
386         xmlFreeDoc(xmlCalDAVDoc);
387         
388         return calendarList;
389         
392 string CalDAV::ProcessXMLEntryETag(){
393         
394         string entryETag;
395         
396         xmlDocPtr xmlCalDAVDoc;
397         xmlCalDAVDoc = xmlReadMemory(serverData.c_str(), (int)serverData.size(), "noname.xml", NULL, 0);
399         xmlNodePtr nodeSeek;
400         bool nodeFound = false;
401         
402         // Start with the first node, look for multistatus.
403         
404         for (nodeSeek = xmlCalDAVDoc->children;
405                 nodeSeek != NULL;
406                 nodeSeek = nodeSeek->next)
407         {
408         
409                 if (!xmlStrcmp(nodeSeek->name, (const xmlChar *)"multistatus") ||
410                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"d:multistatus") ||
411                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"D:multistatus")
412                 ){
413                         
414                         nodeFound = true;
415                         break;
416                         
417                 }
418                 
419         }
420         
421         if (nodeFound == false){
422         
423                 return entryETag;
425         }
426         
427         // Look for response.
428         
429         if (nodeFound == false){ return entryETag; } else { nodeFound = false; }
430         nodeFound = MatchXMLNameTransverse(&nodeSeek, "response");
432         // Look for propstat.
433         
434         if (nodeFound == false){ return entryETag; } else { nodeFound = false; }
435         nodeFound = MatchXMLNameTransverse(&nodeSeek, "propstat");
437         // Look for prop.
438         
439         if (nodeFound == false){ return entryETag; } else { nodeFound = false; }
440         nodeFound = MatchXMLNameTransverse(&nodeSeek, "prop");
441         
442         // Look for calendar-home-set.
443         
444         if (nodeFound == false){ return entryETag; } else { nodeFound = false; }
445         nodeFound = MatchXMLNameTransverse(&nodeSeek, "getetag");
447         // Get the data from href.
448         
449         entryETag = FetchXMLData(&nodeSeek);    
450         
451         xmlFreeDoc(xmlCalDAVDoc);       
452         
453         // Check if the entity tag contains quote marks
454         // at the start and end and remove them (if needed).
455         
456         if (entryETag.substr(0,1) == "\"" && 
457                 entryETag.substr(entryETag.size()-1, 1) == "\"" && entryETag.size() > 2){
458                 
459                 entryETag.erase(entryETag.begin());
460                 entryETag.erase(entryETag.end()-1);
461                         
462         }
463         
464         return entryETag;
465         
468 CalDAVEntryList CalDAV::ProcessXMLEntryList(){
470         CalDAVEntryList entryList;
471         
472         xmlDocPtr xmlCalDAVDoc;
473         xmlCalDAVDoc = xmlReadMemory(serverData.c_str(), (int)serverData.size(), "noname.xml", NULL, 0);
475         xmlNodePtr nodeSeek = NULL;
476         xmlNodePtr nodeResponse = NULL;
477         xmlNodePtr nodeMatch = NULL;
478         xmlNodePtr nodeData = NULL;
479         bool nodeFound = false;
480         int responseCount = 0;
481         
482         // Start with the first node, look for multistatus.
483         
484         for (nodeSeek = xmlCalDAVDoc->children;
485                 nodeSeek != NULL;
486                 nodeSeek = nodeSeek->next)
487         {
488         
489                 if (!xmlStrcmp(nodeSeek->name, (const xmlChar *)"multistatus") ||
490                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"d:multistatus") ||
491                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"D:multistatus")
492                 ){
493                 
494                         nodeResponse = nodeSeek->children;      
495                         nodeFound = true;
496                         break;
497                         
498                 }
499                 
500         }
501         
502         if (nodeFound == false){
503         
504                 return entryList;
506         }
507         
508         for (nodeResponse = nodeSeek->children;
509                 nodeResponse != nullptr;
510                 nodeResponse = nodeResponse->next)
511         {
512         
513                 // Go through each of the responses and find the calendars.
515                 nodeMatch = xmlCopyNode(nodeResponse, 1);
516                 
517                 if (MatchXMLName(&nodeMatch, "response")){
519                         nodeData = xmlCopyNode(nodeMatch, 1);
520                         
521                         // Get the HREF.
522                         
523                         nodeData = xmlCopyNode(nodeMatch, 1);
524                         
525                         if (!MatchXMLNameTransverse(&nodeData, "href")){ continue; }
526                                                 
527                         string hrefAddress = FetchXMLData(&nodeData);
528                         
529                         // Get the calendar data.
530                         
531                         nodeData = xmlCopyNode(nodeMatch, 1);
532                         
533                         string entryDescription = "";
534                         
535                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
536                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
537                         if (MatchXMLNameTransverse(&nodeData, "calendar-data")){ 
538                         
539                                 // Note: libxml2 will strip the CDATA part at the start and
540                                 // end of each calendar-data section.
541                                 
542                                 entryDescription = FetchXMLData(&nodeData);
543                                 
544                         }
545                         
546                         // Get the entry entity tag.
547                         
548                         nodeData = xmlCopyNode(nodeMatch, 1);
549                         
550                         string entryEntityTag = "";
551                         
552                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
553                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
554                         if (MatchXMLNameTransverse(&nodeData, "getetag")){ 
555                                 
556                                 entryEntityTag = FetchXMLData(&nodeData);
557                                 
558                         }
559                         
560                         // Insert the calendar information into the
561                         // list if all the information is there.
562                         
563                         entryList.href.insert(make_pair(responseCount, hrefAddress));
564                         entryList.data.insert(make_pair(responseCount, entryDescription));
565                         entryList.tag.insert(make_pair(responseCount, entryEntityTag));
566                         
567                         responseCount++;
568                         
569                 }
570                 
571         }
572         
573         xmlFreeDoc(xmlCalDAVDoc);
574         
575         return entryList;
576         
579 CalDAVEntryList CalDAV::ProcessXMLSyncTokenList(){
581         CalDAVEntryList entryList;
582         
583         xmlDocPtr xmlCalDAVDoc;
584         xmlCalDAVDoc = xmlReadMemory(serverData.c_str(), (int)serverData.size(), "noname.xml", NULL, 0);
586         xmlNodePtr nodeSeek = NULL;
587         xmlNodePtr nodeResponse = NULL;
588         xmlNodePtr nodeMatch = NULL;
589         xmlNodePtr nodeData = NULL;
590         bool nodeFound = false;
591         int responseCount = 0;
592         
593         // Start with the first node, look for multistatus.
594         
595         for (nodeSeek = xmlCalDAVDoc->children;
596                 nodeSeek != NULL;
597                 nodeSeek = nodeSeek->next)
598         {
599         
600                 if (!xmlStrcmp(nodeSeek->name, (const xmlChar *)"multistatus") ||
601                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"d:multistatus") ||
602                         !xmlStrcmp(nodeSeek->name, (const xmlChar *)"D:multistatus")
603                 ){
604                 
605                         nodeResponse = nodeSeek->children;      
606                         nodeFound = true;
607                         break;
608                         
609                 }
610                 
611         }
612         
613         if (nodeFound == false){
614         
615                 return entryList;
617         }
618         
619         for (nodeResponse = nodeSeek->children;
620                 nodeResponse != nullptr;
621                 nodeResponse = nodeResponse->next)
622         {
623         
624                 // Go through each of the responses and find the calendars.
626                 nodeMatch = xmlCopyNode(nodeResponse, 1);
627                 
628                 if (MatchXMLName(&nodeMatch, "response")){
630                         nodeData = xmlCopyNode(nodeMatch, 1);
631                         
632                         // Get the HREF.
633                         
634                         nodeData = xmlCopyNode(nodeMatch, 1);
635                         
636                         if (!MatchXMLNameTransverse(&nodeData, "href")){ continue; }
637                                                 
638                         string hrefAddress = FetchXMLData(&nodeData);
639                         
640                         // Get the entry entity tag.
641                         
642                         nodeData = xmlCopyNode(nodeMatch, 1);
643                         
644                         string entryEntityTag = "";
645                         
646                         if (!MatchXMLNameTransverse(&nodeData, "propstat")){ continue; }
647                         if (!MatchXMLNameTransverse(&nodeData, "prop")){ continue; }
648                         if (MatchXMLNameTransverse(&nodeData, "getetag")){ 
649                                 
650                                 entryEntityTag = FetchXMLData(&nodeData);
651                                 
652                         }
653                         
654                         // Insert the calendar information into the
655                         // list if all the information is there.
656                         
657                         entryList.href.insert(make_pair(responseCount, hrefAddress));
658                         entryList.data.insert(make_pair(responseCount, ""));
659                         entryList.tag.insert(make_pair(responseCount, entryEntityTag));
660                         
661                         responseCount++;
662                         
663                 }
664                 
665         }
666         
667         xmlFreeDoc(xmlCalDAVDoc);
668         
669         return entryList;
670         
673 bool CalDAV::MatchXMLNameTransverse(xmlNodePtr *nodePtr, string nodeName){
675         string nodeNameSmallD = "d:" + nodeName;
676         string nodeNameLargeD = "D:" + nodeName;
677         
678         for ((*nodePtr) = (*nodePtr)->children;
679                 (*nodePtr) != NULL;
680                 (*nodePtr) = (*nodePtr)->next)
681         {
682         
683                 if (!xmlStrcmp((*nodePtr)->name, (const xmlChar *)nodeName.c_str()) ||
684                         !xmlStrcmp((*nodePtr)->name, (const xmlChar *)nodeNameSmallD.c_str()) ||
685                         !xmlStrcmp((*nodePtr)->name, (const xmlChar *)nodeNameLargeD.c_str())
686                 ){
687                         
688                         return true;
689                         
690                 }
691                 
692         }
693         
694         return false;
695         
698 bool CalDAV::MatchXMLName(xmlNodePtr *nodePtrOriginal, string nodeName){
700         if (nodePtrOriginal == nullptr){
701                 
702                 return false;
703                 
704         }
705         
706         string nodeNameSmallD = "d:" + nodeName;
707         string nodeNameLargeD = "D:" + nodeName;
708         
709         xmlNodePtr *nodePtr = nodePtrOriginal;
710         
711         if (!xmlStrcmp((*nodePtr)->name, (const xmlChar *)nodeName.c_str()) ||
712                 !xmlStrcmp((*nodePtr)->name, (const xmlChar *)nodeNameSmallD.c_str()) ||
713                 !xmlStrcmp((*nodePtr)->name, (const xmlChar *)nodeNameLargeD.c_str())
714         ){
715                         
716                 return true;
717                         
718         } else {
719                         
720                 return false;
721                 
722         }
723         
724         return false;
725         
728 string CalDAV::FetchXMLData(xmlNodePtr *nodePtr){
730         for ((*nodePtr) = (*nodePtr)->children;
731                 (*nodePtr) != NULL;
732                 (*nodePtr) = (*nodePtr)->next)
733         {
734                                                                 
735                 return (const char*)(*nodePtr)->content;
736                         
737         }
738         
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