youtube  v3
channel_list_response.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-02-27, 01:46:08 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // YouTube Data API (youtube/v3)
24 // Generated from:
25 // Version: v3
26 // Revision: 222
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_YOUTUBE_API_CHANNEL_LIST_RESPONSE_H_
31 #define GOOGLE_YOUTUBE_API_CHANNEL_LIST_RESPONSE_H_
32 
33 #include <string>
34 #include "googleapis/base/macros.h"
35 #include "googleapis/client/data/jsoncpp_data.h"
36 #include "googleapis/strings/stringpiece.h"
37 
38 #include "google/youtube_api/channel.h"
39 #include "google/youtube_api/page_info.h"
40 #include "google/youtube_api/token_pagination.h"
41 
42 namespace Json {
43 class Value;
44 } // namespace Json
45 
46 namespace google_youtube_api {
47 using namespace googleapis;
48 
54 class ChannelListResponse : public client::JsonCppData {
55  public:
61  static ChannelListResponse* New();
62 
68  explicit ChannelListResponse(const Json::Value& storage);
69 
75  explicit ChannelListResponse(Json::Value* storage);
76 
80  virtual ~ChannelListResponse();
81 
87  const StringPiece GetTypeName() const {
88  return StringPiece("google_youtube_api::ChannelListResponse");
89  }
90 
96  bool has_etag() const {
97  return Storage().isMember("etag");
98  }
99 
103  void clear_etag() {
104  MutableStorage()->removeMember("etag");
105  }
106 
107 
111  const StringPiece get_etag() const {
112  const Json::Value& v = Storage("etag");
113  if (v == Json::Value::null) return StringPiece("");
114  return StringPiece(v.asCString());
115  }
116 
124  void set_etag(const StringPiece& value) {
125  *MutableStorage("etag") = value.data();
126  }
127 
133  bool has_event_id() const {
134  return Storage().isMember("eventId");
135  }
136 
140  void clear_event_id() {
141  MutableStorage()->removeMember("eventId");
142  }
143 
144 
148  const StringPiece get_event_id() const {
149  const Json::Value& v = Storage("eventId");
150  if (v == Json::Value::null) return StringPiece("");
151  return StringPiece(v.asCString());
152  }
153 
161  void set_event_id(const StringPiece& value) {
162  *MutableStorage("eventId") = value.data();
163  }
164 
170  bool has_items() const {
171  return Storage().isMember("items");
172  }
173 
177  void clear_items() {
178  MutableStorage()->removeMember("items");
179  }
180 
181 
185  const client::JsonCppArray<Channel > get_items() const;
186 
194  client::JsonCppArray<Channel > mutable_items();
195 
201  bool has_kind() const {
202  return Storage().isMember("kind");
203  }
204 
208  void clear_kind() {
209  MutableStorage()->removeMember("kind");
210  }
211 
212 
216  const StringPiece get_kind() const {
217  const Json::Value& v = Storage("kind");
218  if (v == Json::Value::null) return StringPiece("");
219  return StringPiece(v.asCString());
220  }
221 
230  void set_kind(const StringPiece& value) {
231  *MutableStorage("kind") = value.data();
232  }
233 
239  bool has_next_page_token() const {
240  return Storage().isMember("nextPageToken");
241  }
242 
247  MutableStorage()->removeMember("nextPageToken");
248  }
249 
250 
254  const StringPiece get_next_page_token() const {
255  const Json::Value& v = Storage("nextPageToken");
256  if (v == Json::Value::null) return StringPiece("");
257  return StringPiece(v.asCString());
258  }
259 
268  void set_next_page_token(const StringPiece& value) {
269  *MutableStorage("nextPageToken") = value.data();
270  }
271 
277  bool has_page_info() const {
278  return Storage().isMember("pageInfo");
279  }
280 
285  MutableStorage()->removeMember("pageInfo");
286  }
287 
288 
292  const PageInfo get_page_info() const;
293 
299  PageInfo mutable_pageInfo();
300 
306  bool has_prev_page_token() const {
307  return Storage().isMember("prevPageToken");
308  }
309 
314  MutableStorage()->removeMember("prevPageToken");
315  }
316 
317 
321  const StringPiece get_prev_page_token() const {
322  const Json::Value& v = Storage("prevPageToken");
323  if (v == Json::Value::null) return StringPiece("");
324  return StringPiece(v.asCString());
325  }
326 
335  void set_prev_page_token(const StringPiece& value) {
336  *MutableStorage("prevPageToken") = value.data();
337  }
338 
344  bool has_token_pagination() const {
345  return Storage().isMember("tokenPagination");
346  }
347 
352  MutableStorage()->removeMember("tokenPagination");
353  }
354 
355 
360  const TokenPagination get_token_pagination() const;
361 
367  TokenPagination mutable_tokenPagination();
368 
374  bool has_visitor_id() const {
375  return Storage().isMember("visitorId");
376  }
377 
382  MutableStorage()->removeMember("visitorId");
383  }
384 
385 
389  const StringPiece get_visitor_id() const {
390  const Json::Value& v = Storage("visitorId");
391  if (v == Json::Value::null) return StringPiece("");
392  return StringPiece(v.asCString());
393  }
394 
402  void set_visitor_id(const StringPiece& value) {
403  *MutableStorage("visitorId") = value.data();
404  }
405 
406  private:
407  void operator=(const ChannelListResponse&);
408 }; // ChannelListResponse
409 } // namespace google_youtube_api
410 #endif // GOOGLE_YOUTUBE_API_CHANNEL_LIST_RESPONSE_H_
bool has_visitor_id() const
Definition: channel_list_response.h:374
Definition: access_policy.cc:40
bool has_token_pagination() const
Definition: channel_list_response.h:344
void clear_visitor_id()
Definition: channel_list_response.h:381
void set_next_page_token(const StringPiece &value)
Definition: channel_list_response.h:268
void clear_next_page_token()
Definition: channel_list_response.h:246
bool has_prev_page_token() const
Definition: channel_list_response.h:306
void clear_token_pagination()
Definition: channel_list_response.h:351
bool has_etag() const
Definition: channel_list_response.h:96
void clear_etag()
Definition: channel_list_response.h:103
void set_etag(const StringPiece &value)
Definition: channel_list_response.h:124
const StringPiece get_visitor_id() const
Definition: channel_list_response.h:389
const StringPiece get_event_id() const
Definition: channel_list_response.h:148
void clear_items()
Definition: channel_list_response.h:177
bool has_kind() const
Definition: channel_list_response.h:201
void set_prev_page_token(const StringPiece &value)
Definition: channel_list_response.h:335
bool has_page_info() const
Definition: channel_list_response.h:277
Definition: access_policy.h:38
const StringPiece get_prev_page_token() const
Definition: channel_list_response.h:321
const StringPiece GetTypeName() const
Definition: channel_list_response.h:87
bool has_next_page_token() const
Definition: channel_list_response.h:239
Definition: channel_list_response.h:54
Definition: token_pagination.h:49
void clear_kind()
Definition: channel_list_response.h:208
Definition: page_info.h:51
void clear_prev_page_token()
Definition: channel_list_response.h:313
void set_event_id(const StringPiece &value)
Definition: channel_list_response.h:161
bool has_items() const
Definition: channel_list_response.h:170
void set_visitor_id(const StringPiece &value)
Definition: channel_list_response.h:402
const StringPiece get_etag() const
Definition: channel_list_response.h:111
void clear_event_id()
Definition: channel_list_response.h:140
bool has_event_id() const
Definition: channel_list_response.h:133
void set_kind(const StringPiece &value)
Definition: channel_list_response.h:230
const StringPiece get_kind() const
Definition: channel_list_response.h:216
void clear_page_info()
Definition: channel_list_response.h:284
const StringPiece get_next_page_token() const
Definition: channel_list_response.h:254