analytics  v3
custom_data_source.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-01-30, 05:27:32 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // Google Analytics API (analytics/v3)
24 // Generated from:
25 // Version: v3
26 // Revision: 169
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_ANALYTICS_API_CUSTOM_DATA_SOURCE_H_
31 #define GOOGLE_ANALYTICS_API_CUSTOM_DATA_SOURCE_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 namespace Json {
40 class Value;
41 } // namespace Json
42 
43 namespace google_analytics_api {
44 using namespace googleapis;
45 
51 class CustomDataSource : public client::JsonCppData {
52  public:
58  class CustomDataSourceChildLink : public client::JsonCppData {
59  public:
65  static CustomDataSourceChildLink* New();
66 
72  explicit CustomDataSourceChildLink(const Json::Value& storage);
73 
79  explicit CustomDataSourceChildLink(Json::Value* storage);
80 
84  virtual ~CustomDataSourceChildLink();
85 
91  const StringPiece GetTypeName() const {
92  return StringPiece("google_analytics_api::CustomDataSourceChildLink");
93  }
94 
100  bool has_href() const {
101  return Storage().isMember("href");
102  }
103 
107  void clear_href() {
108  MutableStorage()->removeMember("href");
109  }
110 
111 
115  const StringPiece get_href() const {
116  const Json::Value& v = Storage("href");
117  if (v == Json::Value::null) return StringPiece("");
118  return StringPiece(v.asCString());
119  }
120 
129  void set_href(const StringPiece& value) {
130  *MutableStorage("href") = value.data();
131  }
132 
138  bool has_type() const {
139  return Storage().isMember("type");
140  }
141 
145  void clear_type() {
146  MutableStorage()->removeMember("type");
147  }
148 
149 
153  const StringPiece get_type() const {
154  const Json::Value& v = Storage("type");
155  if (v == Json::Value::null) return StringPiece("");
156  return StringPiece(v.asCString());
157  }
158 
166  void set_type(const StringPiece& value) {
167  *MutableStorage("type") = value.data();
168  }
169 
170  private:
171  void operator=(const CustomDataSourceChildLink&);
172  }; // CustomDataSourceChildLink
179  class CustomDataSourceParentLink : public client::JsonCppData {
180  public:
186  static CustomDataSourceParentLink* New();
187 
193  explicit CustomDataSourceParentLink(const Json::Value& storage);
194 
200  explicit CustomDataSourceParentLink(Json::Value* storage);
201 
205  virtual ~CustomDataSourceParentLink();
206 
212  const StringPiece GetTypeName() const {
213  return StringPiece("google_analytics_api::CustomDataSourceParentLink");
214  }
215 
221  bool has_href() const {
222  return Storage().isMember("href");
223  }
224 
228  void clear_href() {
229  MutableStorage()->removeMember("href");
230  }
231 
232 
236  const StringPiece get_href() const {
237  const Json::Value& v = Storage("href");
238  if (v == Json::Value::null) return StringPiece("");
239  return StringPiece(v.asCString());
240  }
241 
249  void set_href(const StringPiece& value) {
250  *MutableStorage("href") = value.data();
251  }
252 
258  bool has_type() const {
259  return Storage().isMember("type");
260  }
261 
265  void clear_type() {
266  MutableStorage()->removeMember("type");
267  }
268 
269 
273  const StringPiece get_type() const {
274  const Json::Value& v = Storage("type");
275  if (v == Json::Value::null) return StringPiece("");
276  return StringPiece(v.asCString());
277  }
278 
286  void set_type(const StringPiece& value) {
287  *MutableStorage("type") = value.data();
288  }
289 
290  private:
291  void operator=(const CustomDataSourceParentLink&);
292  }; // CustomDataSourceParentLink
298  static CustomDataSource* New();
299 
305  explicit CustomDataSource(const Json::Value& storage);
306 
312  explicit CustomDataSource(Json::Value* storage);
313 
317  virtual ~CustomDataSource();
318 
324  const StringPiece GetTypeName() const {
325  return StringPiece("google_analytics_api::CustomDataSource");
326  }
327 
333  bool has_account_id() const {
334  return Storage().isMember("accountId");
335  }
336 
341  MutableStorage()->removeMember("accountId");
342  }
343 
344 
348  const StringPiece get_account_id() const {
349  const Json::Value& v = Storage("accountId");
350  if (v == Json::Value::null) return StringPiece("");
351  return StringPiece(v.asCString());
352  }
353 
361  void set_account_id(const StringPiece& value) {
362  *MutableStorage("accountId") = value.data();
363  }
364 
370  bool has_child_link() const {
371  return Storage().isMember("childLink");
372  }
373 
378  MutableStorage()->removeMember("childLink");
379  }
380 
381 
386  const Json::Value& storage = Storage("childLink");
387  return client::JsonValueToCppValueHelper<CustomDataSourceChildLink >(storage);
388  }
389 
396  Json::Value* storage = MutableStorage("childLink");
397  return client::JsonValueToMutableCppValueHelper<CustomDataSourceChildLink >(storage);
398  }
399 
405  bool has_created() const {
406  return Storage().isMember("created");
407  }
408 
412  void clear_created() {
413  MutableStorage()->removeMember("created");
414  }
415 
416 
420  client::DateTime get_created() const {
421  const Json::Value& storage = Storage("created");
422  return client::JsonValueToCppValueHelper<client::DateTime >(storage);
423  }
424 
432  void set_created(client::DateTime value) {
433  client::SetJsonValueFromCppValueHelper<client::DateTime >(
434  value, MutableStorage("created"));
435  }
436 
442  bool has_description() const {
443  return Storage().isMember("description");
444  }
445 
450  MutableStorage()->removeMember("description");
451  }
452 
453 
457  const StringPiece get_description() const {
458  const Json::Value& v = Storage("description");
459  if (v == Json::Value::null) return StringPiece("");
460  return StringPiece(v.asCString());
461  }
462 
470  void set_description(const StringPiece& value) {
471  *MutableStorage("description") = value.data();
472  }
473 
479  bool has_id() const {
480  return Storage().isMember("id");
481  }
482 
486  void clear_id() {
487  MutableStorage()->removeMember("id");
488  }
489 
490 
494  const StringPiece get_id() const {
495  const Json::Value& v = Storage("id");
496  if (v == Json::Value::null) return StringPiece("");
497  return StringPiece(v.asCString());
498  }
499 
507  void set_id(const StringPiece& value) {
508  *MutableStorage("id") = value.data();
509  }
510 
516  bool has_import_behavior() const {
517  return Storage().isMember("importBehavior");
518  }
519 
524  MutableStorage()->removeMember("importBehavior");
525  }
526 
527 
531  const StringPiece get_import_behavior() const {
532  const Json::Value& v = Storage("importBehavior");
533  if (v == Json::Value::null) return StringPiece("");
534  return StringPiece(v.asCString());
535  }
536 
541  void set_import_behavior(const StringPiece& value) {
542  *MutableStorage("importBehavior") = value.data();
543  }
544 
550  bool has_kind() const {
551  return Storage().isMember("kind");
552  }
553 
557  void clear_kind() {
558  MutableStorage()->removeMember("kind");
559  }
560 
561 
565  const StringPiece get_kind() const {
566  const Json::Value& v = Storage("kind");
567  if (v == Json::Value::null) return StringPiece("");
568  return StringPiece(v.asCString());
569  }
570 
578  void set_kind(const StringPiece& value) {
579  *MutableStorage("kind") = value.data();
580  }
581 
587  bool has_name() const {
588  return Storage().isMember("name");
589  }
590 
594  void clear_name() {
595  MutableStorage()->removeMember("name");
596  }
597 
598 
602  const StringPiece get_name() const {
603  const Json::Value& v = Storage("name");
604  if (v == Json::Value::null) return StringPiece("");
605  return StringPiece(v.asCString());
606  }
607 
615  void set_name(const StringPiece& value) {
616  *MutableStorage("name") = value.data();
617  }
618 
624  bool has_parent_link() const {
625  return Storage().isMember("parentLink");
626  }
627 
632  MutableStorage()->removeMember("parentLink");
633  }
634 
635 
640  const Json::Value& storage = Storage("parentLink");
641  return client::JsonValueToCppValueHelper<CustomDataSourceParentLink >(storage);
642  }
643 
654  Json::Value* storage = MutableStorage("parentLink");
655  return client::JsonValueToMutableCppValueHelper<CustomDataSourceParentLink >(storage);
656  }
657 
663  bool has_profiles_linked() const {
664  return Storage().isMember("profilesLinked");
665  }
666 
671  MutableStorage()->removeMember("profilesLinked");
672  }
673 
674 
679  const client::JsonCppArray<string > get_profiles_linked() const {
680  const Json::Value& storage = Storage("profilesLinked");
681  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
682  }
683 
692  client::JsonCppArray<string > mutable_profilesLinked() {
693  Json::Value* storage = MutableStorage("profilesLinked");
694  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
695  }
696 
702  bool has_schema() const {
703  return Storage().isMember("schema");
704  }
705 
709  void clear_schema() {
710  MutableStorage()->removeMember("schema");
711  }
712 
713 
717  const client::JsonCppArray<string > get_schema() const {
718  const Json::Value& storage = Storage("schema");
719  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
720  }
721 
729  client::JsonCppArray<string > mutable_schema() {
730  Json::Value* storage = MutableStorage("schema");
731  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
732  }
733 
739  bool has_self_link() const {
740  return Storage().isMember("selfLink");
741  }
742 
747  MutableStorage()->removeMember("selfLink");
748  }
749 
750 
754  const StringPiece get_self_link() const {
755  const Json::Value& v = Storage("selfLink");
756  if (v == Json::Value::null) return StringPiece("");
757  return StringPiece(v.asCString());
758  }
759 
767  void set_self_link(const StringPiece& value) {
768  *MutableStorage("selfLink") = value.data();
769  }
770 
776  bool has_type() const {
777  return Storage().isMember("type");
778  }
779 
783  void clear_type() {
784  MutableStorage()->removeMember("type");
785  }
786 
787 
791  const StringPiece get_type() const {
792  const Json::Value& v = Storage("type");
793  if (v == Json::Value::null) return StringPiece("");
794  return StringPiece(v.asCString());
795  }
796 
804  void set_type(const StringPiece& value) {
805  *MutableStorage("type") = value.data();
806  }
807 
813  bool has_updated() const {
814  return Storage().isMember("updated");
815  }
816 
820  void clear_updated() {
821  MutableStorage()->removeMember("updated");
822  }
823 
824 
828  client::DateTime get_updated() const {
829  const Json::Value& storage = Storage("updated");
830  return client::JsonValueToCppValueHelper<client::DateTime >(storage);
831  }
832 
840  void set_updated(client::DateTime value) {
841  client::SetJsonValueFromCppValueHelper<client::DateTime >(
842  value, MutableStorage("updated"));
843  }
844 
850  bool has_upload_type() const {
851  return Storage().isMember("uploadType");
852  }
853 
858  MutableStorage()->removeMember("uploadType");
859  }
860 
861 
865  const StringPiece get_upload_type() const {
866  const Json::Value& v = Storage("uploadType");
867  if (v == Json::Value::null) return StringPiece("");
868  return StringPiece(v.asCString());
869  }
870 
878  void set_upload_type(const StringPiece& value) {
879  *MutableStorage("uploadType") = value.data();
880  }
881 
887  bool has_web_property_id() const {
888  return Storage().isMember("webPropertyId");
889  }
890 
895  MutableStorage()->removeMember("webPropertyId");
896  }
897 
898 
902  const StringPiece get_web_property_id() const {
903  const Json::Value& v = Storage("webPropertyId");
904  if (v == Json::Value::null) return StringPiece("");
905  return StringPiece(v.asCString());
906  }
907 
916  void set_web_property_id(const StringPiece& value) {
917  *MutableStorage("webPropertyId") = value.data();
918  }
919 
920  private:
921  void operator=(const CustomDataSource&);
922 }; // CustomDataSource
923 } // namespace google_analytics_api
924 #endif // GOOGLE_ANALYTICS_API_CUSTOM_DATA_SOURCE_H_
void clear_kind()
Definition: custom_data_source.h:557
void clear_web_property_id()
Definition: custom_data_source.h:894
bool has_type() const
Definition: custom_data_source.h:776
bool has_id() const
Definition: custom_data_source.h:479
void set_type(const StringPiece &value)
Definition: custom_data_source.h:804
void clear_self_link()
Definition: custom_data_source.h:746
void set_description(const StringPiece &value)
Definition: custom_data_source.h:470
const CustomDataSourceChildLink get_child_link() const
Definition: custom_data_source.h:385
const StringPiece get_upload_type() const
Definition: custom_data_source.h:865
void set_import_behavior(const StringPiece &value)
Definition: custom_data_source.h:541
void clear_child_link()
Definition: custom_data_source.h:377
client::DateTime get_updated() const
Definition: custom_data_source.h:828
void set_self_link(const StringPiece &value)
Definition: custom_data_source.h:767
Definition: custom_data_source.h:51
const CustomDataSourceParentLink get_parent_link() const
Definition: custom_data_source.h:639
bool has_account_id() const
Definition: custom_data_source.h:333
bool has_updated() const
Definition: custom_data_source.h:813
void set_name(const StringPiece &value)
Definition: custom_data_source.h:615
client::DateTime get_created() const
Definition: custom_data_source.h:420
void clear_type()
Definition: custom_data_source.h:783
const client::JsonCppArray< string > get_profiles_linked() const
Definition: custom_data_source.h:679
bool has_child_link() const
Definition: custom_data_source.h:370
const StringPiece get_type() const
Definition: custom_data_source.h:791
client::JsonCppArray< string > mutable_schema()
Definition: custom_data_source.h:729
void clear_profiles_linked()
Definition: custom_data_source.h:670
bool has_import_behavior() const
Definition: custom_data_source.h:516
void clear_updated()
Definition: custom_data_source.h:820
void clear_description()
Definition: custom_data_source.h:449
bool has_parent_link() const
Definition: custom_data_source.h:624
const StringPiece get_id() const
Definition: custom_data_source.h:494
bool has_schema() const
Definition: custom_data_source.h:702
CustomDataSourceParentLink mutable_parentLink()
Definition: custom_data_source.h:653
const StringPiece get_kind() const
Definition: custom_data_source.h:565
void set_web_property_id(const StringPiece &value)
Definition: custom_data_source.h:916
void clear_created()
Definition: custom_data_source.h:412
Definition: account.h:39
bool has_name() const
Definition: custom_data_source.h:587
bool has_profiles_linked() const
Definition: custom_data_source.h:663
const StringPiece get_self_link() const
Definition: custom_data_source.h:754
bool has_description() const
Definition: custom_data_source.h:442
Definition: account.cc:41
void set_account_id(const StringPiece &value)
Definition: custom_data_source.h:361
const StringPiece get_import_behavior() const
Definition: custom_data_source.h:531
CustomDataSourceChildLink mutable_childLink()
Definition: custom_data_source.h:395
bool has_created() const
Definition: custom_data_source.h:405
bool has_self_link() const
Definition: custom_data_source.h:739
void set_kind(const StringPiece &value)
Definition: custom_data_source.h:578
void clear_upload_type()
Definition: custom_data_source.h:857
void clear_schema()
Definition: custom_data_source.h:709
const StringPiece GetTypeName() const
Definition: custom_data_source.h:324
const StringPiece get_description() const
Definition: custom_data_source.h:457
bool has_upload_type() const
Definition: custom_data_source.h:850
bool has_kind() const
Definition: custom_data_source.h:550
void clear_account_id()
Definition: custom_data_source.h:340
void clear_name()
Definition: custom_data_source.h:594
void set_id(const StringPiece &value)
Definition: custom_data_source.h:507
void clear_id()
Definition: custom_data_source.h:486
void set_upload_type(const StringPiece &value)
Definition: custom_data_source.h:878
void clear_parent_link()
Definition: custom_data_source.h:631
void set_updated(client::DateTime value)
Definition: custom_data_source.h:840
const client::JsonCppArray< string > get_schema() const
Definition: custom_data_source.h:717
client::JsonCppArray< string > mutable_profilesLinked()
Definition: custom_data_source.h:692
void clear_import_behavior()
Definition: custom_data_source.h:523
void set_created(client::DateTime value)
Definition: custom_data_source.h:432
const StringPiece get_account_id() const
Definition: custom_data_source.h:348
const StringPiece get_web_property_id() const
Definition: custom_data_source.h:902
const StringPiece get_name() const
Definition: custom_data_source.h:602
bool has_web_property_id() const
Definition: custom_data_source.h:887