identitytoolkit  v3
email_link_signin_response.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-04-06, 12:09:29 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 Identity Toolkit API (identitytoolkit/v3)
24 // Generated from:
25 // Version: v3
26 // Revision: 368
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_IDENTITYTOOLKIT_API_EMAIL_LINK_SIGNIN_RESPONSE_H_
31 #define GOOGLE_IDENTITYTOOLKIT_API_EMAIL_LINK_SIGNIN_RESPONSE_H_
32 
33 #include <string>
34 #include "googleapis/base/integral_types.h"
35 #include "googleapis/base/macros.h"
36 #include "googleapis/client/data/jsoncpp_data.h"
37 #include "googleapis/strings/stringpiece.h"
38 
39 namespace Json {
40 class Value;
41 } // namespace Json
42 
44 using namespace googleapis;
45 
51 class EmailLinkSigninResponse : public client::JsonCppData {
52  public:
58  static EmailLinkSigninResponse* New();
59 
65  explicit EmailLinkSigninResponse(const Json::Value& storage);
66 
72  explicit EmailLinkSigninResponse(Json::Value* storage);
73 
77  virtual ~EmailLinkSigninResponse();
78 
84  const StringPiece GetTypeName() const {
85  return StringPiece("google_identitytoolkit_api::EmailLinkSigninResponse");
86  }
87 
93  bool has_email() const {
94  return Storage().isMember("email");
95  }
96 
100  void clear_email() {
101  MutableStorage()->removeMember("email");
102  }
103 
104 
108  const StringPiece get_email() const {
109  const Json::Value& v = Storage("email");
110  if (v == Json::Value::null) return StringPiece("");
111  return StringPiece(v.asCString());
112  }
113 
121  void set_email(const StringPiece& value) {
122  *MutableStorage("email") = value.data();
123  }
124 
130  bool has_expires_in() const {
131  return Storage().isMember("expiresIn");
132  }
133 
138  MutableStorage()->removeMember("expiresIn");
139  }
140 
141 
145  int64 get_expires_in() const {
146  const Json::Value& storage = Storage("expiresIn");
147  return client::JsonValueToCppValueHelper<int64 >(storage);
148  }
149 
157  void set_expires_in(int64 value) {
158  client::SetJsonValueFromCppValueHelper<int64 >(
159  value, MutableStorage("expiresIn"));
160  }
161 
167  bool has_id_token() const {
168  return Storage().isMember("idToken");
169  }
170 
174  void clear_id_token() {
175  MutableStorage()->removeMember("idToken");
176  }
177 
178 
182  const StringPiece get_id_token() const {
183  const Json::Value& v = Storage("idToken");
184  if (v == Json::Value::null) return StringPiece("");
185  return StringPiece(v.asCString());
186  }
187 
195  void set_id_token(const StringPiece& value) {
196  *MutableStorage("idToken") = value.data();
197  }
198 
204  bool has_is_new_user() const {
205  return Storage().isMember("isNewUser");
206  }
207 
212  MutableStorage()->removeMember("isNewUser");
213  }
214 
215 
219  bool get_is_new_user() const {
220  const Json::Value& storage = Storage("isNewUser");
221  return client::JsonValueToCppValueHelper<bool >(storage);
222  }
223 
231  void set_is_new_user(bool value) {
232  client::SetJsonValueFromCppValueHelper<bool >(
233  value, MutableStorage("isNewUser"));
234  }
235 
241  bool has_kind() const {
242  return Storage().isMember("kind");
243  }
244 
248  void clear_kind() {
249  MutableStorage()->removeMember("kind");
250  }
251 
252 
256  const StringPiece get_kind() const {
257  const Json::Value& v = Storage("kind");
258  if (v == Json::Value::null) return StringPiece("");
259  return StringPiece(v.asCString());
260  }
261 
269  void set_kind(const StringPiece& value) {
270  *MutableStorage("kind") = value.data();
271  }
272 
278  bool has_local_id() const {
279  return Storage().isMember("localId");
280  }
281 
285  void clear_local_id() {
286  MutableStorage()->removeMember("localId");
287  }
288 
289 
293  const StringPiece get_local_id() const {
294  const Json::Value& v = Storage("localId");
295  if (v == Json::Value::null) return StringPiece("");
296  return StringPiece(v.asCString());
297  }
298 
306  void set_local_id(const StringPiece& value) {
307  *MutableStorage("localId") = value.data();
308  }
309 
315  bool has_refresh_token() const {
316  return Storage().isMember("refreshToken");
317  }
318 
323  MutableStorage()->removeMember("refreshToken");
324  }
325 
326 
330  const StringPiece get_refresh_token() const {
331  const Json::Value& v = Storage("refreshToken");
332  if (v == Json::Value::null) return StringPiece("");
333  return StringPiece(v.asCString());
334  }
335 
343  void set_refresh_token(const StringPiece& value) {
344  *MutableStorage("refreshToken") = value.data();
345  }
346 
347  private:
348  void operator=(const EmailLinkSigninResponse&);
349 }; // EmailLinkSigninResponse
350 } // namespace google_identitytoolkit_api
351 #endif // GOOGLE_IDENTITYTOOLKIT_API_EMAIL_LINK_SIGNIN_RESPONSE_H_
const StringPiece GetTypeName() const
Definition: email_link_signin_response.h:84
bool has_refresh_token() const
Definition: email_link_signin_response.h:315
bool has_is_new_user() const
Definition: email_link_signin_response.h:204
void set_id_token(const StringPiece &value)
Definition: email_link_signin_response.h:195
bool has_email() const
Definition: email_link_signin_response.h:93
void clear_local_id()
Definition: email_link_signin_response.h:285
void clear_refresh_token()
Definition: email_link_signin_response.h:322
const StringPiece get_kind() const
Definition: email_link_signin_response.h:256
Definition: create_auth_uri_response.cc:40
void set_is_new_user(bool value)
Definition: email_link_signin_response.h:231
bool has_expires_in() const
Definition: email_link_signin_response.h:130
bool has_id_token() const
Definition: email_link_signin_response.h:167
void set_local_id(const StringPiece &value)
Definition: email_link_signin_response.h:306
bool has_kind() const
Definition: email_link_signin_response.h:241
void set_refresh_token(const StringPiece &value)
Definition: email_link_signin_response.h:343
void clear_id_token()
Definition: email_link_signin_response.h:174
int64 get_expires_in() const
Definition: email_link_signin_response.h:145
const StringPiece get_refresh_token() const
Definition: email_link_signin_response.h:330
Definition: create_auth_uri_response.h:38
void clear_expires_in()
Definition: email_link_signin_response.h:137
const StringPiece get_local_id() const
Definition: email_link_signin_response.h:293
void clear_kind()
Definition: email_link_signin_response.h:248
void clear_is_new_user()
Definition: email_link_signin_response.h:211
bool has_local_id() const
Definition: email_link_signin_response.h:278
bool get_is_new_user() const
Definition: email_link_signin_response.h:219
const StringPiece get_id_token() const
Definition: email_link_signin_response.h:182
void clear_email()
Definition: email_link_signin_response.h:100
void set_expires_in(int64 value)
Definition: email_link_signin_response.h:157
void set_email(const StringPiece &value)
Definition: email_link_signin_response.h:121
Definition: email_link_signin_response.h:51
const StringPiece get_email() const
Definition: email_link_signin_response.h:108
void set_kind(const StringPiece &value)
Definition: email_link_signin_response.h:269