AWS SDK for C++

AWS SDK for C++ Version 1.11.927

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/LaunchTemplateMode.h>
17#include <aws/pcs/model/NodeLifecycleActions.h>
18#include <aws/pcs/model/PurchaseOption.h>
19#include <aws/pcs/model/ScalingConfiguration.h>
20#include <aws/pcs/model/SpotOptions.h>
21
22#include <utility>
23
24namespace Aws {
25namespace Utils {
26namespace Json {
27class JsonValue;
28class JsonView;
29} // namespace Json
30} // namespace Utils
31namespace PCS {
32namespace Model {
33
40 public:
41 AWS_PCS_API ComputeNodeGroup() = default;
45
47
51 inline const Aws::String& GetAmiId() const { return m_amiId; }
52 inline bool AmiIdHasBeenSet() const { return m_amiIdHasBeenSet; }
53 template <typename AmiIdT = Aws::String>
54 void SetAmiId(AmiIdT&& value) {
55 m_amiIdHasBeenSet = true;
56 m_amiId = std::forward<AmiIdT>(value);
57 }
58 template <typename AmiIdT = Aws::String>
59 ComputeNodeGroup& WithAmiId(AmiIdT&& value) {
60 SetAmiId(std::forward<AmiIdT>(value));
61 return *this;
62 }
64
66
73 inline const Aws::Vector<Aws::String>& GetSecurityGroupIds() const { return m_securityGroupIds; }
74 inline bool SecurityGroupIdsHasBeenSet() const { return m_securityGroupIdsHasBeenSet; }
75 template <typename SecurityGroupIdsT = Aws::Vector<Aws::String>>
76 void SetSecurityGroupIds(SecurityGroupIdsT&& value) {
77 m_securityGroupIdsHasBeenSet = true;
78 m_securityGroupIds = std::forward<SecurityGroupIdsT>(value);
79 }
80 template <typename SecurityGroupIdsT = Aws::Vector<Aws::String>>
81 ComputeNodeGroup& WithSecurityGroupIds(SecurityGroupIdsT&& value) {
82 SetSecurityGroupIds(std::forward<SecurityGroupIdsT>(value));
83 return *this;
84 }
85 template <typename SecurityGroupIdsT = Aws::String>
86 ComputeNodeGroup& AddSecurityGroupIds(SecurityGroupIdsT&& value) {
87 m_securityGroupIdsHasBeenSet = true;
88 m_securityGroupIds.emplace_back(std::forward<SecurityGroupIdsT>(value));
89 return *this;
90 }
92
94
101 inline const Aws::String& GetSshKeyName() const { return m_sshKeyName; }
102 inline bool SshKeyNameHasBeenSet() const { return m_sshKeyNameHasBeenSet; }
103 template <typename SshKeyNameT = Aws::String>
104 void SetSshKeyName(SshKeyNameT&& value) {
105 m_sshKeyNameHasBeenSet = true;
106 m_sshKeyName = std::forward<SshKeyNameT>(value);
107 }
108 template <typename SshKeyNameT = Aws::String>
109 ComputeNodeGroup& WithSshKeyName(SshKeyNameT&& value) {
110 SetSshKeyName(std::forward<SshKeyNameT>(value));
111 return *this;
112 }
114
116
119 inline const Aws::String& GetName() const { return m_name; }
120 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
121 template <typename NameT = Aws::String>
122 void SetName(NameT&& value) {
123 m_nameHasBeenSet = true;
124 m_name = std::forward<NameT>(value);
125 }
126 template <typename NameT = Aws::String>
127 ComputeNodeGroup& WithName(NameT&& value) {
128 SetName(std::forward<NameT>(value));
129 return *this;
130 }
132
134
137 inline const Aws::String& GetId() const { return m_id; }
138 inline bool IdHasBeenSet() const { return m_idHasBeenSet; }
139 template <typename IdT = Aws::String>
140 void SetId(IdT&& value) {
141 m_idHasBeenSet = true;
142 m_id = std::forward<IdT>(value);
143 }
144 template <typename IdT = Aws::String>
145 ComputeNodeGroup& WithId(IdT&& value) {
146 SetId(std::forward<IdT>(value));
147 return *this;
148 }
150
152
155 inline const Aws::String& GetArn() const { return m_arn; }
156 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
157 template <typename ArnT = Aws::String>
158 void SetArn(ArnT&& value) {
159 m_arnHasBeenSet = true;
160 m_arn = std::forward<ArnT>(value);
161 }
162 template <typename ArnT = Aws::String>
163 ComputeNodeGroup& WithArn(ArnT&& value) {
164 SetArn(std::forward<ArnT>(value));
165 return *this;
166 }
168
170
173 inline const Aws::String& GetClusterId() const { return m_clusterId; }
174 inline bool ClusterIdHasBeenSet() const { return m_clusterIdHasBeenSet; }
175 template <typename ClusterIdT = Aws::String>
176 void SetClusterId(ClusterIdT&& value) {
177 m_clusterIdHasBeenSet = true;
178 m_clusterId = std::forward<ClusterIdT>(value);
179 }
180 template <typename ClusterIdT = Aws::String>
181 ComputeNodeGroup& WithClusterId(ClusterIdT&& value) {
182 SetClusterId(std::forward<ClusterIdT>(value));
183 return *this;
184 }
186
188
191 inline const Aws::Utils::DateTime& GetCreatedAt() const { return m_createdAt; }
192 inline bool CreatedAtHasBeenSet() const { return m_createdAtHasBeenSet; }
193 template <typename CreatedAtT = Aws::Utils::DateTime>
194 void SetCreatedAt(CreatedAtT&& value) {
195 m_createdAtHasBeenSet = true;
196 m_createdAt = std::forward<CreatedAtT>(value);
197 }
198 template <typename CreatedAtT = Aws::Utils::DateTime>
199 ComputeNodeGroup& WithCreatedAt(CreatedAtT&& value) {
200 SetCreatedAt(std::forward<CreatedAtT>(value));
201 return *this;
202 }
204
206
209 inline const Aws::Utils::DateTime& GetModifiedAt() const { return m_modifiedAt; }
210 inline bool ModifiedAtHasBeenSet() const { return m_modifiedAtHasBeenSet; }
211 template <typename ModifiedAtT = Aws::Utils::DateTime>
212 void SetModifiedAt(ModifiedAtT&& value) {
213 m_modifiedAtHasBeenSet = true;
214 m_modifiedAt = std::forward<ModifiedAtT>(value);
215 }
216 template <typename ModifiedAtT = Aws::Utils::DateTime>
217 ComputeNodeGroup& WithModifiedAt(ModifiedAtT&& value) {
218 SetModifiedAt(std::forward<ModifiedAtT>(value));
219 return *this;
220 }
222
224
238 inline ComputeNodeGroupStatus GetStatus() const { return m_status; }
239 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
241 m_statusHasBeenSet = true;
242 m_status = value;
243 }
245 SetStatus(value);
246 return *this;
247 }
249
251
255 inline const Aws::Vector<Aws::String>& GetSubnetIds() const { return m_subnetIds; }
256 inline bool SubnetIdsHasBeenSet() const { return m_subnetIdsHasBeenSet; }
257 template <typename SubnetIdsT = Aws::Vector<Aws::String>>
258 void SetSubnetIds(SubnetIdsT&& value) {
259 m_subnetIdsHasBeenSet = true;
260 m_subnetIds = std::forward<SubnetIdsT>(value);
261 }
262 template <typename SubnetIdsT = Aws::Vector<Aws::String>>
263 ComputeNodeGroup& WithSubnetIds(SubnetIdsT&& value) {
264 SetSubnetIds(std::forward<SubnetIdsT>(value));
265 return *this;
266 }
267 template <typename SubnetIdsT = Aws::String>
268 ComputeNodeGroup& AddSubnetIds(SubnetIdsT&& value) {
269 m_subnetIdsHasBeenSet = true;
270 m_subnetIds.emplace_back(std::forward<SubnetIdsT>(value));
271 return *this;
272 }
274
276
296 inline PurchaseOption GetPurchaseOption() const { return m_purchaseOption; }
297 inline bool PurchaseOptionHasBeenSet() const { return m_purchaseOptionHasBeenSet; }
299 m_purchaseOptionHasBeenSet = true;
300 m_purchaseOption = value;
301 }
303 SetPurchaseOption(value);
304 return *this;
305 }
307
309
317 inline LaunchTemplateMode GetLaunchTemplateMode() const { return m_launchTemplateMode; }
318 inline bool LaunchTemplateModeHasBeenSet() const { return m_launchTemplateModeHasBeenSet; }
320 m_launchTemplateModeHasBeenSet = true;
321 m_launchTemplateMode = value;
322 }
325 return *this;
326 }
328
330
336 inline const CustomLaunchTemplate& GetCustomLaunchTemplate() const { return m_customLaunchTemplate; }
337 inline bool CustomLaunchTemplateHasBeenSet() const { return m_customLaunchTemplateHasBeenSet; }
338 template <typename CustomLaunchTemplateT = CustomLaunchTemplate>
339 void SetCustomLaunchTemplate(CustomLaunchTemplateT&& value) {
340 m_customLaunchTemplateHasBeenSet = true;
341 m_customLaunchTemplate = std::forward<CustomLaunchTemplateT>(value);
342 }
343 template <typename CustomLaunchTemplateT = CustomLaunchTemplate>
344 ComputeNodeGroup& WithCustomLaunchTemplate(CustomLaunchTemplateT&& value) {
345 SetCustomLaunchTemplate(std::forward<CustomLaunchTemplateT>(value));
346 return *this;
347 }
349
351
360 inline const Aws::String& GetIamInstanceProfileArn() const { return m_iamInstanceProfileArn; }
361 inline bool IamInstanceProfileArnHasBeenSet() const { return m_iamInstanceProfileArnHasBeenSet; }
362 template <typename IamInstanceProfileArnT = Aws::String>
363 void SetIamInstanceProfileArn(IamInstanceProfileArnT&& value) {
364 m_iamInstanceProfileArnHasBeenSet = true;
365 m_iamInstanceProfileArn = std::forward<IamInstanceProfileArnT>(value);
366 }
367 template <typename IamInstanceProfileArnT = Aws::String>
368 ComputeNodeGroup& WithIamInstanceProfileArn(IamInstanceProfileArnT&& value) {
369 SetIamInstanceProfileArn(std::forward<IamInstanceProfileArnT>(value));
370 return *this;
371 }
373
375
376 inline const ScalingConfiguration& GetScalingConfiguration() const { return m_scalingConfiguration; }
377 inline bool ScalingConfigurationHasBeenSet() const { return m_scalingConfigurationHasBeenSet; }
378 template <typename ScalingConfigurationT = ScalingConfiguration>
379 void SetScalingConfiguration(ScalingConfigurationT&& value) {
380 m_scalingConfigurationHasBeenSet = true;
381 m_scalingConfiguration = std::forward<ScalingConfigurationT>(value);
382 }
383 template <typename ScalingConfigurationT = ScalingConfiguration>
384 ComputeNodeGroup& WithScalingConfiguration(ScalingConfigurationT&& value) {
385 SetScalingConfiguration(std::forward<ScalingConfigurationT>(value));
386 return *this;
387 }
389
391
395 inline const Aws::Vector<InstanceConfig>& GetInstanceConfigs() const { return m_instanceConfigs; }
396 inline bool InstanceConfigsHasBeenSet() const { return m_instanceConfigsHasBeenSet; }
397 template <typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
398 void SetInstanceConfigs(InstanceConfigsT&& value) {
399 m_instanceConfigsHasBeenSet = true;
400 m_instanceConfigs = std::forward<InstanceConfigsT>(value);
401 }
402 template <typename InstanceConfigsT = Aws::Vector<InstanceConfig>>
403 ComputeNodeGroup& WithInstanceConfigs(InstanceConfigsT&& value) {
404 SetInstanceConfigs(std::forward<InstanceConfigsT>(value));
405 return *this;
406 }
407 template <typename InstanceConfigsT = InstanceConfig>
408 ComputeNodeGroup& AddInstanceConfigs(InstanceConfigsT&& value) {
409 m_instanceConfigsHasBeenSet = true;
410 m_instanceConfigs.emplace_back(std::forward<InstanceConfigsT>(value));
411 return *this;
412 }
414
416
417 inline const SpotOptions& GetSpotOptions() const { return m_spotOptions; }
418 inline bool SpotOptionsHasBeenSet() const { return m_spotOptionsHasBeenSet; }
419 template <typename SpotOptionsT = SpotOptions>
420 void SetSpotOptions(SpotOptionsT&& value) {
421 m_spotOptionsHasBeenSet = true;
422 m_spotOptions = std::forward<SpotOptionsT>(value);
423 }
424 template <typename SpotOptionsT = SpotOptions>
425 ComputeNodeGroup& WithSpotOptions(SpotOptionsT&& value) {
426 SetSpotOptions(std::forward<SpotOptionsT>(value));
427 return *this;
428 }
430
432
433 inline const ComputeNodeGroupSlurmConfiguration& GetSlurmConfiguration() const { return m_slurmConfiguration; }
434 inline bool SlurmConfigurationHasBeenSet() const { return m_slurmConfigurationHasBeenSet; }
435 template <typename SlurmConfigurationT = ComputeNodeGroupSlurmConfiguration>
436 void SetSlurmConfiguration(SlurmConfigurationT&& value) {
437 m_slurmConfigurationHasBeenSet = true;
438 m_slurmConfiguration = std::forward<SlurmConfigurationT>(value);
439 }
440 template <typename SlurmConfigurationT = ComputeNodeGroupSlurmConfiguration>
441 ComputeNodeGroup& WithSlurmConfiguration(SlurmConfigurationT&& value) {
442 SetSlurmConfiguration(std::forward<SlurmConfigurationT>(value));
443 return *this;
444 }
446
448
454 inline const NodeLifecycleActions& GetNodeLifecycleActions() const { return m_nodeLifecycleActions; }
455 inline bool NodeLifecycleActionsHasBeenSet() const { return m_nodeLifecycleActionsHasBeenSet; }
456 template <typename NodeLifecycleActionsT = NodeLifecycleActions>
457 void SetNodeLifecycleActions(NodeLifecycleActionsT&& value) {
458 m_nodeLifecycleActionsHasBeenSet = true;
459 m_nodeLifecycleActions = std::forward<NodeLifecycleActionsT>(value);
460 }
461 template <typename NodeLifecycleActionsT = NodeLifecycleActions>
462 ComputeNodeGroup& WithNodeLifecycleActions(NodeLifecycleActionsT&& value) {
463 SetNodeLifecycleActions(std::forward<NodeLifecycleActionsT>(value));
464 return *this;
465 }
467
469
472 inline const Aws::Vector<ErrorInfo>& GetErrorInfo() const { return m_errorInfo; }
473 inline bool ErrorInfoHasBeenSet() const { return m_errorInfoHasBeenSet; }
474 template <typename ErrorInfoT = Aws::Vector<ErrorInfo>>
475 void SetErrorInfo(ErrorInfoT&& value) {
476 m_errorInfoHasBeenSet = true;
477 m_errorInfo = std::forward<ErrorInfoT>(value);
478 }
479 template <typename ErrorInfoT = Aws::Vector<ErrorInfo>>
480 ComputeNodeGroup& WithErrorInfo(ErrorInfoT&& value) {
481 SetErrorInfo(std::forward<ErrorInfoT>(value));
482 return *this;
483 }
484 template <typename ErrorInfoT = ErrorInfo>
485 ComputeNodeGroup& AddErrorInfo(ErrorInfoT&& value) {
486 m_errorInfoHasBeenSet = true;
487 m_errorInfo.emplace_back(std::forward<ErrorInfoT>(value));
488 return *this;
489 }
491 private:
492 Aws::String m_amiId;
493
494 Aws::Vector<Aws::String> m_securityGroupIds;
495
496 Aws::String m_sshKeyName;
497
498 Aws::String m_name;
499
500 Aws::String m_id;
501
502 Aws::String m_arn;
503
504 Aws::String m_clusterId;
505
506 Aws::Utils::DateTime m_createdAt{};
507
508 Aws::Utils::DateTime m_modifiedAt{};
509
511
512 Aws::Vector<Aws::String> m_subnetIds;
513
514 PurchaseOption m_purchaseOption{PurchaseOption::NOT_SET};
515
517
518 CustomLaunchTemplate m_customLaunchTemplate;
519
520 Aws::String m_iamInstanceProfileArn;
521
522 ScalingConfiguration m_scalingConfiguration;
523
524 Aws::Vector<InstanceConfig> m_instanceConfigs;
525
526 SpotOptions m_spotOptions;
527
528 ComputeNodeGroupSlurmConfiguration m_slurmConfiguration;
529
530 NodeLifecycleActions m_nodeLifecycleActions;
531
532 Aws::Vector<ErrorInfo> m_errorInfo;
533 bool m_amiIdHasBeenSet = false;
534 bool m_securityGroupIdsHasBeenSet = false;
535 bool m_sshKeyNameHasBeenSet = false;
536 bool m_nameHasBeenSet = false;
537 bool m_idHasBeenSet = false;
538 bool m_arnHasBeenSet = false;
539 bool m_clusterIdHasBeenSet = false;
540 bool m_createdAtHasBeenSet = false;
541 bool m_modifiedAtHasBeenSet = false;
542 bool m_statusHasBeenSet = false;
543 bool m_subnetIdsHasBeenSet = false;
544 bool m_purchaseOptionHasBeenSet = false;
545 bool m_launchTemplateModeHasBeenSet = false;
546 bool m_customLaunchTemplateHasBeenSet = false;
547 bool m_iamInstanceProfileArnHasBeenSet = false;
548 bool m_scalingConfigurationHasBeenSet = false;
549 bool m_instanceConfigsHasBeenSet = false;
550 bool m_spotOptionsHasBeenSet = false;
551 bool m_slurmConfigurationHasBeenSet = false;
552 bool m_nodeLifecycleActionsHasBeenSet = false;
553 bool m_errorInfoHasBeenSet = false;
554};
555
556} // namespace Model
557} // namespace PCS
558} // namespace Aws
ComputeNodeGroup & AddSubnetIds(SubnetIdsT &&value)
ComputeNodeGroupStatus GetStatus() const
void SetScalingConfiguration(ScalingConfigurationT &&value)
const Aws::Utils::DateTime & GetCreatedAt() const
LaunchTemplateMode GetLaunchTemplateMode() const
ComputeNodeGroup & WithPurchaseOption(PurchaseOption value)
const Aws::String & GetIamInstanceProfileArn() const
void SetPurchaseOption(PurchaseOption value)
const ComputeNodeGroupSlurmConfiguration & GetSlurmConfiguration() const
const Aws::Vector< Aws::String > & GetSecurityGroupIds() 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)
void SetLaunchTemplateMode(LaunchTemplateMode value)
ComputeNodeGroup & AddSecurityGroupIds(SecurityGroupIdsT &&value)
ComputeNodeGroup & WithSpotOptions(SpotOptionsT &&value)
ComputeNodeGroup & WithName(NameT &&value)
AWS_PCS_API ComputeNodeGroup()=default
void SetModifiedAt(ModifiedAtT &&value)
ComputeNodeGroup & WithInstanceConfigs(InstanceConfigsT &&value)
ComputeNodeGroup & WithSshKeyName(SshKeyNameT &&value)
void SetStatus(ComputeNodeGroupStatus value)
ComputeNodeGroup & WithId(IdT &&value)
ComputeNodeGroup & WithModifiedAt(ModifiedAtT &&value)
void SetClusterId(ClusterIdT &&value)
void SetSecurityGroupIds(SecurityGroupIdsT &&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
void SetSshKeyName(SshKeyNameT &&value)
ComputeNodeGroup & WithCreatedAt(CreatedAtT &&value)
const Aws::Utils::DateTime & GetModifiedAt() const
PurchaseOption GetPurchaseOption() const
const Aws::Vector< InstanceConfig > & GetInstanceConfigs() const
ComputeNodeGroup & WithSecurityGroupIds(SecurityGroupIdsT &&value)
ComputeNodeGroup & WithStatus(ComputeNodeGroupStatus value)
const Aws::String & GetSshKeyName() const
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 & WithLaunchTemplateMode(LaunchTemplateMode 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