Portability Libraries  2015.2.0.0
Common Methods and Objects for Platform Independance.
vquery.hpp
Go to the documentation of this file.
1 //
2 // BEGIN_DOUGLAS_MARK_ROYER_COPYRIGHT
3 //
4 // Copyright (C) 1993-2012 Douglas Mark Royer, All Rights Reserved.
5 //
6 // NOTICE:
7 //
8 // THIS SOURCE CODE BELONGS TO DOUGLAS MARK ROYER
9 // THIS CODE IS CONSIDERED A
10 // TRADE SECRET AND IS NOT TO BE DIVULGED OR USED BY PARTIES WHO HAVE
11 // NOT RECEIVED WRITTEN AUTHORIZATION FROM THE OWNER.
12 //
13 // THIS SOURCE CODE IS UNPUBLISHED WORK FULLY PROTECTED BY THE UNITED
14 // STATES COPYRIGHT LAWS AND IS CONSIDERED A TRADE SECRET BELONGING
15 // TO THE COPYRIGHT HOLDER.
16 //
17 // THIS SOFTWARE AND MANUAL ARE BOTH PROTECTED BY UNITED STATES
18 // COPYRIGHT LAW (TITLE 17 UNITED STATES CODE). UNAUTHORIZED REPRODUCTION
19 // AND/OR SALE MAY RESULT IN IMPRISONMENT OF UP TO ONE YEAR AND FINES
20 // OF UP TO $100,000 (17 USC 506). COPYRIGHT INFRINGERS MAY ALSO
21 // BE SUBJECT TO CIVIL LIABILITY.
22 //
23 // THIS NOTICE AND THE ABOVE COPYRIGHT NOTICE MUST REMAIN IN ALL
24 // COPIES AND ANY DERIVED WORK.
25 //
26 // ALL OF THIS CODE IS ORIGINAL WORK BY THE COPYRIGHT HOLDER.
27 //
28 // THIS DOCUMENT AND THE INFORMATION CONTAINED HEREIN IS
29 // PROVIDED ON AN "AS IS" BASIS AND INET-CONSULTING.COM, INC.
30 // DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT
31 // NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
32 // HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
33 // WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR
34 // PURPOSE. ANY SERVICE CONTRACT WILL BE UNDER A SEPARATE
35 // LICENSE.
36 //
37 // END_DOUGLAS_MARK_ROYER_COPYRIGHT
38 //
39 
40 /**
41  * @author Doug Royer / SoftwareAndServices
42  * @file
43  * This is a class and interfaces in C and C++ that represents calendar VQUERY
44  * component. It is designed to be compatible with RFC-iCalendar, RFC-iTIP, RFC-iMIP,
45  * CAP, and current WebDAV and CalDAV calendars.
46  */
47 #ifndef _PROJECTCONTRACTING_LIBRARY_ICALENDAR_VQUERY_HPP_
48 #define _PROJECTCONTRACTING_LIBRARY_ICALENDAR_VQUERY_HPP_
49 
50 #ifndef EXPORT_ICALENDAR
51 #ifdef BUILDING_LIBRARY_ICALENDAR
52 #define EXPORT_ICALENDAR EXPORT_OUT
53 #else
54 #define EXPORT_ICALENDAR EXPORT_IN
55 #endif
56 #endif
57 
58 #ifdef BUILDING_LIBRARY_ICALENDAR
59 #include "iCalendar.hpp"
60 #include "component.hpp"
61 #else
62 #include <SaS/iCalendar/iCalendar.hpp>
63 #include <SaS/iCalendar/component.hpp>
64 #endif
65 
66 using namespace std;
70 
71 namespace SoftwareAndServices
72 {
73  namespace Library
74  {
75  namespace iCalendar
76  {
77 
78  /**
79  * @class vquery
80  * An implementation of a RFC-CAP VQUERY component.
81  */
82  class EXPORT_ICALENDAR vquery
83  : public component
84  {
85 
86  public:
87 
88  /**
89  * vquery Constructor.
90  */
91  vquery();
92 
93  /**
94  * vquery Destructor.
95  */
96  virtual ~vquery();
97 
98  /**
99  * #Parse a vquery.
100  *
101  * @param in An open Parse object.
102  *
103  * @param errors Where any errors may be stored.
104  *
105  * @return TRUE when the parse is successful.
106  */
107  virtual bool parse(Parse & in, component * errors);
108 
109  /**
110  * #Parse a vquery.
111  *
112  * @param in A pointer to a string containing a vquery.
113  *
114  * @param errors Where any errors may be stored.
115  *
116  * @return TRUE when the parse is successful.
117  */
118  bool parse(const char * in, component * errors);
119 
120  /**
121  * @return TRUE if the url values are correct.
122  */
123  bool valid() const;
124  };
125  }
126  }
127 }
128 
129 #endif // _PROJECTCONTRACTING_LIBRARY_ICALENDAR_VQUERY_HPP_
STL namespace.
unsigned int errors[MAX_TESTS]