dataflow  v1b3
pubsub_location.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-19, 02:23:49 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // Dataflow API (dataflow/v1b3)
24 // Generated from:
25 // Version: v1b3
26 // Revision: 302
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_DATAFLOW_API_PUBSUB_LOCATION_H_
31 #define GOOGLE_DATAFLOW_API_PUBSUB_LOCATION_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_dataflow_api {
43 using namespace googleapis;
44 
51 class PubsubLocation : public client::JsonCppData {
52  public:
58  static PubsubLocation* New();
59 
65  explicit PubsubLocation(const Json::Value& storage);
66 
72  explicit PubsubLocation(Json::Value* storage);
73 
77  virtual ~PubsubLocation();
78 
84  const StringPiece GetTypeName() const {
85  return StringPiece("google_dataflow_api::PubsubLocation");
86  }
87 
93  bool has_drop_late_data() const {
94  return Storage().isMember("dropLateData");
95  }
96 
101  MutableStorage()->removeMember("dropLateData");
102  }
103 
104 
108  bool get_drop_late_data() const {
109  const Json::Value& storage = Storage("dropLateData");
110  return client::JsonValueToCppValueHelper<bool >(storage);
111  }
112 
120  void set_drop_late_data(bool value) {
121  client::SetJsonValueFromCppValueHelper<bool >(
122  value, MutableStorage("dropLateData"));
123  }
124 
130  bool has_id_label() const {
131  return Storage().isMember("idLabel");
132  }
133 
137  void clear_id_label() {
138  MutableStorage()->removeMember("idLabel");
139  }
140 
141 
145  const StringPiece get_id_label() const {
146  const Json::Value& v = Storage("idLabel");
147  if (v == Json::Value::null) return StringPiece("");
148  return StringPiece(v.asCString());
149  }
150 
159  void set_id_label(const StringPiece& value) {
160  *MutableStorage("idLabel") = value.data();
161  }
162 
168  bool has_subscription() const {
169  return Storage().isMember("subscription");
170  }
171 
176  MutableStorage()->removeMember("subscription");
177  }
178 
179 
183  const StringPiece get_subscription() const {
184  const Json::Value& v = Storage("subscription");
185  if (v == Json::Value::null) return StringPiece("");
186  return StringPiece(v.asCString());
187  }
188 
197  void set_subscription(const StringPiece& value) {
198  *MutableStorage("subscription") = value.data();
199  }
200 
206  bool has_timestamp_label() const {
207  return Storage().isMember("timestampLabel");
208  }
209 
214  MutableStorage()->removeMember("timestampLabel");
215  }
216 
217 
221  const StringPiece get_timestamp_label() const {
222  const Json::Value& v = Storage("timestampLabel");
223  if (v == Json::Value::null) return StringPiece("");
224  return StringPiece(v.asCString());
225  }
226 
235  void set_timestamp_label(const StringPiece& value) {
236  *MutableStorage("timestampLabel") = value.data();
237  }
238 
244  bool has_topic() const {
245  return Storage().isMember("topic");
246  }
247 
251  void clear_topic() {
252  MutableStorage()->removeMember("topic");
253  }
254 
255 
259  const StringPiece get_topic() const {
260  const Json::Value& v = Storage("topic");
261  if (v == Json::Value::null) return StringPiece("");
262  return StringPiece(v.asCString());
263  }
264 
273  void set_topic(const StringPiece& value) {
274  *MutableStorage("topic") = value.data();
275  }
276 
283  return Storage().isMember("trackingSubscription");
284  }
285 
290  MutableStorage()->removeMember("trackingSubscription");
291  }
292 
293 
297  const StringPiece get_tracking_subscription() const {
298  const Json::Value& v = Storage("trackingSubscription");
299  if (v == Json::Value::null) return StringPiece("");
300  return StringPiece(v.asCString());
301  }
302 
311  void set_tracking_subscription(const StringPiece& value) {
312  *MutableStorage("trackingSubscription") = value.data();
313  }
314 
320  bool has_with_attributes() const {
321  return Storage().isMember("withAttributes");
322  }
323 
328  MutableStorage()->removeMember("withAttributes");
329  }
330 
331 
335  bool get_with_attributes() const {
336  const Json::Value& storage = Storage("withAttributes");
337  return client::JsonValueToCppValueHelper<bool >(storage);
338  }
339 
347  void set_with_attributes(bool value) {
348  client::SetJsonValueFromCppValueHelper<bool >(
349  value, MutableStorage("withAttributes"));
350  }
351 
352  private:
353  void operator=(const PubsubLocation&);
354 }; // PubsubLocation
355 } // namespace google_dataflow_api
356 #endif // GOOGLE_DATAFLOW_API_PUBSUB_LOCATION_H_
const StringPiece get_subscription() const
Definition: pubsub_location.h:183
bool has_tracking_subscription() const
Definition: pubsub_location.h:282
void clear_subscription()
Definition: pubsub_location.h:175
bool has_topic() const
Definition: pubsub_location.h:244
bool has_id_label() const
Definition: pubsub_location.h:130
const StringPiece get_id_label() const
Definition: pubsub_location.h:145
const StringPiece get_timestamp_label() const
Definition: pubsub_location.h:221
void clear_timestamp_label()
Definition: pubsub_location.h:213
void clear_id_label()
Definition: pubsub_location.h:137
bool has_drop_late_data() const
Definition: pubsub_location.h:93
void clear_topic()
Definition: pubsub_location.h:251
void set_topic(const StringPiece &value)
Definition: pubsub_location.h:273
const StringPiece get_topic() const
Definition: pubsub_location.h:259
bool get_drop_late_data() const
Definition: pubsub_location.h:108
void set_timestamp_label(const StringPiece &value)
Definition: pubsub_location.h:235
const StringPiece get_tracking_subscription() const
Definition: pubsub_location.h:297
Definition: approximate_progress.h:40
bool has_with_attributes() const
Definition: pubsub_location.h:320
bool has_subscription() const
Definition: pubsub_location.h:168
void set_tracking_subscription(const StringPiece &value)
Definition: pubsub_location.h:311
bool get_with_attributes() const
Definition: pubsub_location.h:335
bool has_timestamp_label() const
Definition: pubsub_location.h:206
const StringPiece GetTypeName() const
Definition: pubsub_location.h:84
void set_subscription(const StringPiece &value)
Definition: pubsub_location.h:197
void clear_tracking_subscription()
Definition: pubsub_location.h:289
void set_drop_late_data(bool value)
Definition: pubsub_location.h:120
Definition: approximate_progress.cc:42
void clear_drop_late_data()
Definition: pubsub_location.h:100
Definition: pubsub_location.h:51
void set_id_label(const StringPiece &value)
Definition: pubsub_location.h:159
void clear_with_attributes()
Definition: pubsub_location.h:327
void set_with_attributes(bool value)
Definition: pubsub_location.h:347