sqladmin  v1beta4
backup_configuration.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-06-11, 00:07:27 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // Cloud SQL Admin API (sqladmin/v1beta4)
24 // Generated from:
25 // Version: v1beta4
26 // Revision: 76
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_SQLADMIN_API_BACKUP_CONFIGURATION_H_
31 #define GOOGLE_SQLADMIN_API_BACKUP_CONFIGURATION_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 
42 namespace google_sqladmin_api {
43 using namespace googleapis;
44 
50 class BackupConfiguration : public client::JsonCppData {
51  public:
57  static BackupConfiguration* New();
58 
64  explicit BackupConfiguration(const Json::Value& storage);
65 
71  explicit BackupConfiguration(Json::Value* storage);
72 
76  virtual ~BackupConfiguration();
77 
83  const StringPiece GetTypeName() const {
84  return StringPiece("google_sqladmin_api::BackupConfiguration");
85  }
86 
92  bool has_binary_log_enabled() const {
93  return Storage().isMember("binaryLogEnabled");
94  }
95 
100  MutableStorage()->removeMember("binaryLogEnabled");
101  }
102 
103 
107  bool get_binary_log_enabled() const {
108  const Json::Value& storage = Storage("binaryLogEnabled");
109  return client::JsonValueToCppValueHelper<bool >(storage);
110  }
111 
120  void set_binary_log_enabled(bool value) {
121  client::SetJsonValueFromCppValueHelper<bool >(
122  value, MutableStorage("binaryLogEnabled"));
123  }
124 
130  bool has_enabled() const {
131  return Storage().isMember("enabled");
132  }
133 
137  void clear_enabled() {
138  MutableStorage()->removeMember("enabled");
139  }
140 
141 
145  bool get_enabled() const {
146  const Json::Value& storage = Storage("enabled");
147  return client::JsonValueToCppValueHelper<bool >(storage);
148  }
149 
157  void set_enabled(bool value) {
158  client::SetJsonValueFromCppValueHelper<bool >(
159  value, MutableStorage("enabled"));
160  }
161 
167  bool has_kind() const {
168  return Storage().isMember("kind");
169  }
170 
174  void clear_kind() {
175  MutableStorage()->removeMember("kind");
176  }
177 
178 
182  const StringPiece get_kind() const {
183  const Json::Value& v = Storage("kind");
184  if (v == Json::Value::null) return StringPiece("");
185  return StringPiece(v.asCString());
186  }
187 
195  void set_kind(const StringPiece& value) {
196  *MutableStorage("kind") = value.data();
197  }
198 
204  bool has_location() const {
205  return Storage().isMember("location");
206  }
207 
211  void clear_location() {
212  MutableStorage()->removeMember("location");
213  }
214 
215 
219  const StringPiece get_location() const {
220  const Json::Value& v = Storage("location");
221  if (v == Json::Value::null) return StringPiece("");
222  return StringPiece(v.asCString());
223  }
224 
232  void set_location(const StringPiece& value) {
233  *MutableStorage("location") = value.data();
234  }
235 
244  return Storage().isMember("replicationLogArchivingEnabled");
245  }
246 
251  MutableStorage()->removeMember("replicationLogArchivingEnabled");
252  }
253 
254 
260  const Json::Value& storage = Storage("replicationLogArchivingEnabled");
261  return client::JsonValueToCppValueHelper<bool >(storage);
262  }
263 
272  client::SetJsonValueFromCppValueHelper<bool >(
273  value, MutableStorage("replicationLogArchivingEnabled"));
274  }
275 
281  bool has_start_time() const {
282  return Storage().isMember("startTime");
283  }
284 
289  MutableStorage()->removeMember("startTime");
290  }
291 
292 
296  const StringPiece get_start_time() const {
297  const Json::Value& v = Storage("startTime");
298  if (v == Json::Value::null) return StringPiece("");
299  return StringPiece(v.asCString());
300  }
301 
310  void set_start_time(const StringPiece& value) {
311  *MutableStorage("startTime") = value.data();
312  }
313 
314  private:
315  void operator=(const BackupConfiguration&);
316 }; // BackupConfiguration
317 } // namespace google_sqladmin_api
318 #endif // GOOGLE_SQLADMIN_API_BACKUP_CONFIGURATION_H_
const StringPiece GetTypeName() const
Definition: backup_configuration.h:83
bool get_enabled() const
Definition: backup_configuration.h:145
const StringPiece get_location() const
Definition: backup_configuration.h:219
void clear_start_time()
Definition: backup_configuration.h:288
bool has_start_time() const
Definition: backup_configuration.h:281
void clear_replication_log_archiving_enabled()
Definition: backup_configuration.h:250
Definition: backup_configuration.h:50
void set_enabled(bool value)
Definition: backup_configuration.h:157
bool has_enabled() const
Definition: backup_configuration.h:130
void clear_location()
Definition: backup_configuration.h:211
bool has_kind() const
Definition: backup_configuration.h:167
void set_start_time(const StringPiece &value)
Definition: backup_configuration.h:310
void clear_enabled()
Definition: backup_configuration.h:137
bool get_binary_log_enabled() const
Definition: backup_configuration.h:107
bool has_binary_log_enabled() const
Definition: backup_configuration.h:92
void clear_binary_log_enabled()
Definition: backup_configuration.h:99
Definition: acl_entry.cc:41
Definition: acl_entry.h:39
void set_replication_log_archiving_enabled(bool value)
Definition: backup_configuration.h:271
bool has_location() const
Definition: backup_configuration.h:204
bool has_replication_log_archiving_enabled() const
Definition: backup_configuration.h:243
const StringPiece get_kind() const
Definition: backup_configuration.h:182
void set_binary_log_enabled(bool value)
Definition: backup_configuration.h:120
const StringPiece get_start_time() const
Definition: backup_configuration.h:296
bool get_replication_log_archiving_enabled() const
Definition: backup_configuration.h:259
void set_kind(const StringPiece &value)
Definition: backup_configuration.h:195
void clear_kind()
Definition: backup_configuration.h:174
void set_location(const StringPiece &value)
Definition: backup_configuration.h:232