container  v1
autoprovisioning_node_pool_defaults.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-07, 01:20:42 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // Kubernetes Engine API (container/v1)
24 // Generated from:
25 // Version: v1
26 // Revision: 93
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_CONTAINER_API_AUTOPROVISIONING_NODE_POOL_DEFAULTS_H_
31 #define GOOGLE_CONTAINER_API_AUTOPROVISIONING_NODE_POOL_DEFAULTS_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/container_api/node_management.h"
39 #include "google/container_api/upgrade_settings.h"
40 
41 namespace Json {
42 class Value;
43 } // namespace Json
44 
45 namespace google_container_api {
46 using namespace googleapis;
47 
54 class AutoprovisioningNodePoolDefaults : public client::JsonCppData {
55  public:
62 
68  explicit AutoprovisioningNodePoolDefaults(const Json::Value& storage);
69 
75  explicit AutoprovisioningNodePoolDefaults(Json::Value* storage);
76 
81 
87  const StringPiece GetTypeName() const {
88  return StringPiece("google_container_api::AutoprovisioningNodePoolDefaults");
89  }
90 
96  bool has_management() const {
97  return Storage().isMember("management");
98  }
99 
104  MutableStorage()->removeMember("management");
105  }
106 
107 
111  const NodeManagement get_management() const;
112 
121  NodeManagement mutable_management();
122 
128  bool has_oauth_scopes() const {
129  return Storage().isMember("oauthScopes");
130  }
131 
136  MutableStorage()->removeMember("oauthScopes");
137  }
138 
139 
143  const client::JsonCppArray<string > get_oauth_scopes() const {
144  const Json::Value& storage = Storage("oauthScopes");
145  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
146  }
147 
157  client::JsonCppArray<string > mutable_oauthScopes() {
158  Json::Value* storage = MutableStorage("oauthScopes");
159  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
160  }
161 
167  bool has_service_account() const {
168  return Storage().isMember("serviceAccount");
169  }
170 
175  MutableStorage()->removeMember("serviceAccount");
176  }
177 
178 
182  const StringPiece get_service_account() const {
183  const Json::Value& v = Storage("serviceAccount");
184  if (v == Json::Value::null) return StringPiece("");
185  return StringPiece(v.asCString());
186  }
187 
196  void set_service_account(const StringPiece& value) {
197  *MutableStorage("serviceAccount") = value.data();
198  }
199 
205  bool has_upgrade_settings() const {
206  return Storage().isMember("upgradeSettings");
207  }
208 
213  MutableStorage()->removeMember("upgradeSettings");
214  }
215 
216 
221  const UpgradeSettings get_upgrade_settings() const;
222 
231  UpgradeSettings mutable_upgradeSettings();
232 
233  private:
234  void operator=(const AutoprovisioningNodePoolDefaults&);
235 }; // AutoprovisioningNodePoolDefaults
236 } // namespace google_container_api
237 #endif // GOOGLE_CONTAINER_API_AUTOPROVISIONING_NODE_POOL_DEFAULTS_H_
bool has_upgrade_settings() const
Definition: autoprovisioning_node_pool_defaults.h:205
void clear_upgrade_settings()
Definition: autoprovisioning_node_pool_defaults.h:212
void clear_oauth_scopes()
Definition: autoprovisioning_node_pool_defaults.h:135
client::JsonCppArray< string > mutable_oauthScopes()
Definition: autoprovisioning_node_pool_defaults.h:157
const StringPiece GetTypeName() const
Definition: autoprovisioning_node_pool_defaults.h:87
Definition: upgrade_settings.h:72
Definition: autoprovisioning_node_pool_defaults.h:54
bool has_oauth_scopes() const
Definition: autoprovisioning_node_pool_defaults.h:128
bool has_management() const
Definition: autoprovisioning_node_pool_defaults.h:96
Definition: accelerator_config.h:39
void clear_management()
Definition: autoprovisioning_node_pool_defaults.h:103
Definition: accelerator_config.cc:41
bool has_service_account() const
Definition: autoprovisioning_node_pool_defaults.h:167
void clear_service_account()
Definition: autoprovisioning_node_pool_defaults.h:174
Definition: node_management.h:52
void set_service_account(const StringPiece &value)
Definition: autoprovisioning_node_pool_defaults.h:196
const client::JsonCppArray< string > get_oauth_scopes() const
Definition: autoprovisioning_node_pool_defaults.h:143
const StringPiece get_service_account() const
Definition: autoprovisioning_node_pool_defaults.h:182