androidenterprise  v1
user.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-11, 20:26:36 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 Play EMM API (androidenterprise/v1)
24 // Generated from:
25 // Version: v1
26 // Revision: 218
27 // Generated by:
28 // Tool: google-apis-code-generator 1.5.1
29 // C++: 0.1.4
30 #ifndef GOOGLE_ANDROIDENTERPRISE_API_USER_H_
31 #define GOOGLE_ANDROIDENTERPRISE_API_USER_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 
43 using namespace googleapis;
44 
59 class User : public client::JsonCppData {
60  public:
66  static User* New();
67 
73  explicit User(const Json::Value& storage);
74 
80  explicit User(Json::Value* storage);
81 
85  virtual ~User();
86 
92  const StringPiece GetTypeName() const {
93  return StringPiece("google_androidenterprise_api::User");
94  }
95 
101  bool has_account_identifier() const {
102  return Storage().isMember("accountIdentifier");
103  }
104 
109  MutableStorage()->removeMember("accountIdentifier");
110  }
111 
112 
116  const StringPiece get_account_identifier() const {
117  const Json::Value& v = Storage("accountIdentifier");
118  if (v == Json::Value::null) return StringPiece("");
119  return StringPiece(v.asCString());
120  }
121 
132  void set_account_identifier(const StringPiece& value) {
133  *MutableStorage("accountIdentifier") = value.data();
134  }
135 
141  bool has_account_type() const {
142  return Storage().isMember("accountType");
143  }
144 
149  MutableStorage()->removeMember("accountType");
150  }
151 
152 
156  const StringPiece get_account_type() const {
157  const Json::Value& v = Storage("accountType");
158  if (v == Json::Value::null) return StringPiece("");
159  return StringPiece(v.asCString());
160  }
161 
173  void set_account_type(const StringPiece& value) {
174  *MutableStorage("accountType") = value.data();
175  }
176 
182  bool has_display_name() const {
183  return Storage().isMember("displayName");
184  }
185 
190  MutableStorage()->removeMember("displayName");
191  }
192 
193 
197  const StringPiece get_display_name() const {
198  const Json::Value& v = Storage("displayName");
199  if (v == Json::Value::null) return StringPiece("");
200  return StringPiece(v.asCString());
201  }
202 
213  void set_display_name(const StringPiece& value) {
214  *MutableStorage("displayName") = value.data();
215  }
216 
222  bool has_id() const {
223  return Storage().isMember("id");
224  }
225 
229  void clear_id() {
230  MutableStorage()->removeMember("id");
231  }
232 
233 
237  const StringPiece get_id() const {
238  const Json::Value& v = Storage("id");
239  if (v == Json::Value::null) return StringPiece("");
240  return StringPiece(v.asCString());
241  }
242 
250  void set_id(const StringPiece& value) {
251  *MutableStorage("id") = value.data();
252  }
253 
259  bool has_kind() const {
260  return Storage().isMember("kind");
261  }
262 
266  void clear_kind() {
267  MutableStorage()->removeMember("kind");
268  }
269 
270 
274  const StringPiece get_kind() const {
275  const Json::Value& v = Storage("kind");
276  if (v == Json::Value::null) return StringPiece("");
277  return StringPiece(v.asCString());
278  }
279 
284  void set_kind(const StringPiece& value) {
285  *MutableStorage("kind") = value.data();
286  }
287 
293  bool has_management_type() const {
294  return Storage().isMember("managementType");
295  }
296 
301  MutableStorage()->removeMember("managementType");
302  }
303 
304 
308  const StringPiece get_management_type() const {
309  const Json::Value& v = Storage("managementType");
310  if (v == Json::Value::null) return StringPiece("");
311  return StringPiece(v.asCString());
312  }
313 
323  void set_management_type(const StringPiece& value) {
324  *MutableStorage("managementType") = value.data();
325  }
326 
332  bool has_primary_email() const {
333  return Storage().isMember("primaryEmail");
334  }
335 
340  MutableStorage()->removeMember("primaryEmail");
341  }
342 
343 
347  const StringPiece get_primary_email() const {
348  const Json::Value& v = Storage("primaryEmail");
349  if (v == Json::Value::null) return StringPiece("");
350  return StringPiece(v.asCString());
351  }
352 
361  void set_primary_email(const StringPiece& value) {
362  *MutableStorage("primaryEmail") = value.data();
363  }
364 
365  private:
366  void operator=(const User&);
367 }; // User
368 } // namespace google_androidenterprise_api
369 #endif // GOOGLE_ANDROIDENTERPRISE_API_USER_H_
void clear_account_type()
Definition: user.h:148
bool has_primary_email() const
Definition: user.h:332
bool has_account_type() const
Definition: user.h:141
void set_account_identifier(const StringPiece &value)
Definition: user.h:132
const StringPiece get_management_type() const
Definition: user.h:308
void clear_management_type()
Definition: user.h:300
const StringPiece get_kind() const
Definition: user.h:274
const StringPiece get_account_type() const
Definition: user.h:156
void clear_display_name()
Definition: user.h:189
void set_management_type(const StringPiece &value)
Definition: user.h:323
const StringPiece get_account_identifier() const
Definition: user.h:116
bool has_display_name() const
Definition: user.h:182
const StringPiece get_id() const
Definition: user.h:237
void set_account_type(const StringPiece &value)
Definition: user.h:173
const StringPiece get_primary_email() const
Definition: user.h:347
bool has_account_identifier() const
Definition: user.h:101
void set_kind(const StringPiece &value)
Definition: user.h:284
Definition: administrator.h:38
void clear_id()
Definition: user.h:229
Definition: administrator.cc:40
bool has_management_type() const
Definition: user.h:293
const StringPiece get_display_name() const
Definition: user.h:197
void clear_kind()
Definition: user.h:266
bool has_kind() const
Definition: user.h:259
void clear_primary_email()
Definition: user.h:339
void clear_account_identifier()
Definition: user.h:108
void set_primary_email(const StringPiece &value)
Definition: user.h:361
const StringPiece GetTypeName() const
Definition: user.h:92
bool has_id() const
Definition: user.h:222
void set_id(const StringPiece &value)
Definition: user.h:250
void set_display_name(const StringPiece &value)
Definition: user.h:213