30 #ifndef GOOGLE_CLASSROOM_API_STUDENT_H_ 31 #define GOOGLE_CLASSROOM_API_STUDENT_H_ 34 #include "googleapis/base/macros.h" 35 #include "googleapis/client/data/jsoncpp_data.h" 36 #include "googleapis/strings/stringpiece.h" 38 #include "google/classroom_api/drive_folder.h" 39 #include "google/classroom_api/user_profile.h" 53 class Student :
public client::JsonCppData {
67 explicit Student(
const Json::Value& storage);
74 explicit Student(Json::Value* storage);
87 return StringPiece(
"google_classroom_api::Student");
96 return Storage().isMember(
"courseId");
103 MutableStorage()->removeMember(
"courseId");
111 const Json::Value& v = Storage(
"courseId");
112 if (v == Json::Value::null)
return StringPiece(
"");
113 return StringPiece(v.asCString());
126 *MutableStorage(
"courseId") = value.data();
135 return Storage().isMember(
"profile");
142 MutableStorage()->removeMember(
"profile");
168 return Storage().isMember(
"studentWorkFolder");
175 MutableStorage()->removeMember(
"studentWorkFolder");
204 return Storage().isMember(
"userId");
211 MutableStorage()->removeMember(
"userId");
219 const Json::Value& v = Storage(
"userId");
220 if (v == Json::Value::null)
return StringPiece(
"");
221 return StringPiece(v.asCString());
239 *MutableStorage(
"userId") = value.data();
243 void operator=(
const Student&);
246 #endif // GOOGLE_CLASSROOM_API_STUDENT_H_ const StringPiece get_user_id() const
Definition: student.h:218
bool has_profile() const
Definition: student.h:134
void clear_student_work_folder()
Definition: student.h:174
Definition: drive_folder.h:50
const StringPiece get_course_id() const
Definition: student.h:110
void set_course_id(const StringPiece &value)
Definition: student.h:125
void clear_profile()
Definition: student.h:141
bool has_course_id() const
Definition: student.h:95
void clear_user_id()
Definition: student.h:210
Definition: announcement.h:41
bool has_user_id() const
Definition: student.h:203
void clear_course_id()
Definition: student.h:102
const StringPiece GetTypeName() const
Definition: student.h:86
Definition: announcement.cc:43
Definition: user_profile.h:53
bool has_student_work_folder() const
Definition: student.h:167
void set_user_id(const StringPiece &value)
Definition: student.h:238