30 #ifndef GOOGLE_GAMES_API_TURN_BASED_MATCH_TURN_H_ 31 #define GOOGLE_GAMES_API_TURN_BASED_MATCH_TURN_H_ 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" 39 #include "google/games_api/participant_result.h" 40 #include "google/games_api/turn_based_match_data_request.h" 88 return StringPiece(
"google_games_api::TurnBasedMatchTurn");
97 return Storage().isMember(
"data");
104 MutableStorage()->removeMember(
"data");
128 return Storage().isMember(
"kind");
135 MutableStorage()->removeMember(
"kind");
143 const Json::Value& v = Storage(
"kind");
144 if (v == Json::Value::null)
return StringPiece(
"");
145 return StringPiece(v.asCString());
157 *MutableStorage(
"kind") = value.data();
166 return Storage().isMember(
"matchVersion");
173 MutableStorage()->removeMember(
"matchVersion");
181 const Json::Value& storage = Storage(
"matchVersion");
182 return client::JsonValueToCppValueHelper<int32 >(storage);
194 client::SetJsonValueFromCppValueHelper<int32 >(
195 value, MutableStorage(
"matchVersion"));
204 return Storage().isMember(
"pendingParticipantId");
211 MutableStorage()->removeMember(
"pendingParticipantId");
219 const Json::Value& v = Storage(
"pendingParticipantId");
220 if (v == Json::Value::null)
return StringPiece(
"");
221 return StringPiece(v.asCString());
236 *MutableStorage(
"pendingParticipantId") = value.data();
245 return Storage().isMember(
"results");
252 MutableStorage()->removeMember(
"results");
259 const client::JsonCppArray<ParticipantResult > get_results()
const;
268 client::JsonCppArray<ParticipantResult > mutable_results();
274 #endif // GOOGLE_GAMES_API_TURN_BASED_MATCH_TURN_H_ void set_pending_participant_id(const StringPiece &value)
Definition: turn_based_match_turn.h:235
void set_kind(const StringPiece &value)
Definition: turn_based_match_turn.h:156
void set_match_version(int32 value)
Definition: turn_based_match_turn.h:193
void clear_match_version()
Definition: turn_based_match_turn.h:172
bool has_kind() const
Definition: turn_based_match_turn.h:127
void clear_results()
Definition: turn_based_match_turn.h:251
bool has_results() const
Definition: turn_based_match_turn.h:244
Definition: turn_based_match_data_request.h:50
void clear_pending_participant_id()
Definition: turn_based_match_turn.h:210
void clear_kind()
Definition: turn_based_match_turn.h:134
void clear_data()
Definition: turn_based_match_turn.h:103
bool has_data() const
Definition: turn_based_match_turn.h:96
Definition: achievement_definition.cc:41
Definition: achievement_definition.h:39
const StringPiece GetTypeName() const
Definition: turn_based_match_turn.h:87
bool has_match_version() const
Definition: turn_based_match_turn.h:165
bool has_pending_participant_id() const
Definition: turn_based_match_turn.h:203
Definition: turn_based_match_turn.h:54
const StringPiece get_pending_participant_id() const
Definition: turn_based_match_turn.h:218
int32 get_match_version() const
Definition: turn_based_match_turn.h:180
const StringPiece get_kind() const
Definition: turn_based_match_turn.h:142