AWS SDK for C++

AWS SDK for C++ Version 1.11.637

Loading...
Searching...
No Matches
CreateComputeNodeGroupRequest.h
1
6#pragma once
7#include <aws/pcs/PCS_EXPORTS.h>
8#include <aws/pcs/PCSRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/pcs/model/PurchaseOption.h>
12#include <aws/pcs/model/CustomLaunchTemplate.h>
13#include <aws/pcs/model/ScalingConfigurationRequest.h>
14#include <aws/pcs/model/SpotOptions.h>
15#include <aws/pcs/model/ComputeNodeGroupSlurmConfigurationRequest.h>
16#include <aws/core/utils/memory/stl/AWSMap.h>
17#include <aws/pcs/model/InstanceConfig.h>
18#include <utility>
19#include <aws/core/utils/UUID.h>
20
21namespace Aws
22{
23namespace PCS
24{
25namespace Model
26{
27
31 {
32 public:
33 AWS_PCS_API CreateComputeNodeGroupRequest() = default;
34
35 // Service request name is the Operation name which will send this request out,
36 // each operation should has unique request name, so that we can get operation's name from this request.
37 // Note: this is not true for response, multiple operations may have the same response name,
38 // so we can not get operation's name from response.
39 inline virtual const char* GetServiceRequestName() const override { return "CreateComputeNodeGroup"; }
40
41 AWS_PCS_API Aws::String SerializePayload() const override;
42
44
45
47
50 inline const Aws::String& GetClusterIdentifier() const { return m_clusterIdentifier; }
51 inline bool ClusterIdentifierHasBeenSet() const { return m_clusterIdentifierHasBeenSet; }
52 template<typename ClusterIdentifierT = Aws::String>
53 void SetClusterIdentifier(ClusterIdentifierT&& value) { m_clusterIdentifierHasBeenSet = true; m_clusterIdentifier = std::forward<ClusterIdentifierT>(value); }
54 template<typename ClusterIdentifierT = Aws::String>
55 CreateComputeNodeGroupRequest& WithClusterIdentifier(ClusterIdentifierT&& value) { SetClusterIdentifier(std::forward<ClusterIdentifierT>(value)); return *this;}
57
59
62 inline const Aws::String& GetComputeNodeGroupName() const { return m_computeNodeGroupName; }
63 inline bool ComputeNodeGroupNameHasBeenSet() const { return m_computeNodeGroupNameHasBeenSet; }
64 template<typename ComputeNodeGroupNameT = Aws::String>
65 void SetComputeNodeGroupName(ComputeNodeGroupNameT&& value) { m_computeNodeGroupNameHasBeenSet = true; m_computeNodeGroupName = std::forward<ComputeNodeGroupNameT>(value); }
66 template<typename ComputeNodeGroupNameT = Aws::String>
67 CreateComputeNodeGroupRequest& WithComputeNodeGroupName(ComputeNodeGroupNameT&& value) { SetComputeNodeGroupName(std::forward<ComputeNodeGroupNameT>(value)); return *this;}
69
71
77 inline const Aws::String& GetAmiId() const { return m_amiId; }
78 inline bool AmiIdHasBeenSet() const { return m_amiIdHasBeenSet; }
79 template<typename AmiIdT = Aws::String>
80 void SetAmiId(AmiIdT&& value) { m_amiIdHasBeenSet = true; m_amiId = std::forward<AmiIdT>(value); }
81 template<typename AmiIdT = Aws::String>
82 CreateComputeNodeGroupRequest& WithAmiId(AmiIdT&& value) { SetAmiId(std::forward<AmiIdT>(value)); return *this;}
84
86
90 inline const Aws::Vector<Aws::String>& GetSubnetIds() const { return m_subnetIds; }
91 inline bool SubnetIdsHasBeenSet() const { return m_subnetIdsHasBeenSet; }
92 template<typename SubnetIdsT = Aws::Vector<Aws::String>>
93 void SetSubnetIds(SubnetIdsT&& value) { m_subnetIdsHasBeenSet = true; m_subnetIds = std::forward<SubnetIdsT>(value); }
94 template<typename SubnetIdsT = Aws::Vector<Aws::String>>
95 CreateComputeNodeGroupRequest& WithSubnetIds(SubnetIdsT&& value) { SetSubnetIds(std::forward<SubnetIdsT>(value)); return *this;}
96 template<typename SubnetIdsT = Aws::String>
97 CreateComputeNodeGroupRequest& AddSubnetIds(SubnetIdsT&& value) { m_subnetIdsHasBeenSet = true; m_subnetIds.emplace_back(std::forward<SubnetIdsT>(value)); return *this; }
99
101
108 inline PurchaseOption GetPurchaseOption() const { return m_purchaseOption; }
109 inline bool PurchaseOptionHasBeenSet() const { return m_purchaseOptionHasBeenSet; }
110 inline void SetPurchaseOption(PurchaseOption value) { m_purchaseOptionHasBeenSet = true; m_purchaseOption = value; }
113
115
116 inline const CustomLaunchTemplate& GetCustomLaunchTemplate() const { return m_customLaunchTemplate; }
117 inline bool CustomLaunchTemplateHasBeenSet() const { return m_customLaunchTemplateHasBeenSet; }
118 template<typename CustomLaunchTemplateT = CustomLaunchTemplate>
119 void SetCustomLaunchTemplate(CustomLaunchTemplateT&& value) { m_customLaunchTemplateHasBeenSet = true; m_customLaunchTemplate = std::forward<CustomLaunchTemplateT>(value); }
120 template<typename CustomLaunchTemplateT = CustomLaunchTemplate>
121 CreateComputeNodeGroupRequest& WithCustomLaunchTemplate(CustomLaunchTemplateT&& value) { SetCustomLaunchTemplate(std::forward<CustomLaunchTemplateT>(value)); return *this;}
123
125
134 inline const Aws::String& GetIamInstanceProfileArn() const { return m_iamInstanceProfileArn; }
135 inline bool IamInstanceProfileArnHasBeenSet() const { return m_iamInstanceProfileArnHasBeenSet; }
136 template<typename IamInstanceProfileArnT = Aws::String>
137 void SetIamInstanceProfileArn(IamInstanceProfileArnT&& value) { m_iamInstanceProfileArnHasBeenSet = true; m_iamInstanceProfileArn = std::forward<IamInstanceProfileArnT>(value); }
138 template<typename IamInstanceProfileArnT = Aws::String>
139 CreateComputeNodeGroupRequest& WithIamInstanceProfileArn(IamInstanceProfileArnT&& value) { SetIamInstanceProfileArn(std::forward<IamInstanceProfileArnT>(value)); return *this;}
141
143
146 inline const ScalingConfigurationRequest& GetScalingConfiguration() const { return m_scalingConfiguration; }
147 inline bool ScalingConfigurationHasBeenSet() const { return m_scalingConfigurationHasBeenSet; }
148 template<typename ScalingConfigurationT = ScalingConfigurationRequest>
149 void SetScalingConfiguration(ScalingConfigurationT&& value) { m_scalingConfigurationHasBeenSet = true; m_scalingConfiguration = std::forward<ScalingConfigurationT>(value); }
150 template<typename ScalingConfigurationT = ScalingConfigurationRequest>
151 CreateComputeNodeGroupRequest& WithScalingConfiguration(ScalingConfigurationT&& value) { SetScalingConfiguration(std::forward<ScalingConfigurationT>(value)); return *this;}
153
155
159 inline const Aws::Vector<InstanceConfig>& GetInstanceConfigs() const { return m_instanceConfigs; }
160 inline bool InstanceConfigsHasBeenSet() const { return m_instanceConfigsHasBeenSet; }
161 template<typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
162 void SetInstanceConfigs(InstanceConfigsT&& value) { m_instanceConfigsHasBeenSet = true; m_instanceConfigs = std::forward<InstanceConfigsT>(value); }
163 template<typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
164 CreateComputeNodeGroupRequest& WithInstanceConfigs(InstanceConfigsT&& value) { SetInstanceConfigs(std::forward<InstanceConfigsT>(value)); return *this;}
165 template<typename InstanceConfigsT = InstanceConfig>
166 CreateComputeNodeGroupRequest& AddInstanceConfigs(InstanceConfigsT&& value) { m_instanceConfigsHasBeenSet = true; m_instanceConfigs.emplace_back(std::forward<InstanceConfigsT>(value)); return *this; }
168
170
171 inline const SpotOptions& GetSpotOptions() const { return m_spotOptions; }
172 inline bool SpotOptionsHasBeenSet() const { return m_spotOptionsHasBeenSet; }
173 template<typename SpotOptionsT = SpotOptions>
174 void SetSpotOptions(SpotOptionsT&& value) { m_spotOptionsHasBeenSet = true; m_spotOptions = std::forward<SpotOptionsT>(value); }
175 template<typename SpotOptionsT = SpotOptions>
176 CreateComputeNodeGroupRequest& WithSpotOptions(SpotOptionsT&& value) { SetSpotOptions(std::forward<SpotOptionsT>(value)); return *this;}
178
180
183 inline const ComputeNodeGroupSlurmConfigurationRequest& GetSlurmConfiguration() const { return m_slurmConfiguration; }
184 inline bool SlurmConfigurationHasBeenSet() const { return m_slurmConfigurationHasBeenSet; }
185 template<typename SlurmConfigurationT = ComputeNodeGroupSlurmConfigurationRequest>
186 void SetSlurmConfiguration(SlurmConfigurationT&& value) { m_slurmConfigurationHasBeenSet = true; m_slurmConfiguration = std::forward<SlurmConfigurationT>(value); }
187 template<typename SlurmConfigurationT = ComputeNodeGroupSlurmConfigurationRequest>
188 CreateComputeNodeGroupRequest& WithSlurmConfiguration(SlurmConfigurationT&& value) { SetSlurmConfiguration(std::forward<SlurmConfigurationT>(value)); return *this;}
190
192
201 inline const Aws::String& GetClientToken() const { return m_clientToken; }
202 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
203 template<typename ClientTokenT = Aws::String>
204 void SetClientToken(ClientTokenT&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::forward<ClientTokenT>(value); }
205 template<typename ClientTokenT = Aws::String>
206 CreateComputeNodeGroupRequest& WithClientToken(ClientTokenT&& value) { SetClientToken(std::forward<ClientTokenT>(value)); return *this;}
208
210
214 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
215 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
216 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
217 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
218 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
219 CreateComputeNodeGroupRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
220 template<typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
221 CreateComputeNodeGroupRequest& AddTags(TagsKeyT&& key, TagsValueT&& value) {
222 m_tagsHasBeenSet = true; m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value)); return *this;
223 }
225 private:
226
227 Aws::String m_clusterIdentifier;
228 bool m_clusterIdentifierHasBeenSet = false;
229
230 Aws::String m_computeNodeGroupName;
231 bool m_computeNodeGroupNameHasBeenSet = false;
232
233 Aws::String m_amiId;
234 bool m_amiIdHasBeenSet = false;
235
236 Aws::Vector<Aws::String> m_subnetIds;
237 bool m_subnetIdsHasBeenSet = false;
238
239 PurchaseOption m_purchaseOption{PurchaseOption::NOT_SET};
240 bool m_purchaseOptionHasBeenSet = false;
241
242 CustomLaunchTemplate m_customLaunchTemplate;
243 bool m_customLaunchTemplateHasBeenSet = false;
244
245 Aws::String m_iamInstanceProfileArn;
246 bool m_iamInstanceProfileArnHasBeenSet = false;
247
248 ScalingConfigurationRequest m_scalingConfiguration;
249 bool m_scalingConfigurationHasBeenSet = false;
250
251 Aws::Vector<InstanceConfig> m_instanceConfigs;
252 bool m_instanceConfigsHasBeenSet = false;
253
254 SpotOptions m_spotOptions;
255 bool m_spotOptionsHasBeenSet = false;
256
257 ComputeNodeGroupSlurmConfigurationRequest m_slurmConfiguration;
258 bool m_slurmConfigurationHasBeenSet = false;
259
261 bool m_clientTokenHasBeenSet = true;
262
264 bool m_tagsHasBeenSet = false;
265 };
266
267} // namespace Model
268} // namespace PCS
269} // namespace Aws
void SetIamInstanceProfileArn(IamInstanceProfileArnT &&value)
const Aws::Vector< Aws::String > & GetSubnetIds() const
CreateComputeNodeGroupRequest & WithCustomLaunchTemplate(CustomLaunchTemplateT &&value)
CreateComputeNodeGroupRequest & WithInstanceConfigs(InstanceConfigsT &&value)
CreateComputeNodeGroupRequest & WithSubnetIds(SubnetIdsT &&value)
const ScalingConfigurationRequest & GetScalingConfiguration() const
CreateComputeNodeGroupRequest & AddInstanceConfigs(InstanceConfigsT &&value)
CreateComputeNodeGroupRequest & WithClusterIdentifier(ClusterIdentifierT &&value)
CreateComputeNodeGroupRequest & WithIamInstanceProfileArn(IamInstanceProfileArnT &&value)
AWS_PCS_API Aws::String SerializePayload() const override
const ComputeNodeGroupSlurmConfigurationRequest & GetSlurmConfiguration() const
CreateComputeNodeGroupRequest & WithScalingConfiguration(ScalingConfigurationT &&value)
const Aws::Vector< InstanceConfig > & GetInstanceConfigs() const
CreateComputeNodeGroupRequest & WithPurchaseOption(PurchaseOption value)
void SetComputeNodeGroupName(ComputeNodeGroupNameT &&value)
const CustomLaunchTemplate & GetCustomLaunchTemplate() const
CreateComputeNodeGroupRequest & AddSubnetIds(SubnetIdsT &&value)
CreateComputeNodeGroupRequest & AddTags(TagsKeyT &&key, TagsValueT &&value)
CreateComputeNodeGroupRequest & WithClientToken(ClientTokenT &&value)
CreateComputeNodeGroupRequest & WithAmiId(AmiIdT &&value)
CreateComputeNodeGroupRequest & WithComputeNodeGroupName(ComputeNodeGroupNameT &&value)
CreateComputeNodeGroupRequest & WithSlurmConfiguration(SlurmConfigurationT &&value)
CreateComputeNodeGroupRequest & WithTags(TagsT &&value)
CreateComputeNodeGroupRequest & WithSpotOptions(SpotOptionsT &&value)
const Aws::Map< Aws::String, Aws::String > & GetTags() const
virtual const char * GetServiceRequestName() const override
AWS_PCS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
static Aws::Utils::UUID PseudoRandomUUID()
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
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
std::vector< T, Aws::Allocator< T > > Vector