deploymentmanager  v2
audit_config.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_AUDIT_CONFIG_H_
31 #define GOOGLE_DEPLOYMENTMANAGER_API_AUDIT_CONFIG_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/deploymentmanager_api/audit_log_config.h"
39 
40 namespace Json {
41 class Value;
42 } // namespace Json
43 
45 using namespace googleapis;
46 
72 class AuditConfig : public client::JsonCppData {
73  public:
79  static AuditConfig* New();
80 
86  explicit AuditConfig(const Json::Value& storage);
87 
93  explicit AuditConfig(Json::Value* storage);
94 
98  virtual ~AuditConfig();
99 
105  const StringPiece GetTypeName() const {
106  return StringPiece("google_deploymentmanager_api::AuditConfig");
107  }
108 
114  bool has_audit_log_configs() const {
115  return Storage().isMember("auditLogConfigs");
116  }
117 
122  MutableStorage()->removeMember("auditLogConfigs");
123  }
124 
125 
130  const client::JsonCppArray<AuditLogConfig > get_audit_log_configs() const;
131 
140  client::JsonCppArray<AuditLogConfig > mutable_auditLogConfigs();
141 
147  bool has_exempted_members() const {
148  return Storage().isMember("exemptedMembers");
149  }
150 
155  MutableStorage()->removeMember("exemptedMembers");
156  }
157 
158 
163  const client::JsonCppArray<string > get_exempted_members() const {
164  const Json::Value& storage = Storage("exemptedMembers");
165  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
166  }
167 
173  client::JsonCppArray<string > mutable_exemptedMembers() {
174  Json::Value* storage = MutableStorage("exemptedMembers");
175  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
176  }
177 
183  bool has_service() const {
184  return Storage().isMember("service");
185  }
186 
190  void clear_service() {
191  MutableStorage()->removeMember("service");
192  }
193 
194 
198  const StringPiece get_service() const {
199  const Json::Value& v = Storage("service");
200  if (v == Json::Value::null) return StringPiece("");
201  return StringPiece(v.asCString());
202  }
203 
213  void set_service(const StringPiece& value) {
214  *MutableStorage("service") = value.data();
215  }
216 
217  private:
218  void operator=(const AuditConfig&);
219 }; // AuditConfig
220 } // namespace google_deploymentmanager_api
221 #endif // GOOGLE_DEPLOYMENTMANAGER_API_AUDIT_CONFIG_H_
void clear_service()
Definition: audit_config.h:190
void clear_audit_log_configs()
Definition: audit_config.h:121
const StringPiece get_service() const
Definition: audit_config.h:198
void clear_exempted_members()
Definition: audit_config.h:154
bool has_service() const
Definition: audit_config.h:183
Definition: audit_config.h:40
const client::JsonCppArray< string > get_exempted_members() const
Definition: audit_config.h:163
client::JsonCppArray< string > mutable_exemptedMembers()
Definition: audit_config.h:173
const StringPiece GetTypeName() const
Definition: audit_config.h:105
bool has_audit_log_configs() const
Definition: audit_config.h:114
Definition: audit_config.cc:42
void set_service(const StringPiece &value)
Definition: audit_config.h:213
Definition: audit_config.h:72
bool has_exempted_members() const
Definition: audit_config.h:147