youtube  v3
channel_settings.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_SETTINGS_H_
31 #define GOOGLE_YOUTUBE_API_CHANNEL_SETTINGS_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 namespace Json {
39 class Value;
40 } // namespace Json
41 
42 namespace google_youtube_api {
43 using namespace googleapis;
44 
50 class ChannelSettings : public client::JsonCppData {
51  public:
57  static ChannelSettings* New();
58 
64  explicit ChannelSettings(const Json::Value& storage);
65 
71  explicit ChannelSettings(Json::Value* storage);
72 
76  virtual ~ChannelSettings();
77 
83  const StringPiece GetTypeName() const {
84  return StringPiece("google_youtube_api::ChannelSettings");
85  }
86 
92  bool has_country() const {
93  return Storage().isMember("country");
94  }
95 
99  void clear_country() {
100  MutableStorage()->removeMember("country");
101  }
102 
103 
107  const StringPiece get_country() const {
108  const Json::Value& v = Storage("country");
109  if (v == Json::Value::null) return StringPiece("");
110  return StringPiece(v.asCString());
111  }
112 
120  void set_country(const StringPiece& value) {
121  *MutableStorage("country") = value.data();
122  }
123 
129  bool has_default_language() const {
130  return Storage().isMember("defaultLanguage");
131  }
132 
137  MutableStorage()->removeMember("defaultLanguage");
138  }
139 
140 
144  const StringPiece get_default_language() const {
145  const Json::Value& v = Storage("defaultLanguage");
146  if (v == Json::Value::null) return StringPiece("");
147  return StringPiece(v.asCString());
148  }
149 
154  void set_default_language(const StringPiece& value) {
155  *MutableStorage("defaultLanguage") = value.data();
156  }
157 
163  bool has_default_tab() const {
164  return Storage().isMember("defaultTab");
165  }
166 
171  MutableStorage()->removeMember("defaultTab");
172  }
173 
174 
178  const StringPiece get_default_tab() const {
179  const Json::Value& v = Storage("defaultTab");
180  if (v == Json::Value::null) return StringPiece("");
181  return StringPiece(v.asCString());
182  }
183 
191  void set_default_tab(const StringPiece& value) {
192  *MutableStorage("defaultTab") = value.data();
193  }
194 
200  bool has_description() const {
201  return Storage().isMember("description");
202  }
203 
208  MutableStorage()->removeMember("description");
209  }
210 
211 
215  const StringPiece get_description() const {
216  const Json::Value& v = Storage("description");
217  if (v == Json::Value::null) return StringPiece("");
218  return StringPiece(v.asCString());
219  }
220 
228  void set_description(const StringPiece& value) {
229  *MutableStorage("description") = value.data();
230  }
231 
238  return Storage().isMember("featuredChannelsTitle");
239  }
240 
245  MutableStorage()->removeMember("featuredChannelsTitle");
246  }
247 
248 
252  const StringPiece get_featured_channels_title() const {
253  const Json::Value& v = Storage("featuredChannelsTitle");
254  if (v == Json::Value::null) return StringPiece("");
255  return StringPiece(v.asCString());
256  }
257 
265  void set_featured_channels_title(const StringPiece& value) {
266  *MutableStorage("featuredChannelsTitle") = value.data();
267  }
268 
275  return Storage().isMember("featuredChannelsUrls");
276  }
277 
282  MutableStorage()->removeMember("featuredChannelsUrls");
283  }
284 
285 
290  const client::JsonCppArray<string > get_featured_channels_urls() const {
291  const Json::Value& storage = Storage("featuredChannelsUrls");
292  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
293  }
294 
303  client::JsonCppArray<string > mutable_featuredChannelsUrls() {
304  Json::Value* storage = MutableStorage("featuredChannelsUrls");
305  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
306  }
307 
313  bool has_keywords() const {
314  return Storage().isMember("keywords");
315  }
316 
320  void clear_keywords() {
321  MutableStorage()->removeMember("keywords");
322  }
323 
324 
328  const StringPiece get_keywords() const {
329  const Json::Value& v = Storage("keywords");
330  if (v == Json::Value::null) return StringPiece("");
331  return StringPiece(v.asCString());
332  }
333 
341  void set_keywords(const StringPiece& value) {
342  *MutableStorage("keywords") = value.data();
343  }
344 
350  bool has_moderate_comments() const {
351  return Storage().isMember("moderateComments");
352  }
353 
358  MutableStorage()->removeMember("moderateComments");
359  }
360 
361 
365  bool get_moderate_comments() const {
366  const Json::Value& storage = Storage("moderateComments");
367  return client::JsonValueToCppValueHelper<bool >(storage);
368  }
369 
378  void set_moderate_comments(bool value) {
379  client::SetJsonValueFromCppValueHelper<bool >(
380  value, MutableStorage("moderateComments"));
381  }
382 
388  bool has_profile_color() const {
389  return Storage().isMember("profileColor");
390  }
391 
396  MutableStorage()->removeMember("profileColor");
397  }
398 
399 
403  const StringPiece get_profile_color() const {
404  const Json::Value& v = Storage("profileColor");
405  if (v == Json::Value::null) return StringPiece("");
406  return StringPiece(v.asCString());
407  }
408 
416  void set_profile_color(const StringPiece& value) {
417  *MutableStorage("profileColor") = value.data();
418  }
419 
425  bool has_show_browse_view() const {
426  return Storage().isMember("showBrowseView");
427  }
428 
433  MutableStorage()->removeMember("showBrowseView");
434  }
435 
436 
440  bool get_show_browse_view() const {
441  const Json::Value& storage = Storage("showBrowseView");
442  return client::JsonValueToCppValueHelper<bool >(storage);
443  }
444 
452  void set_show_browse_view(bool value) {
453  client::SetJsonValueFromCppValueHelper<bool >(
454  value, MutableStorage("showBrowseView"));
455  }
456 
463  return Storage().isMember("showRelatedChannels");
464  }
465 
470  MutableStorage()->removeMember("showRelatedChannels");
471  }
472 
473 
478  const Json::Value& storage = Storage("showRelatedChannels");
479  return client::JsonValueToCppValueHelper<bool >(storage);
480  }
481 
489  void set_show_related_channels(bool value) {
490  client::SetJsonValueFromCppValueHelper<bool >(
491  value, MutableStorage("showRelatedChannels"));
492  }
493 
499  bool has_title() const {
500  return Storage().isMember("title");
501  }
502 
506  void clear_title() {
507  MutableStorage()->removeMember("title");
508  }
509 
510 
514  const StringPiece get_title() const {
515  const Json::Value& v = Storage("title");
516  if (v == Json::Value::null) return StringPiece("");
517  return StringPiece(v.asCString());
518  }
519 
527  void set_title(const StringPiece& value) {
528  *MutableStorage("title") = value.data();
529  }
530 
539  return Storage().isMember("trackingAnalyticsAccountId");
540  }
541 
546  MutableStorage()->removeMember("trackingAnalyticsAccountId");
547  }
548 
549 
553  const StringPiece get_tracking_analytics_account_id() const {
554  const Json::Value& v = Storage("trackingAnalyticsAccountId");
555  if (v == Json::Value::null) return StringPiece("");
556  return StringPiece(v.asCString());
557  }
558 
567  void set_tracking_analytics_account_id(const StringPiece& value) {
568  *MutableStorage("trackingAnalyticsAccountId") = value.data();
569  }
570 
577  return Storage().isMember("unsubscribedTrailer");
578  }
579 
584  MutableStorage()->removeMember("unsubscribedTrailer");
585  }
586 
587 
591  const StringPiece get_unsubscribed_trailer() const {
592  const Json::Value& v = Storage("unsubscribedTrailer");
593  if (v == Json::Value::null) return StringPiece("");
594  return StringPiece(v.asCString());
595  }
596 
604  void set_unsubscribed_trailer(const StringPiece& value) {
605  *MutableStorage("unsubscribedTrailer") = value.data();
606  }
607 
608  private:
609  void operator=(const ChannelSettings&);
610 }; // ChannelSettings
611 } // namespace google_youtube_api
612 #endif // GOOGLE_YOUTUBE_API_CHANNEL_SETTINGS_H_
const StringPiece get_keywords() const
Definition: channel_settings.h:328
bool has_featured_channels_title() const
Definition: channel_settings.h:237
void set_keywords(const StringPiece &value)
Definition: channel_settings.h:341
Definition: access_policy.cc:40
const StringPiece get_title() const
Definition: channel_settings.h:514
bool has_featured_channels_urls() const
Definition: channel_settings.h:274
void clear_unsubscribed_trailer()
Definition: channel_settings.h:583
void clear_title()
Definition: channel_settings.h:506
const StringPiece get_description() const
Definition: channel_settings.h:215
void clear_tracking_analytics_account_id()
Definition: channel_settings.h:545
client::JsonCppArray< string > mutable_featuredChannelsUrls()
Definition: channel_settings.h:303
void set_tracking_analytics_account_id(const StringPiece &value)
Definition: channel_settings.h:567
const StringPiece GetTypeName() const
Definition: channel_settings.h:83
void clear_default_tab()
Definition: channel_settings.h:170
bool has_profile_color() const
Definition: channel_settings.h:388
void set_default_tab(const StringPiece &value)
Definition: channel_settings.h:191
bool has_title() const
Definition: channel_settings.h:499
Definition: channel_settings.h:50
bool has_show_related_channels() const
Definition: channel_settings.h:462
void set_country(const StringPiece &value)
Definition: channel_settings.h:120
void clear_profile_color()
Definition: channel_settings.h:395
const StringPiece get_featured_channels_title() const
Definition: channel_settings.h:252
void set_show_browse_view(bool value)
Definition: channel_settings.h:452
void set_moderate_comments(bool value)
Definition: channel_settings.h:378
const StringPiece get_tracking_analytics_account_id() const
Definition: channel_settings.h:553
void clear_default_language()
Definition: channel_settings.h:136
void set_description(const StringPiece &value)
Definition: channel_settings.h:228
bool has_show_browse_view() const
Definition: channel_settings.h:425
bool has_description() const
Definition: channel_settings.h:200
void clear_show_related_channels()
Definition: channel_settings.h:469
void clear_featured_channels_title()
Definition: channel_settings.h:244
void clear_moderate_comments()
Definition: channel_settings.h:357
bool get_moderate_comments() const
Definition: channel_settings.h:365
const StringPiece get_profile_color() const
Definition: channel_settings.h:403
void clear_featured_channels_urls()
Definition: channel_settings.h:281
bool get_show_related_channels() const
Definition: channel_settings.h:477
bool has_default_language() const
Definition: channel_settings.h:129
Definition: access_policy.h:38
void clear_keywords()
Definition: channel_settings.h:320
void set_show_related_channels(bool value)
Definition: channel_settings.h:489
void set_title(const StringPiece &value)
Definition: channel_settings.h:527
bool has_country() const
Definition: channel_settings.h:92
bool has_default_tab() const
Definition: channel_settings.h:163
bool has_tracking_analytics_account_id() const
Definition: channel_settings.h:538
bool has_keywords() const
Definition: channel_settings.h:313
void clear_show_browse_view()
Definition: channel_settings.h:432
void clear_description()
Definition: channel_settings.h:207
void set_unsubscribed_trailer(const StringPiece &value)
Definition: channel_settings.h:604
const client::JsonCppArray< string > get_featured_channels_urls() const
Definition: channel_settings.h:290
void set_featured_channels_title(const StringPiece &value)
Definition: channel_settings.h:265
void set_default_language(const StringPiece &value)
Definition: channel_settings.h:154
bool get_show_browse_view() const
Definition: channel_settings.h:440
const StringPiece get_unsubscribed_trailer() const
Definition: channel_settings.h:591
const StringPiece get_default_language() const
Definition: channel_settings.h:144
const StringPiece get_default_tab() const
Definition: channel_settings.h:178
bool has_unsubscribed_trailer() const
Definition: channel_settings.h:576
void clear_country()
Definition: channel_settings.h:99
const StringPiece get_country() const
Definition: channel_settings.h:107
void set_profile_color(const StringPiece &value)
Definition: channel_settings.h:416
bool has_moderate_comments() const
Definition: channel_settings.h:350