drive  v2
comment_reply.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, 05:24:40 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // Drive API (drive/v2)
24 // Generated from:
25 // Version: v2
26 // Revision: 393
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_DRIVE_API_COMMENT_REPLY_H_
31 #define GOOGLE_DRIVE_API_COMMENT_REPLY_H_
32 
33 #include <string>
34 #include "googleapis/base/macros.h"
35 #include "googleapis/client/data/jsoncpp_data.h"
36 #include "googleapis/client/util/date_time.h"
37 #include "googleapis/strings/stringpiece.h"
38 
39 #include "google/drive_api/user.h"
40 
41 namespace Json {
42 class Value;
43 } // namespace Json
44 
45 namespace google_drive_api {
46 using namespace googleapis;
47 
53 class CommentReply : public client::JsonCppData {
54  public:
60  static CommentReply* New();
61 
67  explicit CommentReply(const Json::Value& storage);
68 
74  explicit CommentReply(Json::Value* storage);
75 
79  virtual ~CommentReply();
80 
86  const StringPiece GetTypeName() const {
87  return StringPiece("google_drive_api::CommentReply");
88  }
89 
95  bool has_author() const {
96  return Storage().isMember("author");
97  }
98 
102  void clear_author() {
103  MutableStorage()->removeMember("author");
104  }
105 
106 
110  const User get_author() const;
111 
120  User mutable_author();
121 
127  bool has_content() const {
128  return Storage().isMember("content");
129  }
130 
134  void clear_content() {
135  MutableStorage()->removeMember("content");
136  }
137 
138 
142  const StringPiece get_content() const {
143  const Json::Value& v = Storage("content");
144  if (v == Json::Value::null) return StringPiece("");
145  return StringPiece(v.asCString());
146  }
147 
157  void set_content(const StringPiece& value) {
158  *MutableStorage("content") = value.data();
159  }
160 
166  bool has_created_date() const {
167  return Storage().isMember("createdDate");
168  }
169 
174  MutableStorage()->removeMember("createdDate");
175  }
176 
177 
181  client::DateTime get_created_date() const {
182  const Json::Value& storage = Storage("createdDate");
183  return client::JsonValueToCppValueHelper<client::DateTime >(storage);
184  }
185 
193  void set_created_date(client::DateTime value) {
194  client::SetJsonValueFromCppValueHelper<client::DateTime >(
195  value, MutableStorage("createdDate"));
196  }
197 
203  bool has_deleted() const {
204  return Storage().isMember("deleted");
205  }
206 
210  void clear_deleted() {
211  MutableStorage()->removeMember("deleted");
212  }
213 
214 
218  bool get_deleted() const {
219  const Json::Value& storage = Storage("deleted");
220  return client::JsonValueToCppValueHelper<bool >(storage);
221  }
222 
232  void set_deleted(bool value) {
233  client::SetJsonValueFromCppValueHelper<bool >(
234  value, MutableStorage("deleted"));
235  }
236 
242  bool has_html_content() const {
243  return Storage().isMember("htmlContent");
244  }
245 
250  MutableStorage()->removeMember("htmlContent");
251  }
252 
253 
257  const StringPiece get_html_content() const {
258  const Json::Value& v = Storage("htmlContent");
259  if (v == Json::Value::null) return StringPiece("");
260  return StringPiece(v.asCString());
261  }
262 
270  void set_html_content(const StringPiece& value) {
271  *MutableStorage("htmlContent") = value.data();
272  }
273 
279  bool has_kind() const {
280  return Storage().isMember("kind");
281  }
282 
286  void clear_kind() {
287  MutableStorage()->removeMember("kind");
288  }
289 
290 
294  const StringPiece get_kind() const {
295  const Json::Value& v = Storage("kind");
296  if (v == Json::Value::null) return StringPiece("");
297  return StringPiece(v.asCString());
298  }
299 
307  void set_kind(const StringPiece& value) {
308  *MutableStorage("kind") = value.data();
309  }
310 
316  bool has_modified_date() const {
317  return Storage().isMember("modifiedDate");
318  }
319 
324  MutableStorage()->removeMember("modifiedDate");
325  }
326 
327 
331  client::DateTime get_modified_date() const {
332  const Json::Value& storage = Storage("modifiedDate");
333  return client::JsonValueToCppValueHelper<client::DateTime >(storage);
334  }
335 
343  void set_modified_date(client::DateTime value) {
344  client::SetJsonValueFromCppValueHelper<client::DateTime >(
345  value, MutableStorage("modifiedDate"));
346  }
347 
353  bool has_reply_id() const {
354  return Storage().isMember("replyId");
355  }
356 
360  void clear_reply_id() {
361  MutableStorage()->removeMember("replyId");
362  }
363 
364 
368  const StringPiece get_reply_id() const {
369  const Json::Value& v = Storage("replyId");
370  if (v == Json::Value::null) return StringPiece("");
371  return StringPiece(v.asCString());
372  }
373 
381  void set_reply_id(const StringPiece& value) {
382  *MutableStorage("replyId") = value.data();
383  }
384 
390  bool has_verb() const {
391  return Storage().isMember("verb");
392  }
393 
397  void clear_verb() {
398  MutableStorage()->removeMember("verb");
399  }
400 
401 
405  const StringPiece get_verb() const {
406  const Json::Value& v = Storage("verb");
407  if (v == Json::Value::null) return StringPiece("");
408  return StringPiece(v.asCString());
409  }
410 
427  void set_verb(const StringPiece& value) {
428  *MutableStorage("verb") = value.data();
429  }
430 
431  private:
432  void operator=(const CommentReply&);
433 }; // CommentReply
434 } // namespace google_drive_api
435 #endif // GOOGLE_DRIVE_API_COMMENT_REPLY_H_
client::DateTime get_created_date() const
Definition: comment_reply.h:181
void clear_kind()
Definition: comment_reply.h:286
bool has_html_content() const
Definition: comment_reply.h:242
void set_deleted(bool value)
Definition: comment_reply.h:232
void clear_deleted()
Definition: comment_reply.h:210
void set_kind(const StringPiece &value)
Definition: comment_reply.h:307
Definition: user.h:50
bool has_deleted() const
Definition: comment_reply.h:203
bool has_content() const
Definition: comment_reply.h:127
bool get_deleted() const
Definition: comment_reply.h:218
bool has_verb() const
Definition: comment_reply.h:390
void clear_verb()
Definition: comment_reply.h:397
const StringPiece get_html_content() const
Definition: comment_reply.h:257
void clear_content()
Definition: comment_reply.h:134
client::DateTime get_modified_date() const
Definition: comment_reply.h:331
void clear_author()
Definition: comment_reply.h:102
void set_created_date(client::DateTime value)
Definition: comment_reply.h:193
void set_html_content(const StringPiece &value)
Definition: comment_reply.h:270
void clear_created_date()
Definition: comment_reply.h:173
bool has_modified_date() const
Definition: comment_reply.h:316
bool has_author() const
Definition: comment_reply.h:95
const StringPiece GetTypeName() const
Definition: comment_reply.h:86
bool has_created_date() const
Definition: comment_reply.h:166
Definition: about.h:41
void set_modified_date(client::DateTime value)
Definition: comment_reply.h:343
void clear_reply_id()
Definition: comment_reply.h:360
void set_content(const StringPiece &value)
Definition: comment_reply.h:157
const StringPiece get_reply_id() const
Definition: comment_reply.h:368
bool has_kind() const
Definition: comment_reply.h:279
void set_verb(const StringPiece &value)
Definition: comment_reply.h:427
const StringPiece get_content() const
Definition: comment_reply.h:142
void clear_modified_date()
Definition: comment_reply.h:323
void set_reply_id(const StringPiece &value)
Definition: comment_reply.h:381
void clear_html_content()
Definition: comment_reply.h:249
Definition: about.cc:43
const StringPiece get_verb() const
Definition: comment_reply.h:405
Definition: comment_reply.h:53
const StringPiece get_kind() const
Definition: comment_reply.h:294
bool has_reply_id() const
Definition: comment_reply.h:353