dns  v1
project.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-29, 22:13:38 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 Cloud DNS API (dns/v1)
24 // Generated from:
25 // Version: v1
26 // Revision: 112
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_DNS_API_PROJECT_H_
31 #define GOOGLE_DNS_API_PROJECT_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/strings/stringpiece.h"
38 
39 #include "google/dns_api/quota.h"
40 
41 namespace Json {
42 class Value;
43 } // namespace Json
44 
45 namespace google_dns_api {
46 using namespace googleapis;
47 
55 class Project : public client::JsonCppData {
56  public:
62  static Project* New();
63 
69  explicit Project(const Json::Value& storage);
70 
76  explicit Project(Json::Value* storage);
77 
81  virtual ~Project();
82 
88  const StringPiece GetTypeName() const {
89  return StringPiece("google_dns_api::Project");
90  }
91 
97  bool has_id() const {
98  return Storage().isMember("id");
99  }
100 
104  void clear_id() {
105  MutableStorage()->removeMember("id");
106  }
107 
108 
112  const StringPiece get_id() const {
113  const Json::Value& v = Storage("id");
114  if (v == Json::Value::null) return StringPiece("");
115  return StringPiece(v.asCString());
116  }
117 
125  void set_id(const StringPiece& value) {
126  *MutableStorage("id") = value.data();
127  }
128 
134  bool has_kind() const {
135  return Storage().isMember("kind");
136  }
137 
141  void clear_kind() {
142  MutableStorage()->removeMember("kind");
143  }
144 
145 
149  const StringPiece get_kind() const {
150  const Json::Value& v = Storage("kind");
151  if (v == Json::Value::null) return StringPiece("");
152  return StringPiece(v.asCString());
153  }
154 
163  void set_kind(const StringPiece& value) {
164  *MutableStorage("kind") = value.data();
165  }
166 
172  bool has_number() const {
173  return Storage().isMember("number");
174  }
175 
179  void clear_number() {
180  MutableStorage()->removeMember("number");
181  }
182 
183 
187  uint64 get_number() const {
188  const Json::Value& storage = Storage("number");
189  return client::JsonValueToCppValueHelper<uint64 >(storage);
190  }
191 
200  void set_number(uint64 value) {
201  client::SetJsonValueFromCppValueHelper<uint64 >(
202  value, MutableStorage("number"));
203  }
204 
210  bool has_quota() const {
211  return Storage().isMember("quota");
212  }
213 
217  void clear_quota() {
218  MutableStorage()->removeMember("quota");
219  }
220 
221 
225  const Quota get_quota() const;
226 
234  Quota mutable_quota();
235 
236  private:
237  void operator=(const Project&);
238 }; // Project
239 } // namespace google_dns_api
240 #endif // GOOGLE_DNS_API_PROJECT_H_
void set_id(const StringPiece &value)
Definition: project.h:125
const StringPiece GetTypeName() const
Definition: project.h:88
const StringPiece get_id() const
Definition: project.h:112
void clear_id()
Definition: project.h:104
void set_kind(const StringPiece &value)
Definition: project.h:163
uint64 get_number() const
Definition: project.h:187
bool has_id() const
Definition: project.h:97
void clear_number()
Definition: project.h:179
const StringPiece get_kind() const
Definition: project.h:149
bool has_number() const
Definition: project.h:172
Definition: project.h:55
Definition: change.h:40
Definition: quota.h:53
void set_number(uint64 value)
Definition: project.h:200
void clear_kind()
Definition: project.h:141
Definition: change.cc:42
void clear_quota()
Definition: project.h:217
bool has_kind() const
Definition: project.h:134
bool has_quota() const
Definition: project.h:210