youtube  v3
geo_point.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-02-27, 01:46:08 UTC
18 // C++ generator version: 0.1.4
19 
20 // ----------------------------------------------------------------------------
21 // NOTE: This file is generated from Google APIs Discovery Service.
22 // Service:
23 // YouTube Data API (youtube/v3)
24 // Generated from:
25 // Version: v3
26 // Revision: 222
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_YOUTUBE_API_GEO_POINT_H_
31 #define GOOGLE_YOUTUBE_API_GEO_POINT_H_
32 
33 #include "googleapis/base/macros.h"
34 #include "googleapis/client/data/jsoncpp_data.h"
35 #include "googleapis/strings/stringpiece.h"
36 
37 namespace Json {
38 class Value;
39 } // namespace Json
40 
41 namespace google_youtube_api {
42 using namespace googleapis;
43 
49 class GeoPoint : public client::JsonCppData {
50  public:
56  static GeoPoint* New();
57 
63  explicit GeoPoint(const Json::Value& storage);
64 
70  explicit GeoPoint(Json::Value* storage);
71 
75  virtual ~GeoPoint();
76 
82  const StringPiece GetTypeName() const {
83  return StringPiece("google_youtube_api::GeoPoint");
84  }
85 
91  bool has_altitude() const {
92  return Storage().isMember("altitude");
93  }
94 
98  void clear_altitude() {
99  MutableStorage()->removeMember("altitude");
100  }
101 
102 
106  double get_altitude() const {
107  const Json::Value& storage = Storage("altitude");
108  return client::JsonValueToCppValueHelper<double >(storage);
109  }
110 
118  void set_altitude(double value) {
119  client::SetJsonValueFromCppValueHelper<double >(
120  value, MutableStorage("altitude"));
121  }
122 
128  bool has_latitude() const {
129  return Storage().isMember("latitude");
130  }
131 
135  void clear_latitude() {
136  MutableStorage()->removeMember("latitude");
137  }
138 
139 
143  double get_latitude() const {
144  const Json::Value& storage = Storage("latitude");
145  return client::JsonValueToCppValueHelper<double >(storage);
146  }
147 
155  void set_latitude(double value) {
156  client::SetJsonValueFromCppValueHelper<double >(
157  value, MutableStorage("latitude"));
158  }
159 
165  bool has_longitude() const {
166  return Storage().isMember("longitude");
167  }
168 
173  MutableStorage()->removeMember("longitude");
174  }
175 
176 
180  double get_longitude() const {
181  const Json::Value& storage = Storage("longitude");
182  return client::JsonValueToCppValueHelper<double >(storage);
183  }
184 
192  void set_longitude(double value) {
193  client::SetJsonValueFromCppValueHelper<double >(
194  value, MutableStorage("longitude"));
195  }
196 
197  private:
198  void operator=(const GeoPoint&);
199 }; // GeoPoint
200 } // namespace google_youtube_api
201 #endif // GOOGLE_YOUTUBE_API_GEO_POINT_H_
Definition: access_policy.cc:40
void clear_longitude()
Definition: geo_point.h:172
bool has_longitude() const
Definition: geo_point.h:165
bool has_altitude() const
Definition: geo_point.h:91
void set_latitude(double value)
Definition: geo_point.h:155
double get_altitude() const
Definition: geo_point.h:106
void set_altitude(double value)
Definition: geo_point.h:118
Definition: access_policy.h:38
void clear_altitude()
Definition: geo_point.h:98
double get_latitude() const
Definition: geo_point.h:143
void set_longitude(double value)
Definition: geo_point.h:192
bool has_latitude() const
Definition: geo_point.h:128
Definition: geo_point.h:49
double get_longitude() const
Definition: geo_point.h:180
void clear_latitude()
Definition: geo_point.h:135
const StringPiece GetTypeName() const
Definition: geo_point.h:82