bigquery  v2
job_configuration_extract.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, 23:51:40 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // BigQuery API (bigquery/v2)
24 // Generated from:
25 // Version: v2
26 // Revision: 459
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_BIGQUERY_API_JOB_CONFIGURATION_EXTRACT_H_
31 #define GOOGLE_BIGQUERY_API_JOB_CONFIGURATION_EXTRACT_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/bigquery_api/model_reference.h"
39 #include "google/bigquery_api/table_reference.h"
40 
41 namespace Json {
42 class Value;
43 } // namespace Json
44 
45 namespace google_bigquery_api {
46 using namespace googleapis;
47 
53 class JobConfigurationExtract : public client::JsonCppData {
54  public:
60  static JobConfigurationExtract* New();
61 
67  explicit JobConfigurationExtract(const Json::Value& storage);
68 
74  explicit JobConfigurationExtract(Json::Value* storage);
75 
79  virtual ~JobConfigurationExtract();
80 
86  const StringPiece GetTypeName() const {
87  return StringPiece("google_bigquery_api::JobConfigurationExtract");
88  }
89 
95  bool has_compression() const {
96  return Storage().isMember("compression");
97  }
98 
103  MutableStorage()->removeMember("compression");
104  }
105 
106 
110  const StringPiece get_compression() const {
111  const Json::Value& v = Storage("compression");
112  if (v == Json::Value::null) return StringPiece("");
113  return StringPiece(v.asCString());
114  }
115 
125  void set_compression(const StringPiece& value) {
126  *MutableStorage("compression") = value.data();
127  }
128 
134  bool has_destination_format() const {
135  return Storage().isMember("destinationFormat");
136  }
137 
142  MutableStorage()->removeMember("destinationFormat");
143  }
144 
145 
149  const StringPiece get_destination_format() const {
150  const Json::Value& v = Storage("destinationFormat");
151  if (v == Json::Value::null) return StringPiece("");
152  return StringPiece(v.asCString());
153  }
154 
164  void set_destination_format(const StringPiece& value) {
165  *MutableStorage("destinationFormat") = value.data();
166  }
167 
173  bool has_destination_uri() const {
174  return Storage().isMember("destinationUri");
175  }
176 
181  MutableStorage()->removeMember("destinationUri");
182  }
183 
184 
188  const StringPiece get_destination_uri() const {
189  const Json::Value& v = Storage("destinationUri");
190  if (v == Json::Value::null) return StringPiece("");
191  return StringPiece(v.asCString());
192  }
193 
203  void set_destination_uri(const StringPiece& value) {
204  *MutableStorage("destinationUri") = value.data();
205  }
206 
212  bool has_destination_uris() const {
213  return Storage().isMember("destinationUris");
214  }
215 
220  MutableStorage()->removeMember("destinationUris");
221  }
222 
223 
228  const client::JsonCppArray<string > get_destination_uris() const {
229  const Json::Value& storage = Storage("destinationUris");
230  return client::JsonValueToCppValueHelper<client::JsonCppArray<string > >(storage);
231  }
232 
242  client::JsonCppArray<string > mutable_destinationUris() {
243  Json::Value* storage = MutableStorage("destinationUris");
244  return client::JsonValueToMutableCppValueHelper<client::JsonCppArray<string > >(storage);
245  }
246 
252  bool has_field_delimiter() const {
253  return Storage().isMember("fieldDelimiter");
254  }
255 
260  MutableStorage()->removeMember("fieldDelimiter");
261  }
262 
263 
267  const StringPiece get_field_delimiter() const {
268  const Json::Value& v = Storage("fieldDelimiter");
269  if (v == Json::Value::null) return StringPiece("");
270  return StringPiece(v.asCString());
271  }
272 
281  void set_field_delimiter(const StringPiece& value) {
282  *MutableStorage("fieldDelimiter") = value.data();
283  }
284 
290  bool has_print_header() const {
291  return Storage().isMember("printHeader");
292  }
293 
298  MutableStorage()->removeMember("printHeader");
299  }
300 
301 
305  bool get_print_header() const {
306  const Json::Value& storage = Storage("printHeader");
307  return client::JsonValueToCppValueHelper<bool >(storage);
308  }
309 
318  void set_print_header(bool value) {
319  client::SetJsonValueFromCppValueHelper<bool >(
320  value, MutableStorage("printHeader"));
321  }
322 
328  bool has_source_model() const {
329  return Storage().isMember("sourceModel");
330  }
331 
336  MutableStorage()->removeMember("sourceModel");
337  }
338 
339 
343  const ModelReference get_source_model() const;
344 
353  ModelReference mutable_sourceModel();
354 
360  bool has_source_table() const {
361  return Storage().isMember("sourceTable");
362  }
363 
368  MutableStorage()->removeMember("sourceTable");
369  }
370 
371 
375  const TableReference get_source_table() const;
376 
385  TableReference mutable_sourceTable();
386 
393  return Storage().isMember("useAvroLogicalTypes");
394  }
395 
400  MutableStorage()->removeMember("useAvroLogicalTypes");
401  }
402 
403 
408  const Json::Value& storage = Storage("useAvroLogicalTypes");
409  return client::JsonValueToCppValueHelper<bool >(storage);
410  }
411 
422  void set_use_avro_logical_types(bool value) {
423  client::SetJsonValueFromCppValueHelper<bool >(
424  value, MutableStorage("useAvroLogicalTypes"));
425  }
426 
427  private:
428  void operator=(const JobConfigurationExtract&);
429 }; // JobConfigurationExtract
430 } // namespace google_bigquery_api
431 #endif // GOOGLE_BIGQUERY_API_JOB_CONFIGURATION_EXTRACT_H_
void clear_source_table()
Definition: job_configuration_extract.h:367
bool has_source_table() const
Definition: job_configuration_extract.h:360
bool has_use_avro_logical_types() const
Definition: job_configuration_extract.h:392
bool get_use_avro_logical_types() const
Definition: job_configuration_extract.h:407
const StringPiece get_destination_uri() const
Definition: job_configuration_extract.h:188
bool has_destination_uri() const
Definition: job_configuration_extract.h:173
Definition: job_configuration_extract.h:53
bool has_source_model() const
Definition: job_configuration_extract.h:328
bool has_print_header() const
Definition: job_configuration_extract.h:290
Definition: aggregate_classification_metrics.cc:39
void set_compression(const StringPiece &value)
Definition: job_configuration_extract.h:125
void set_use_avro_logical_types(bool value)
Definition: job_configuration_extract.h:422
bool get_print_header() const
Definition: job_configuration_extract.h:305
void clear_destination_format()
Definition: job_configuration_extract.h:141
bool has_compression() const
Definition: job_configuration_extract.h:95
void clear_destination_uri()
Definition: job_configuration_extract.h:180
void clear_print_header()
Definition: job_configuration_extract.h:297
void clear_compression()
Definition: job_configuration_extract.h:102
void set_print_header(bool value)
Definition: job_configuration_extract.h:318
bool has_destination_uris() const
Definition: job_configuration_extract.h:212
void clear_destination_uris()
Definition: job_configuration_extract.h:219
Definition: aggregate_classification_metrics.h:37
const StringPiece GetTypeName() const
Definition: job_configuration_extract.h:86
Definition: table_reference.h:50
Definition: model_reference.h:50
void clear_field_delimiter()
Definition: job_configuration_extract.h:259
void clear_use_avro_logical_types()
Definition: job_configuration_extract.h:399
void clear_source_model()
Definition: job_configuration_extract.h:335
const StringPiece get_compression() const
Definition: job_configuration_extract.h:110
client::JsonCppArray< string > mutable_destinationUris()
Definition: job_configuration_extract.h:242
void set_field_delimiter(const StringPiece &value)
Definition: job_configuration_extract.h:281
bool has_destination_format() const
Definition: job_configuration_extract.h:134
bool has_field_delimiter() const
Definition: job_configuration_extract.h:252
void set_destination_format(const StringPiece &value)
Definition: job_configuration_extract.h:164
const StringPiece get_destination_format() const
Definition: job_configuration_extract.h:149
const client::JsonCppArray< string > get_destination_uris() const
Definition: job_configuration_extract.h:228
void set_destination_uri(const StringPiece &value)
Definition: job_configuration_extract.h:203
const StringPiece get_field_delimiter() const
Definition: job_configuration_extract.h:267