calendar  v3
free_busy_request.h
1 // Copyright 2010 Google Inc.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License"); you may not
4 // use this file except in compliance with the License. You may obtain a copy of
5 // the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11 // WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12 // License for the specific language governing permissions and limitations under
13 // the License.
14 
15 // This code was generated by google-apis-code-generator 1.5.1
16 // Build date: 2018-10-08 17:45:39 UTC
17 // on: 2020-03-19, 04:06:47 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // Calendar API (calendar/v3)
24 // Generated from:
25 // Version: v3
26 // Revision: 411
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_CALENDAR_API_FREE_BUSY_REQUEST_H_
31 #define GOOGLE_CALENDAR_API_FREE_BUSY_REQUEST_H_
32 
33 #include <string>
34 #include "googleapis/base/integral_types.h"
35 #include "googleapis/base/macros.h"
36 #include "googleapis/client/data/jsoncpp_data.h"
37 #include "googleapis/client/util/date_time.h"
38 #include "googleapis/strings/stringpiece.h"
39 
40 #include "google/calendar_api/free_busy_request_item.h"
41 
42 namespace Json {
43 class Value;
44 } // namespace Json
45 
46 namespace google_calendar_api {
47 using namespace googleapis;
48 
54 class FreeBusyRequest : public client::JsonCppData {
55  public:
61  static FreeBusyRequest* New();
62 
68  explicit FreeBusyRequest(const Json::Value& storage);
69 
75  explicit FreeBusyRequest(Json::Value* storage);
76 
80  virtual ~FreeBusyRequest();
81 
87  const StringPiece GetTypeName() const {
88  return StringPiece("google_calendar_api::FreeBusyRequest");
89  }
90 
97  return Storage().isMember("calendarExpansionMax");
98  }
99 
104  MutableStorage()->removeMember("calendarExpansionMax");
105  }
106 
107 
112  const Json::Value& storage = Storage("calendarExpansionMax");
113  return client::JsonValueToCppValueHelper<int32 >(storage);
114  }
115 
124  void set_calendar_expansion_max(int32 value) {
125  client::SetJsonValueFromCppValueHelper<int32 >(
126  value, MutableStorage("calendarExpansionMax"));
127  }
128 
134  bool has_group_expansion_max() const {
135  return Storage().isMember("groupExpansionMax");
136  }
137 
142  MutableStorage()->removeMember("groupExpansionMax");
143  }
144 
145 
149  int32 get_group_expansion_max() const {
150  const Json::Value& storage = Storage("groupExpansionMax");
151  return client::JsonValueToCppValueHelper<int32 >(storage);
152  }
153 
163  void set_group_expansion_max(int32 value) {
164  client::SetJsonValueFromCppValueHelper<int32 >(
165  value, MutableStorage("groupExpansionMax"));
166  }
167 
173  bool has_items() const {
174  return Storage().isMember("items");
175  }
176 
180  void clear_items() {
181  MutableStorage()->removeMember("items");
182  }
183 
184 
188  const client::JsonCppArray<FreeBusyRequestItem > get_items() const;
189 
197  client::JsonCppArray<FreeBusyRequestItem > mutable_items();
198 
204  bool has_time_max() const {
205  return Storage().isMember("timeMax");
206  }
207 
211  void clear_time_max() {
212  MutableStorage()->removeMember("timeMax");
213  }
214 
215 
219  client::DateTime get_time_max() const {
220  const Json::Value& storage = Storage("timeMax");
221  return client::JsonValueToCppValueHelper<client::DateTime >(storage);
222  }
223 
231  void set_time_max(client::DateTime value) {
232  client::SetJsonValueFromCppValueHelper<client::DateTime >(
233  value, MutableStorage("timeMax"));
234  }
235 
241  bool has_time_min() const {
242  return Storage().isMember("timeMin");
243  }
244 
248  void clear_time_min() {
249  MutableStorage()->removeMember("timeMin");
250  }
251 
252 
256  client::DateTime get_time_min() const {
257  const Json::Value& storage = Storage("timeMin");
258  return client::JsonValueToCppValueHelper<client::DateTime >(storage);
259  }
260 
268  void set_time_min(client::DateTime value) {
269  client::SetJsonValueFromCppValueHelper<client::DateTime >(
270  value, MutableStorage("timeMin"));
271  }
272 
278  bool has_time_zone() const {
279  return Storage().isMember("timeZone");
280  }
281 
286  MutableStorage()->removeMember("timeZone");
287  }
288 
289 
293  const StringPiece get_time_zone() const {
294  const Json::Value& v = Storage("timeZone");
295  if (v == Json::Value::null) return StringPiece("");
296  return StringPiece(v.asCString());
297  }
298 
306  void set_time_zone(const StringPiece& value) {
307  *MutableStorage("timeZone") = value.data();
308  }
309 
310  private:
311  void operator=(const FreeBusyRequest&);
312 }; // FreeBusyRequest
313 } // namespace google_calendar_api
314 #endif // GOOGLE_CALENDAR_API_FREE_BUSY_REQUEST_H_
bool has_time_zone() const
Definition: free_busy_request.h:278
void set_time_min(client::DateTime value)
Definition: free_busy_request.h:268
void set_group_expansion_max(int32 value)
Definition: free_busy_request.h:163
int32 get_group_expansion_max() const
Definition: free_busy_request.h:149
void set_calendar_expansion_max(int32 value)
Definition: free_busy_request.h:124
Definition: free_busy_request.h:54
bool has_items() const
Definition: free_busy_request.h:173
void clear_time_min()
Definition: free_busy_request.h:248
bool has_group_expansion_max() const
Definition: free_busy_request.h:134
int32 get_calendar_expansion_max() const
Definition: free_busy_request.h:111
const StringPiece get_time_zone() const
Definition: free_busy_request.h:293
const StringPiece GetTypeName() const
Definition: free_busy_request.h:87
void set_time_zone(const StringPiece &value)
Definition: free_busy_request.h:306
void clear_calendar_expansion_max()
Definition: free_busy_request.h:103
bool has_time_max() const
Definition: free_busy_request.h:204
Definition: acl.h:40
void clear_time_zone()
Definition: free_busy_request.h:285
void set_time_max(client::DateTime value)
Definition: free_busy_request.h:231
Definition: acl.cc:42
bool has_calendar_expansion_max() const
Definition: free_busy_request.h:96
void clear_items()
Definition: free_busy_request.h:180
client::DateTime get_time_max() const
Definition: free_busy_request.h:219
void clear_group_expansion_max()
Definition: free_busy_request.h:141
void clear_time_max()
Definition: free_busy_request.h:211
client::DateTime get_time_min() const
Definition: free_busy_request.h:256
bool has_time_min() const
Definition: free_busy_request.h:241