AWS SDK for C++

AWS SDK for C++ Version 1.11.606

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
137 inline const Aws::String& GetIamInstanceProfileArn() const { return m_iamInstanceProfileArn; }
138 inline bool IamInstanceProfileArnHasBeenSet() const { return m_iamInstanceProfileArnHasBeenSet; }
139 template<typename IamInstanceProfileArnT = Aws::String>
140 void SetIamInstanceProfileArn(IamInstanceProfileArnT&& value) { m_iamInstanceProfileArnHasBeenSet = true; m_iamInstanceProfileArn = std::forward<IamInstanceProfileArnT>(value); }
141 template<typename IamInstanceProfileArnT = Aws::String>
142 CreateComputeNodeGroupRequest& WithIamInstanceProfileArn(IamInstanceProfileArnT&& value) { SetIamInstanceProfileArn(std::forward<IamInstanceProfileArnT>(value)); return *this;}
144
146
149 inline const ScalingConfigurationRequest& GetScalingConfiguration() const { return m_scalingConfiguration; }
150 inline bool ScalingConfigurationHasBeenSet() const { return m_scalingConfigurationHasBeenSet; }
151 template<typename ScalingConfigurationT = ScalingConfigurationRequest>
152 void SetScalingConfiguration(ScalingConfigurationT&& value) { m_scalingConfigurationHasBeenSet = true; m_scalingConfiguration = std::forward<ScalingConfigurationT>(value); }
153 template<typename ScalingConfigurationT = ScalingConfigurationRequest>
154 CreateComputeNodeGroupRequest& WithScalingConfiguration(ScalingConfigurationT&& value) { SetScalingConfiguration(std::forward<ScalingConfigurationT>(value)); return *this;}
156
158
162 inline const Aws::Vector<InstanceConfig>& GetInstanceConfigs() const { return m_instanceConfigs; }
163 inline bool InstanceConfigsHasBeenSet() const { return m_instanceConfigsHasBeenSet; }
164 template<typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
165 void SetInstanceConfigs(InstanceConfigsT&& value) { m_instanceConfigsHasBeenSet = true; m_instanceConfigs = std::forward<InstanceConfigsT>(value); }
166 template<typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
167 CreateComputeNodeGroupRequest& WithInstanceConfigs(InstanceConfigsT&& value) { SetInstanceConfigs(std::forward<InstanceConfigsT>(value)); return *this;}
168 template<typename InstanceConfigsT = InstanceConfig>
169 CreateComputeNodeGroupRequest& AddInstanceConfigs(InstanceConfigsT&& value) { m_instanceConfigsHasBeenSet = true; m_instanceConfigs.emplace_back(std::forward<InstanceConfigsT>(value)); return *this; }
171
173
174 inline const SpotOptions& GetSpotOptions() const { return m_spotOptions; }
175 inline bool SpotOptionsHasBeenSet() const { return m_spotOptionsHasBeenSet; }
176 template<typename SpotOptionsT = SpotOptions>
177 void SetSpotOptions(SpotOptionsT&& value) { m_spotOptionsHasBeenSet = true; m_spotOptions = std::forward<SpotOptionsT>(value); }
178 template<typename SpotOptionsT = SpotOptions>
179 CreateComputeNodeGroupRequest& WithSpotOptions(SpotOptionsT&& value) { SetSpotOptions(std::forward<SpotOptionsT>(value)); return *this;}
181
183
186 inline const ComputeNodeGroupSlurmConfigurationRequest& GetSlurmConfiguration() const { return m_slurmConfiguration; }
187 inline bool SlurmConfigurationHasBeenSet() const { return m_slurmConfigurationHasBeenSet; }
188 template<typename SlurmConfigurationT = ComputeNodeGroupSlurmConfigurationRequest>
189 void SetSlurmConfiguration(SlurmConfigurationT&& value) { m_slurmConfigurationHasBeenSet = true; m_slurmConfiguration = std::forward<SlurmConfigurationT>(value); }
190 template<typename SlurmConfigurationT = ComputeNodeGroupSlurmConfigurationRequest>
191 CreateComputeNodeGroupRequest& WithSlurmConfiguration(SlurmConfigurationT&& value) { SetSlurmConfiguration(std::forward<SlurmConfigurationT>(value)); return *this;}
193
195
204 inline const Aws::String& GetClientToken() const { return m_clientToken; }
205 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
206 template<typename ClientTokenT = Aws::String>
207 void SetClientToken(ClientTokenT&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::forward<ClientTokenT>(value); }
208 template<typename ClientTokenT = Aws::String>
209 CreateComputeNodeGroupRequest& WithClientToken(ClientTokenT&& value) { SetClientToken(std::forward<ClientTokenT>(value)); return *this;}
211
213
217 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
218 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
219 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
220 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
221 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
222 CreateComputeNodeGroupRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
223 template<typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
224 CreateComputeNodeGroupRequest& AddTags(TagsKeyT&& key, TagsValueT&& value) {
225 m_tagsHasBeenSet = true; m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value)); return *this;
226 }
228 private:
229
230 Aws::String m_clusterIdentifier;
231 bool m_clusterIdentifierHasBeenSet = false;
232
233 Aws::String m_computeNodeGroupName;
234 bool m_computeNodeGroupNameHasBeenSet = false;
235
236 Aws::String m_amiId;
237 bool m_amiIdHasBeenSet = false;
238
239 Aws::Vector<Aws::String> m_subnetIds;
240 bool m_subnetIdsHasBeenSet = false;
241
242 PurchaseOption m_purchaseOption{PurchaseOption::NOT_SET};
243 bool m_purchaseOptionHasBeenSet = false;
244
245 CustomLaunchTemplate m_customLaunchTemplate;
246 bool m_customLaunchTemplateHasBeenSet = false;
247
248 Aws::String m_iamInstanceProfileArn;
249 bool m_iamInstanceProfileArnHasBeenSet = false;
250
251 ScalingConfigurationRequest m_scalingConfiguration;
252 bool m_scalingConfigurationHasBeenSet = false;
253
254 Aws::Vector<InstanceConfig> m_instanceConfigs;
255 bool m_instanceConfigsHasBeenSet = false;
256
257 SpotOptions m_spotOptions;
258 bool m_spotOptionsHasBeenSet = false;
259
260 ComputeNodeGroupSlurmConfigurationRequest m_slurmConfiguration;
261 bool m_slurmConfigurationHasBeenSet = false;
262
264 bool m_clientTokenHasBeenSet = true;
265
267 bool m_tagsHasBeenSet = false;
268 };
269
270} // namespace Model
271} // namespace PCS
272} // 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