AWS SDK for C++

AWS SDK for C++ Version 1.11.852

Loading...
Searching...
No Matches
ComputeNodeGroup.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/pcs/PCS_EXPORTS.h>
11#include <aws/pcs/model/ComputeNodeGroupSlurmConfiguration.h>
12#include <aws/pcs/model/ComputeNodeGroupStatus.h>
13#include <aws/pcs/model/CustomLaunchTemplate.h>
14#include <aws/pcs/model/ErrorInfo.h>
15#include <aws/pcs/model/InstanceConfig.h>
16#include <aws/pcs/model/NodeLifecycleActions.h>
17#include <aws/pcs/model/PurchaseOption.h>
18#include <aws/pcs/model/ScalingConfiguration.h>
19#include <aws/pcs/model/SpotOptions.h>
20
21#include <utility>
22
23namespace Aws {
24namespace Utils {
25namespace Json {
26class JsonValue;
27class JsonView;
28} // namespace Json
29} // namespace Utils
30namespace PCS {
31namespace Model {
32
39 public:
40 AWS_PCS_API ComputeNodeGroup() = default;
44
46
49 inline const Aws::String& GetName() const { return m_name; }
50 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
51 template <typename NameT = Aws::String>
52 void SetName(NameT&& value) {
53 m_nameHasBeenSet = true;
54 m_name = std::forward<NameT>(value);
55 }
56 template <typename NameT = Aws::String>
57 ComputeNodeGroup& WithName(NameT&& value) {
58 SetName(std::forward<NameT>(value));
59 return *this;
60 }
62
64
67 inline const Aws::String& GetId() const { return m_id; }
68 inline bool IdHasBeenSet() const { return m_idHasBeenSet; }
69 template <typename IdT = Aws::String>
70 void SetId(IdT&& value) {
71 m_idHasBeenSet = true;
72 m_id = std::forward<IdT>(value);
73 }
74 template <typename IdT = Aws::String>
75 ComputeNodeGroup& WithId(IdT&& value) {
76 SetId(std::forward<IdT>(value));
77 return *this;
78 }
80
82
85 inline const Aws::String& GetArn() const { return m_arn; }
86 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
87 template <typename ArnT = Aws::String>
88 void SetArn(ArnT&& value) {
89 m_arnHasBeenSet = true;
90 m_arn = std::forward<ArnT>(value);
91 }
92 template <typename ArnT = Aws::String>
93 ComputeNodeGroup& WithArn(ArnT&& value) {
94 SetArn(std::forward<ArnT>(value));
95 return *this;
96 }
98
100
103 inline const Aws::String& GetClusterId() const { return m_clusterId; }
104 inline bool ClusterIdHasBeenSet() const { return m_clusterIdHasBeenSet; }
105 template <typename ClusterIdT = Aws::String>
106 void SetClusterId(ClusterIdT&& value) {
107 m_clusterIdHasBeenSet = true;
108 m_clusterId = std::forward<ClusterIdT>(value);
109 }
110 template <typename ClusterIdT = Aws::String>
111 ComputeNodeGroup& WithClusterId(ClusterIdT&& value) {
112 SetClusterId(std::forward<ClusterIdT>(value));
113 return *this;
114 }
116
118
121 inline const Aws::Utils::DateTime& GetCreatedAt() const { return m_createdAt; }
122 inline bool CreatedAtHasBeenSet() const { return m_createdAtHasBeenSet; }
123 template <typename CreatedAtT = Aws::Utils::DateTime>
124 void SetCreatedAt(CreatedAtT&& value) {
125 m_createdAtHasBeenSet = true;
126 m_createdAt = std::forward<CreatedAtT>(value);
127 }
128 template <typename CreatedAtT = Aws::Utils::DateTime>
129 ComputeNodeGroup& WithCreatedAt(CreatedAtT&& value) {
130 SetCreatedAt(std::forward<CreatedAtT>(value));
131 return *this;
132 }
134
136
139 inline const Aws::Utils::DateTime& GetModifiedAt() const { return m_modifiedAt; }
140 inline bool ModifiedAtHasBeenSet() const { return m_modifiedAtHasBeenSet; }
141 template <typename ModifiedAtT = Aws::Utils::DateTime>
142 void SetModifiedAt(ModifiedAtT&& value) {
143 m_modifiedAtHasBeenSet = true;
144 m_modifiedAt = std::forward<ModifiedAtT>(value);
145 }
146 template <typename ModifiedAtT = Aws::Utils::DateTime>
147 ComputeNodeGroup& WithModifiedAt(ModifiedAtT&& value) {
148 SetModifiedAt(std::forward<ModifiedAtT>(value));
149 return *this;
150 }
152
154
168 inline ComputeNodeGroupStatus GetStatus() const { return m_status; }
169 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
171 m_statusHasBeenSet = true;
172 m_status = value;
173 }
175 SetStatus(value);
176 return *this;
177 }
179
181
186 inline const Aws::String& GetAmiId() const { return m_amiId; }
187 inline bool AmiIdHasBeenSet() const { return m_amiIdHasBeenSet; }
188 template <typename AmiIdT = Aws::String>
189 void SetAmiId(AmiIdT&& value) {
190 m_amiIdHasBeenSet = true;
191 m_amiId = std::forward<AmiIdT>(value);
192 }
193 template <typename AmiIdT = Aws::String>
194 ComputeNodeGroup& WithAmiId(AmiIdT&& value) {
195 SetAmiId(std::forward<AmiIdT>(value));
196 return *this;
197 }
199
201
205 inline const Aws::Vector<Aws::String>& GetSubnetIds() const { return m_subnetIds; }
206 inline bool SubnetIdsHasBeenSet() const { return m_subnetIdsHasBeenSet; }
207 template <typename SubnetIdsT = Aws::Vector<Aws::String>>
208 void SetSubnetIds(SubnetIdsT&& value) {
209 m_subnetIdsHasBeenSet = true;
210 m_subnetIds = std::forward<SubnetIdsT>(value);
211 }
212 template <typename SubnetIdsT = Aws::Vector<Aws::String>>
213 ComputeNodeGroup& WithSubnetIds(SubnetIdsT&& value) {
214 SetSubnetIds(std::forward<SubnetIdsT>(value));
215 return *this;
216 }
217 template <typename SubnetIdsT = Aws::String>
218 ComputeNodeGroup& AddSubnetIds(SubnetIdsT&& value) {
219 m_subnetIdsHasBeenSet = true;
220 m_subnetIds.emplace_back(std::forward<SubnetIdsT>(value));
221 return *this;
222 }
224
226
246 inline PurchaseOption GetPurchaseOption() const { return m_purchaseOption; }
247 inline bool PurchaseOptionHasBeenSet() const { return m_purchaseOptionHasBeenSet; }
249 m_purchaseOptionHasBeenSet = true;
250 m_purchaseOption = value;
251 }
253 SetPurchaseOption(value);
254 return *this;
255 }
257
259
260 inline const CustomLaunchTemplate& GetCustomLaunchTemplate() const { return m_customLaunchTemplate; }
261 inline bool CustomLaunchTemplateHasBeenSet() const { return m_customLaunchTemplateHasBeenSet; }
262 template <typename CustomLaunchTemplateT = CustomLaunchTemplate>
263 void SetCustomLaunchTemplate(CustomLaunchTemplateT&& value) {
264 m_customLaunchTemplateHasBeenSet = true;
265 m_customLaunchTemplate = std::forward<CustomLaunchTemplateT>(value);
266 }
267 template <typename CustomLaunchTemplateT = CustomLaunchTemplate>
268 ComputeNodeGroup& WithCustomLaunchTemplate(CustomLaunchTemplateT&& value) {
269 SetCustomLaunchTemplate(std::forward<CustomLaunchTemplateT>(value));
270 return *this;
271 }
273
275
284 inline const Aws::String& GetIamInstanceProfileArn() const { return m_iamInstanceProfileArn; }
285 inline bool IamInstanceProfileArnHasBeenSet() const { return m_iamInstanceProfileArnHasBeenSet; }
286 template <typename IamInstanceProfileArnT = Aws::String>
287 void SetIamInstanceProfileArn(IamInstanceProfileArnT&& value) {
288 m_iamInstanceProfileArnHasBeenSet = true;
289 m_iamInstanceProfileArn = std::forward<IamInstanceProfileArnT>(value);
290 }
291 template <typename IamInstanceProfileArnT = Aws::String>
292 ComputeNodeGroup& WithIamInstanceProfileArn(IamInstanceProfileArnT&& value) {
293 SetIamInstanceProfileArn(std::forward<IamInstanceProfileArnT>(value));
294 return *this;
295 }
297
299
300 inline const ScalingConfiguration& GetScalingConfiguration() const { return m_scalingConfiguration; }
301 inline bool ScalingConfigurationHasBeenSet() const { return m_scalingConfigurationHasBeenSet; }
302 template <typename ScalingConfigurationT = ScalingConfiguration>
303 void SetScalingConfiguration(ScalingConfigurationT&& value) {
304 m_scalingConfigurationHasBeenSet = true;
305 m_scalingConfiguration = std::forward<ScalingConfigurationT>(value);
306 }
307 template <typename ScalingConfigurationT = ScalingConfiguration>
308 ComputeNodeGroup& WithScalingConfiguration(ScalingConfigurationT&& value) {
309 SetScalingConfiguration(std::forward<ScalingConfigurationT>(value));
310 return *this;
311 }
313
315
319 inline const Aws::Vector<InstanceConfig>& GetInstanceConfigs() const { return m_instanceConfigs; }
320 inline bool InstanceConfigsHasBeenSet() const { return m_instanceConfigsHasBeenSet; }
321 template <typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
322 void SetInstanceConfigs(InstanceConfigsT&& value) {
323 m_instanceConfigsHasBeenSet = true;
324 m_instanceConfigs = std::forward<InstanceConfigsT>(value);
325 }
326 template <typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
327 ComputeNodeGroup& WithInstanceConfigs(InstanceConfigsT&& value) {
328 SetInstanceConfigs(std::forward<InstanceConfigsT>(value));
329 return *this;
330 }
331 template <typename InstanceConfigsT = InstanceConfig>
332 ComputeNodeGroup& AddInstanceConfigs(InstanceConfigsT&& value) {
333 m_instanceConfigsHasBeenSet = true;
334 m_instanceConfigs.emplace_back(std::forward<InstanceConfigsT>(value));
335 return *this;
336 }
338
340
341 inline const SpotOptions& GetSpotOptions() const { return m_spotOptions; }
342 inline bool SpotOptionsHasBeenSet() const { return m_spotOptionsHasBeenSet; }
343 template <typename SpotOptionsT = SpotOptions>
344 void SetSpotOptions(SpotOptionsT&& value) {
345 m_spotOptionsHasBeenSet = true;
346 m_spotOptions = std::forward<SpotOptionsT>(value);
347 }
348 template <typename SpotOptionsT = SpotOptions>
349 ComputeNodeGroup& WithSpotOptions(SpotOptionsT&& value) {
350 SetSpotOptions(std::forward<SpotOptionsT>(value));
351 return *this;
352 }
354
356
357 inline const ComputeNodeGroupSlurmConfiguration& GetSlurmConfiguration() const { return m_slurmConfiguration; }
358 inline bool SlurmConfigurationHasBeenSet() const { return m_slurmConfigurationHasBeenSet; }
359 template <typename SlurmConfigurationT = ComputeNodeGroupSlurmConfiguration>
360 void SetSlurmConfiguration(SlurmConfigurationT&& value) {
361 m_slurmConfigurationHasBeenSet = true;
362 m_slurmConfiguration = std::forward<SlurmConfigurationT>(value);
363 }
364 template <typename SlurmConfigurationT = ComputeNodeGroupSlurmConfiguration>
365 ComputeNodeGroup& WithSlurmConfiguration(SlurmConfigurationT&& value) {
366 SetSlurmConfiguration(std::forward<SlurmConfigurationT>(value));
367 return *this;
368 }
370
372
378 inline const NodeLifecycleActions& GetNodeLifecycleActions() const { return m_nodeLifecycleActions; }
379 inline bool NodeLifecycleActionsHasBeenSet() const { return m_nodeLifecycleActionsHasBeenSet; }
380 template <typename NodeLifecycleActionsT = NodeLifecycleActions>
381 void SetNodeLifecycleActions(NodeLifecycleActionsT&& value) {
382 m_nodeLifecycleActionsHasBeenSet = true;
383 m_nodeLifecycleActions = std::forward<NodeLifecycleActionsT>(value);
384 }
385 template <typename NodeLifecycleActionsT = NodeLifecycleActions>
386 ComputeNodeGroup& WithNodeLifecycleActions(NodeLifecycleActionsT&& value) {
387 SetNodeLifecycleActions(std::forward<NodeLifecycleActionsT>(value));
388 return *this;
389 }
391
393
396 inline const Aws::Vector<ErrorInfo>& GetErrorInfo() const { return m_errorInfo; }
397 inline bool ErrorInfoHasBeenSet() const { return m_errorInfoHasBeenSet; }
398 template <typename ErrorInfoT = Aws::Vector<ErrorInfo>>
399 void SetErrorInfo(ErrorInfoT&& value) {
400 m_errorInfoHasBeenSet = true;
401 m_errorInfo = std::forward<ErrorInfoT>(value);
402 }
403 template <typename ErrorInfoT = Aws::Vector<ErrorInfo>>
404 ComputeNodeGroup& WithErrorInfo(ErrorInfoT&& value) {
405 SetErrorInfo(std::forward<ErrorInfoT>(value));
406 return *this;
407 }
408 template <typename ErrorInfoT = ErrorInfo>
409 ComputeNodeGroup& AddErrorInfo(ErrorInfoT&& value) {
410 m_errorInfoHasBeenSet = true;
411 m_errorInfo.emplace_back(std::forward<ErrorInfoT>(value));
412 return *this;
413 }
415 private:
416 Aws::String m_name;
417
418 Aws::String m_id;
419
420 Aws::String m_arn;
421
422 Aws::String m_clusterId;
423
424 Aws::Utils::DateTime m_createdAt{};
425
426 Aws::Utils::DateTime m_modifiedAt{};
427
429
430 Aws::String m_amiId;
431
432 Aws::Vector<Aws::String> m_subnetIds;
433
434 PurchaseOption m_purchaseOption{PurchaseOption::NOT_SET};
435
436 CustomLaunchTemplate m_customLaunchTemplate;
437
438 Aws::String m_iamInstanceProfileArn;
439
440 ScalingConfiguration m_scalingConfiguration;
441
442 Aws::Vector<InstanceConfig> m_instanceConfigs;
443
444 SpotOptions m_spotOptions;
445
446 ComputeNodeGroupSlurmConfiguration m_slurmConfiguration;
447
448 NodeLifecycleActions m_nodeLifecycleActions;
449
450 Aws::Vector<ErrorInfo> m_errorInfo;
451 bool m_nameHasBeenSet = false;
452 bool m_idHasBeenSet = false;
453 bool m_arnHasBeenSet = false;
454 bool m_clusterIdHasBeenSet = false;
455 bool m_createdAtHasBeenSet = false;
456 bool m_modifiedAtHasBeenSet = false;
457 bool m_statusHasBeenSet = false;
458 bool m_amiIdHasBeenSet = false;
459 bool m_subnetIdsHasBeenSet = false;
460 bool m_purchaseOptionHasBeenSet = false;
461 bool m_customLaunchTemplateHasBeenSet = false;
462 bool m_iamInstanceProfileArnHasBeenSet = false;
463 bool m_scalingConfigurationHasBeenSet = false;
464 bool m_instanceConfigsHasBeenSet = false;
465 bool m_spotOptionsHasBeenSet = false;
466 bool m_slurmConfigurationHasBeenSet = false;
467 bool m_nodeLifecycleActionsHasBeenSet = false;
468 bool m_errorInfoHasBeenSet = false;
469};
470
471} // namespace Model
472} // namespace PCS
473} // namespace Aws
ComputeNodeGroup & AddSubnetIds(SubnetIdsT &&value)
ComputeNodeGroupStatus GetStatus() const
void SetScalingConfiguration(ScalingConfigurationT &&value)
const Aws::Utils::DateTime & GetCreatedAt() const
ComputeNodeGroup & WithPurchaseOption(PurchaseOption value)
const Aws::String & GetIamInstanceProfileArn() const
void SetPurchaseOption(PurchaseOption value)
const ComputeNodeGroupSlurmConfiguration & GetSlurmConfiguration() const
const Aws::Vector< ErrorInfo > & GetErrorInfo() const
const Aws::String & GetId() const
ComputeNodeGroup & WithClusterId(ClusterIdT &&value)
const Aws::String & GetClusterId() const
void SetErrorInfo(ErrorInfoT &&value)
const Aws::Vector< Aws::String > & GetSubnetIds() const
const NodeLifecycleActions & GetNodeLifecycleActions() const
const SpotOptions & GetSpotOptions() const
ComputeNodeGroup & WithCustomLaunchTemplate(CustomLaunchTemplateT &&value)
ComputeNodeGroup & WithAmiId(AmiIdT &&value)
ComputeNodeGroup & WithSpotOptions(SpotOptionsT &&value)
ComputeNodeGroup & WithName(NameT &&value)
AWS_PCS_API ComputeNodeGroup()=default
void SetModifiedAt(ModifiedAtT &&value)
ComputeNodeGroup & WithInstanceConfigs(InstanceConfigsT &&value)
void SetStatus(ComputeNodeGroupStatus value)
ComputeNodeGroup & WithId(IdT &&value)
ComputeNodeGroup & WithModifiedAt(ModifiedAtT &&value)
void SetClusterId(ClusterIdT &&value)
AWS_PCS_API Aws::Utils::Json::JsonValue Jsonize() const
void SetSubnetIds(SubnetIdsT &&value)
void SetCustomLaunchTemplate(CustomLaunchTemplateT &&value)
ComputeNodeGroup & WithIamInstanceProfileArn(IamInstanceProfileArnT &&value)
ComputeNodeGroup & WithArn(ArnT &&value)
ComputeNodeGroup & WithSubnetIds(SubnetIdsT &&value)
const Aws::String & GetAmiId() const
ComputeNodeGroup & WithCreatedAt(CreatedAtT &&value)
const Aws::Utils::DateTime & GetModifiedAt() const
PurchaseOption GetPurchaseOption() const
const Aws::Vector< InstanceConfig > & GetInstanceConfigs() const
ComputeNodeGroup & WithStatus(ComputeNodeGroupStatus value)
void SetSlurmConfiguration(SlurmConfigurationT &&value)
const Aws::String & GetArn() const
ComputeNodeGroup & AddInstanceConfigs(InstanceConfigsT &&value)
void SetNodeLifecycleActions(NodeLifecycleActionsT &&value)
ComputeNodeGroup & WithScalingConfiguration(ScalingConfigurationT &&value)
ComputeNodeGroup & WithSlurmConfiguration(SlurmConfigurationT &&value)
const Aws::String & GetName() const
void SetInstanceConfigs(InstanceConfigsT &&value)
void SetCreatedAt(CreatedAtT &&value)
const CustomLaunchTemplate & GetCustomLaunchTemplate() const
void SetSpotOptions(SpotOptionsT &&value)
ComputeNodeGroup & WithErrorInfo(ErrorInfoT &&value)
void SetIamInstanceProfileArn(IamInstanceProfileArnT &&value)
ComputeNodeGroup & WithNodeLifecycleActions(NodeLifecycleActionsT &&value)
AWS_PCS_API ComputeNodeGroup & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_PCS_API ComputeNodeGroup(Aws::Utils::Json::JsonView jsonValue)
const ScalingConfiguration & GetScalingConfiguration() const
ComputeNodeGroup & AddErrorInfo(ErrorInfoT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue