AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
Player.h
1
6#pragma once
7#include <aws/gamelift/GameLift_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSMap.h>
10#include <aws/gamelift/model/AttributeValue.h>
11#include <utility>
12
13namespace Aws
14{
15namespace Utils
16{
17namespace Json
18{
19 class JsonValue;
20 class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace GameLift
24{
25namespace Model
26{
27
35 class Player
36 {
37 public:
38 AWS_GAMELIFT_API Player() = default;
39 AWS_GAMELIFT_API Player(Aws::Utils::Json::JsonView jsonValue);
40 AWS_GAMELIFT_API Player& operator=(Aws::Utils::Json::JsonView jsonValue);
41 AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const;
42
43
45
48 inline const Aws::String& GetPlayerId() const { return m_playerId; }
49 inline bool PlayerIdHasBeenSet() const { return m_playerIdHasBeenSet; }
50 template<typename PlayerIdT = Aws::String>
51 void SetPlayerId(PlayerIdT&& value) { m_playerIdHasBeenSet = true; m_playerId = std::forward<PlayerIdT>(value); }
52 template<typename PlayerIdT = Aws::String>
53 Player& WithPlayerId(PlayerIdT&& value) { SetPlayerId(std::forward<PlayerIdT>(value)); return *this;}
55
57
64 inline const Aws::Map<Aws::String, AttributeValue>& GetPlayerAttributes() const { return m_playerAttributes; }
65 inline bool PlayerAttributesHasBeenSet() const { return m_playerAttributesHasBeenSet; }
66 template<typename PlayerAttributesT = Aws::Map<Aws::String, AttributeValue>>
67 void SetPlayerAttributes(PlayerAttributesT&& value) { m_playerAttributesHasBeenSet = true; m_playerAttributes = std::forward<PlayerAttributesT>(value); }
68 template<typename PlayerAttributesT = Aws::Map<Aws::String, AttributeValue>>
69 Player& WithPlayerAttributes(PlayerAttributesT&& value) { SetPlayerAttributes(std::forward<PlayerAttributesT>(value)); return *this;}
70 template<typename PlayerAttributesKeyT = Aws::String, typename PlayerAttributesValueT = AttributeValue>
71 Player& AddPlayerAttributes(PlayerAttributesKeyT&& key, PlayerAttributesValueT&& value) {
72 m_playerAttributesHasBeenSet = true; m_playerAttributes.emplace(std::forward<PlayerAttributesKeyT>(key), std::forward<PlayerAttributesValueT>(value)); return *this;
73 }
75
77
81 inline const Aws::String& GetTeam() const { return m_team; }
82 inline bool TeamHasBeenSet() const { return m_teamHasBeenSet; }
83 template<typename TeamT = Aws::String>
84 void SetTeam(TeamT&& value) { m_teamHasBeenSet = true; m_team = std::forward<TeamT>(value); }
85 template<typename TeamT = Aws::String>
86 Player& WithTeam(TeamT&& value) { SetTeam(std::forward<TeamT>(value)); return *this;}
88
90
99 inline const Aws::Map<Aws::String, int>& GetLatencyInMs() const { return m_latencyInMs; }
100 inline bool LatencyInMsHasBeenSet() const { return m_latencyInMsHasBeenSet; }
101 template<typename LatencyInMsT = Aws::Map<Aws::String, int>>
102 void SetLatencyInMs(LatencyInMsT&& value) { m_latencyInMsHasBeenSet = true; m_latencyInMs = std::forward<LatencyInMsT>(value); }
103 template<typename LatencyInMsT = Aws::Map<Aws::String, int>>
104 Player& WithLatencyInMs(LatencyInMsT&& value) { SetLatencyInMs(std::forward<LatencyInMsT>(value)); return *this;}
105 inline Player& AddLatencyInMs(Aws::String key, int value) {
106 m_latencyInMsHasBeenSet = true; m_latencyInMs.emplace(key, value); return *this;
107 }
109 private:
110
111 Aws::String m_playerId;
112 bool m_playerIdHasBeenSet = false;
113
114 Aws::Map<Aws::String, AttributeValue> m_playerAttributes;
115 bool m_playerAttributesHasBeenSet = false;
116
117 Aws::String m_team;
118 bool m_teamHasBeenSet = false;
119
120 Aws::Map<Aws::String, int> m_latencyInMs;
121 bool m_latencyInMsHasBeenSet = false;
122 };
123
124} // namespace Model
125} // namespace GameLift
126} // namespace Aws
AWS_GAMELIFT_API Player()=default
AWS_GAMELIFT_API Player & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetLatencyInMs(LatencyInMsT &&value)
Definition Player.h:102
const Aws::String & GetTeam() const
Definition Player.h:81
void SetPlayerId(PlayerIdT &&value)
Definition Player.h:51
bool LatencyInMsHasBeenSet() const
Definition Player.h:100
void SetPlayerAttributes(PlayerAttributesT &&value)
Definition Player.h:67
Player & WithPlayerId(PlayerIdT &&value)
Definition Player.h:53
const Aws::String & GetPlayerId() const
Definition Player.h:48
bool TeamHasBeenSet() const
Definition Player.h:82
bool PlayerIdHasBeenSet() const
Definition Player.h:49
Player & WithPlayerAttributes(PlayerAttributesT &&value)
Definition Player.h:69
void SetTeam(TeamT &&value)
Definition Player.h:84
Player & WithTeam(TeamT &&value)
Definition Player.h:86
AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::Map< Aws::String, AttributeValue > & GetPlayerAttributes() const
Definition Player.h:64
AWS_GAMELIFT_API Player(Aws::Utils::Json::JsonView jsonValue)
const Aws::Map< Aws::String, int > & GetLatencyInMs() const
Definition Player.h:99
bool PlayerAttributesHasBeenSet() const
Definition Player.h:65
Player & WithLatencyInMs(LatencyInMsT &&value)
Definition Player.h:104
Player & AddLatencyInMs(Aws::String key, int value)
Definition Player.h:105
Player & AddPlayerAttributes(PlayerAttributesKeyT &&key, PlayerAttributesValueT &&value)
Definition Player.h:71
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue