deploymentmanager  v2
condition.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: 2019-03-20, 05:04:30 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 Deployment Manager API (deploymentmanager/v2)
24 // Generated from:
25 // Version: v2
26 // Revision: 71
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_DEPLOYMENTMANAGER_API_CONDITION_H_
31 #define GOOGLE_DEPLOYMENTMANAGER_API_CONDITION_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 
43 using namespace googleapis;
44 
50 class Condition : public client::JsonCppData {
51  public:
57  static Condition* New();
58 
64  explicit Condition(const Json::Value& storage);
65 
71  explicit Condition(Json::Value* storage);
72 
76  virtual ~Condition();
77 
83  const StringPiece GetTypeName() const {
84  return StringPiece("google_deploymentmanager_api::Condition");
85  }
86 
92  bool has_iam() const {
93  return Storage().isMember("iam");
94  }
95 
99  void clear_iam() {
100  MutableStorage()->removeMember("iam");
101  }
102 
103 
107  const StringPiece get_iam() const {
108  const Json::Value& v = Storage("iam");
109  if (v == Json::Value::null) return StringPiece("");
110  return StringPiece(v.asCString());
111  }
112 
120  void set_iam(const StringPiece& value) {
121  *MutableStorage("iam") = value.data();
122  }
123 
129  bool has_op() const {
130  return Storage().isMember("op");
131  }
132 
136  void clear_op() {
137  MutableStorage()->removeMember("op");
138  }
139 
140 
144  const StringPiece get_op() const {
145  const Json::Value& v = Storage("op");
146  if (v == Json::Value::null) return StringPiece("");
147  return StringPiece(v.asCString());
148  }
149 
157  void set_op(const StringPiece& value) {
158  *MutableStorage("op") = value.data();
159  }
160 
166  bool has_svc() const {
167  return Storage().isMember("svc");
168  }
169 
173  void clear_svc() {
174  MutableStorage()->removeMember("svc");
175  }
176 
177 
181  const StringPiece get_svc() const {
182  const Json::Value& v = Storage("svc");
183  if (v == Json::Value::null) return StringPiece("");
184  return StringPiece(v.asCString());
185  }
186 
194  void set_svc(const StringPiece& value) {
195  *MutableStorage("svc") = value.data();
196  }
197 
203  bool has_sys() const {
204  return Storage().isMember("sys");
205  }
206 
210  void clear_sys() {
211  MutableStorage()->removeMember("sys");
212  }
213 
214 
218  const StringPiece get_sys() const {
219  const Json::Value& v = Storage("sys");
220  if (v == Json::Value::null) return StringPiece("");
221  return StringPiece(v.asCString());
222  }
223 
232  void set_sys(const StringPiece& value) {
233  *MutableStorage("sys") = value.data();
234  }
235 
241  bool has_value() const {
242  return Storage().isMember("value");
243  }
244 
248  void clear_value() {
249  MutableStorage()->removeMember("value");
250  }
251 
252 
256  const StringPiece get_value() const {
257  const Json::Value& v = Storage("value");
258  if (v == Json::Value::null) return StringPiece("");
259  return StringPiece(v.asCString());
260  }
261 
271  void set_value(const StringPiece& value) {
272  *MutableStorage("value") = value.data();
273  }
274 
280  bool has_values() const {
281  return Storage().isMember("values");
282  }
283 
287  void clear_values() {
288  MutableStorage()->removeMember("values");
289  }
290 
291 
295  const client::JsonCppArray<string > get_values() const {
296  const Json::Value& storage = Storage("values");
297  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
298  }
299 
307  client::JsonCppArray<string > mutable_values() {
308  Json::Value* storage = MutableStorage("values");
309  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
310  }
311 
312  private:
313  void operator=(const Condition&);
314 }; // Condition
315 } // namespace google_deploymentmanager_api
316 #endif // GOOGLE_DEPLOYMENTMANAGER_API_CONDITION_H_
void clear_iam()
Definition: condition.h:99
void set_iam(const StringPiece &value)
Definition: condition.h:120
bool has_values() const
Definition: condition.h:280
void set_op(const StringPiece &value)
Definition: condition.h:157
void set_svc(const StringPiece &value)
Definition: condition.h:194
const StringPiece get_value() const
Definition: condition.h:256
const client::JsonCppArray< string > get_values() const
Definition: condition.h:295
bool has_iam() const
Definition: condition.h:92
void clear_value()
Definition: condition.h:248
bool has_value() const
Definition: condition.h:241
void set_value(const StringPiece &value)
Definition: condition.h:271
const StringPiece get_svc() const
Definition: condition.h:181
Definition: condition.h:50
const StringPiece GetTypeName() const
Definition: condition.h:83
const StringPiece get_sys() const
Definition: condition.h:218
Definition: audit_config.h:40
bool has_op() const
Definition: condition.h:129
void clear_op()
Definition: condition.h:136
bool has_svc() const
Definition: condition.h:166
Definition: audit_config.cc:42
const StringPiece get_iam() const
Definition: condition.h:107
client::JsonCppArray< string > mutable_values()
Definition: condition.h:307
const StringPiece get_op() const
Definition: condition.h:144
bool has_sys() const
Definition: condition.h:203
void clear_sys()
Definition: condition.h:210
void clear_svc()
Definition: condition.h:173
void clear_values()
Definition: condition.h:287
void set_sys(const StringPiece &value)
Definition: condition.h:232