AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
CreateGameServerGroupRequest.h
1
6#pragma once
7#include <aws/gamelift/GameLift_EXPORTS.h>
8#include <aws/gamelift/GameLiftRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/gamelift/model/LaunchTemplateSpecification.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <aws/gamelift/model/GameServerGroupAutoScalingPolicy.h>
13#include <aws/gamelift/model/BalancingStrategy.h>
14#include <aws/gamelift/model/GameServerProtectionPolicy.h>
15#include <aws/gamelift/model/InstanceDefinition.h>
16#include <aws/gamelift/model/Tag.h>
17#include <utility>
18
19namespace Aws
20{
21namespace GameLift
22{
23namespace Model
24{
25
29 {
30 public:
31 AWS_GAMELIFT_API CreateGameServerGroupRequest() = default;
32
33 // Service request name is the Operation name which will send this request out,
34 // each operation should has unique request name, so that we can get operation's name from this request.
35 // Note: this is not true for response, multiple operations may have the same response name,
36 // so we can not get operation's name from response.
37 inline virtual const char* GetServiceRequestName() const override { return "CreateGameServerGroup"; }
38
39 AWS_GAMELIFT_API Aws::String SerializePayload() const override;
40
42
43
45
51 inline const Aws::String& GetGameServerGroupName() const { return m_gameServerGroupName; }
52 inline bool GameServerGroupNameHasBeenSet() const { return m_gameServerGroupNameHasBeenSet; }
53 template<typename GameServerGroupNameT = Aws::String>
54 void SetGameServerGroupName(GameServerGroupNameT&& value) { m_gameServerGroupNameHasBeenSet = true; m_gameServerGroupName = std::forward<GameServerGroupNameT>(value); }
55 template<typename GameServerGroupNameT = Aws::String>
56 CreateGameServerGroupRequest& WithGameServerGroupName(GameServerGroupNameT&& value) { SetGameServerGroupName(std::forward<GameServerGroupNameT>(value)); return *this;}
58
60
66 inline const Aws::String& GetRoleArn() const { return m_roleArn; }
67 inline bool RoleArnHasBeenSet() const { return m_roleArnHasBeenSet; }
68 template<typename RoleArnT = Aws::String>
69 void SetRoleArn(RoleArnT&& value) { m_roleArnHasBeenSet = true; m_roleArn = std::forward<RoleArnT>(value); }
70 template<typename RoleArnT = Aws::String>
71 CreateGameServerGroupRequest& WithRoleArn(RoleArnT&& value) { SetRoleArn(std::forward<RoleArnT>(value)); return *this;}
73
75
83 inline int GetMinSize() const { return m_minSize; }
84 inline bool MinSizeHasBeenSet() const { return m_minSizeHasBeenSet; }
85 inline void SetMinSize(int value) { m_minSizeHasBeenSet = true; m_minSize = value; }
86 inline CreateGameServerGroupRequest& WithMinSize(int value) { SetMinSize(value); return *this;}
88
90
97 inline int GetMaxSize() const { return m_maxSize; }
98 inline bool MaxSizeHasBeenSet() const { return m_maxSizeHasBeenSet; }
99 inline void SetMaxSize(int value) { m_maxSizeHasBeenSet = true; m_maxSize = value; }
100 inline CreateGameServerGroupRequest& WithMaxSize(int value) { SetMaxSize(value); return *this;}
102
104
119 inline const LaunchTemplateSpecification& GetLaunchTemplate() const { return m_launchTemplate; }
120 inline bool LaunchTemplateHasBeenSet() const { return m_launchTemplateHasBeenSet; }
121 template<typename LaunchTemplateT = LaunchTemplateSpecification>
122 void SetLaunchTemplate(LaunchTemplateT&& value) { m_launchTemplateHasBeenSet = true; m_launchTemplate = std::forward<LaunchTemplateT>(value); }
123 template<typename LaunchTemplateT = LaunchTemplateSpecification>
124 CreateGameServerGroupRequest& WithLaunchTemplate(LaunchTemplateT&& value) { SetLaunchTemplate(std::forward<LaunchTemplateT>(value)); return *this;}
126
128
142 inline const Aws::Vector<InstanceDefinition>& GetInstanceDefinitions() const { return m_instanceDefinitions; }
143 inline bool InstanceDefinitionsHasBeenSet() const { return m_instanceDefinitionsHasBeenSet; }
144 template<typename InstanceDefinitionsT = Aws::Vector<InstanceDefinition>>
145 void SetInstanceDefinitions(InstanceDefinitionsT&& value) { m_instanceDefinitionsHasBeenSet = true; m_instanceDefinitions = std::forward<InstanceDefinitionsT>(value); }
146 template<typename InstanceDefinitionsT = Aws::Vector<InstanceDefinition>>
147 CreateGameServerGroupRequest& WithInstanceDefinitions(InstanceDefinitionsT&& value) { SetInstanceDefinitions(std::forward<InstanceDefinitionsT>(value)); return *this;}
148 template<typename InstanceDefinitionsT = InstanceDefinition>
149 CreateGameServerGroupRequest& AddInstanceDefinitions(InstanceDefinitionsT&& value) { m_instanceDefinitionsHasBeenSet = true; m_instanceDefinitions.emplace_back(std::forward<InstanceDefinitionsT>(value)); return *this; }
151
153
161 inline const GameServerGroupAutoScalingPolicy& GetAutoScalingPolicy() const { return m_autoScalingPolicy; }
162 inline bool AutoScalingPolicyHasBeenSet() const { return m_autoScalingPolicyHasBeenSet; }
163 template<typename AutoScalingPolicyT = GameServerGroupAutoScalingPolicy>
164 void SetAutoScalingPolicy(AutoScalingPolicyT&& value) { m_autoScalingPolicyHasBeenSet = true; m_autoScalingPolicy = std::forward<AutoScalingPolicyT>(value); }
165 template<typename AutoScalingPolicyT = GameServerGroupAutoScalingPolicy>
166 CreateGameServerGroupRequest& WithAutoScalingPolicy(AutoScalingPolicyT&& value) { SetAutoScalingPolicy(std::forward<AutoScalingPolicyT>(value)); return *this;}
168
170
188 inline BalancingStrategy GetBalancingStrategy() const { return m_balancingStrategy; }
189 inline bool BalancingStrategyHasBeenSet() const { return m_balancingStrategyHasBeenSet; }
190 inline void SetBalancingStrategy(BalancingStrategy value) { m_balancingStrategyHasBeenSet = true; m_balancingStrategy = value; }
193
195
205 inline GameServerProtectionPolicy GetGameServerProtectionPolicy() const { return m_gameServerProtectionPolicy; }
206 inline bool GameServerProtectionPolicyHasBeenSet() const { return m_gameServerProtectionPolicyHasBeenSet; }
207 inline void SetGameServerProtectionPolicy(GameServerProtectionPolicy value) { m_gameServerProtectionPolicyHasBeenSet = true; m_gameServerProtectionPolicy = value; }
210
212
221 inline const Aws::Vector<Aws::String>& GetVpcSubnets() const { return m_vpcSubnets; }
222 inline bool VpcSubnetsHasBeenSet() const { return m_vpcSubnetsHasBeenSet; }
223 template<typename VpcSubnetsT = Aws::Vector<Aws::String>>
224 void SetVpcSubnets(VpcSubnetsT&& value) { m_vpcSubnetsHasBeenSet = true; m_vpcSubnets = std::forward<VpcSubnetsT>(value); }
225 template<typename VpcSubnetsT = Aws::Vector<Aws::String>>
226 CreateGameServerGroupRequest& WithVpcSubnets(VpcSubnetsT&& value) { SetVpcSubnets(std::forward<VpcSubnetsT>(value)); return *this;}
227 template<typename VpcSubnetsT = Aws::String>
228 CreateGameServerGroupRequest& AddVpcSubnets(VpcSubnetsT&& value) { m_vpcSubnetsHasBeenSet = true; m_vpcSubnets.emplace_back(std::forward<VpcSubnetsT>(value)); return *this; }
230
232
241 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
242 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
243 template<typename TagsT = Aws::Vector<Tag>>
244 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
245 template<typename TagsT = Aws::Vector<Tag>>
246 CreateGameServerGroupRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
247 template<typename TagsT = Tag>
248 CreateGameServerGroupRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
250 private:
251
252 Aws::String m_gameServerGroupName;
253 bool m_gameServerGroupNameHasBeenSet = false;
254
255 Aws::String m_roleArn;
256 bool m_roleArnHasBeenSet = false;
257
258 int m_minSize{0};
259 bool m_minSizeHasBeenSet = false;
260
261 int m_maxSize{0};
262 bool m_maxSizeHasBeenSet = false;
263
264 LaunchTemplateSpecification m_launchTemplate;
265 bool m_launchTemplateHasBeenSet = false;
266
267 Aws::Vector<InstanceDefinition> m_instanceDefinitions;
268 bool m_instanceDefinitionsHasBeenSet = false;
269
270 GameServerGroupAutoScalingPolicy m_autoScalingPolicy;
271 bool m_autoScalingPolicyHasBeenSet = false;
272
274 bool m_balancingStrategyHasBeenSet = false;
275
277 bool m_gameServerProtectionPolicyHasBeenSet = false;
278
279 Aws::Vector<Aws::String> m_vpcSubnets;
280 bool m_vpcSubnetsHasBeenSet = false;
281
282 Aws::Vector<Tag> m_tags;
283 bool m_tagsHasBeenSet = false;
284 };
285
286} // namespace Model
287} // namespace GameLift
288} // namespace Aws
const Aws::Vector< InstanceDefinition > & GetInstanceDefinitions() const
CreateGameServerGroupRequest & WithBalancingStrategy(BalancingStrategy value)
AWS_GAMELIFT_API CreateGameServerGroupRequest()=default
CreateGameServerGroupRequest & WithRoleArn(RoleArnT &&value)
const GameServerGroupAutoScalingPolicy & GetAutoScalingPolicy() const
CreateGameServerGroupRequest & WithInstanceDefinitions(InstanceDefinitionsT &&value)
CreateGameServerGroupRequest & WithGameServerGroupName(GameServerGroupNameT &&value)
CreateGameServerGroupRequest & WithAutoScalingPolicy(AutoScalingPolicyT &&value)
CreateGameServerGroupRequest & AddVpcSubnets(VpcSubnetsT &&value)
CreateGameServerGroupRequest & WithTags(TagsT &&value)
CreateGameServerGroupRequest & WithGameServerProtectionPolicy(GameServerProtectionPolicy value)
CreateGameServerGroupRequest & WithVpcSubnets(VpcSubnetsT &&value)
CreateGameServerGroupRequest & WithMinSize(int value)
CreateGameServerGroupRequest & WithLaunchTemplate(LaunchTemplateT &&value)
const LaunchTemplateSpecification & GetLaunchTemplate() const
const Aws::Vector< Aws::String > & GetVpcSubnets() const
void SetGameServerProtectionPolicy(GameServerProtectionPolicy value)
AWS_GAMELIFT_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateGameServerGroupRequest & AddTags(TagsT &&value)
CreateGameServerGroupRequest & AddInstanceDefinitions(InstanceDefinitionsT &&value)
AWS_GAMELIFT_API Aws::String SerializePayload() const override
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector