AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
CreateStackRequest.h
1
6#pragma once
7#include <aws/cloudformation/CloudFormation_EXPORTS.h>
8#include <aws/cloudformation/CloudFormationRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/cloudformation/model/RollbackConfiguration.h>
12#include <aws/cloudformation/model/OnFailure.h>
13#include <aws/cloudformation/model/Parameter.h>
14#include <aws/cloudformation/model/Capability.h>
15#include <aws/cloudformation/model/Tag.h>
16#include <utility>
17
18namespace Aws
19{
20namespace CloudFormation
21{
22namespace Model
23{
24
31 {
32 public:
33 AWS_CLOUDFORMATION_API CreateStackRequest() = 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 "CreateStack"; }
40
41 AWS_CLOUDFORMATION_API Aws::String SerializePayload() const override;
42
43 protected:
44 AWS_CLOUDFORMATION_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
45
46 public:
47
49
56 inline const Aws::String& GetStackName() const { return m_stackName; }
57 inline bool StackNameHasBeenSet() const { return m_stackNameHasBeenSet; }
58 template<typename StackNameT = Aws::String>
59 void SetStackName(StackNameT&& value) { m_stackNameHasBeenSet = true; m_stackName = std::forward<StackNameT>(value); }
60 template<typename StackNameT = Aws::String>
61 CreateStackRequest& WithStackName(StackNameT&& value) { SetStackName(std::forward<StackNameT>(value)); return *this;}
63
65
70 inline const Aws::String& GetTemplateBody() const { return m_templateBody; }
71 inline bool TemplateBodyHasBeenSet() const { return m_templateBodyHasBeenSet; }
72 template<typename TemplateBodyT = Aws::String>
73 void SetTemplateBody(TemplateBodyT&& value) { m_templateBodyHasBeenSet = true; m_templateBody = std::forward<TemplateBodyT>(value); }
74 template<typename TemplateBodyT = Aws::String>
75 CreateStackRequest& WithTemplateBody(TemplateBodyT&& value) { SetTemplateBody(std::forward<TemplateBodyT>(value)); return *this;}
77
79
87 inline const Aws::String& GetTemplateURL() const { return m_templateURL; }
88 inline bool TemplateURLHasBeenSet() const { return m_templateURLHasBeenSet; }
89 template<typename TemplateURLT = Aws::String>
90 void SetTemplateURL(TemplateURLT&& value) { m_templateURLHasBeenSet = true; m_templateURL = std::forward<TemplateURLT>(value); }
91 template<typename TemplateURLT = Aws::String>
92 CreateStackRequest& WithTemplateURL(TemplateURLT&& value) { SetTemplateURL(std::forward<TemplateURLT>(value)); return *this;}
94
96
102 inline const Aws::Vector<Parameter>& GetParameters() const { return m_parameters; }
103 inline bool ParametersHasBeenSet() const { return m_parametersHasBeenSet; }
104 template<typename ParametersT = Aws::Vector<Parameter>>
105 void SetParameters(ParametersT&& value) { m_parametersHasBeenSet = true; m_parameters = std::forward<ParametersT>(value); }
106 template<typename ParametersT = Aws::Vector<Parameter>>
107 CreateStackRequest& WithParameters(ParametersT&& value) { SetParameters(std::forward<ParametersT>(value)); return *this;}
108 template<typename ParametersT = Parameter>
109 CreateStackRequest& AddParameters(ParametersT&& value) { m_parametersHasBeenSet = true; m_parameters.emplace_back(std::forward<ParametersT>(value)); return *this; }
111
113
118 inline bool GetDisableRollback() const { return m_disableRollback; }
119 inline bool DisableRollbackHasBeenSet() const { return m_disableRollbackHasBeenSet; }
120 inline void SetDisableRollback(bool value) { m_disableRollbackHasBeenSet = true; m_disableRollback = value; }
121 inline CreateStackRequest& WithDisableRollback(bool value) { SetDisableRollback(value); return *this;}
123
125
129 inline const RollbackConfiguration& GetRollbackConfiguration() const { return m_rollbackConfiguration; }
130 inline bool RollbackConfigurationHasBeenSet() const { return m_rollbackConfigurationHasBeenSet; }
131 template<typename RollbackConfigurationT = RollbackConfiguration>
132 void SetRollbackConfiguration(RollbackConfigurationT&& value) { m_rollbackConfigurationHasBeenSet = true; m_rollbackConfiguration = std::forward<RollbackConfigurationT>(value); }
133 template<typename RollbackConfigurationT = RollbackConfiguration>
134 CreateStackRequest& WithRollbackConfiguration(RollbackConfigurationT&& value) { SetRollbackConfiguration(std::forward<RollbackConfigurationT>(value)); return *this;}
136
138
143 inline int GetTimeoutInMinutes() const { return m_timeoutInMinutes; }
144 inline bool TimeoutInMinutesHasBeenSet() const { return m_timeoutInMinutesHasBeenSet; }
145 inline void SetTimeoutInMinutes(int value) { m_timeoutInMinutesHasBeenSet = true; m_timeoutInMinutes = value; }
146 inline CreateStackRequest& WithTimeoutInMinutes(int value) { SetTimeoutInMinutes(value); return *this;}
148
150
155 inline const Aws::Vector<Aws::String>& GetNotificationARNs() const { return m_notificationARNs; }
156 inline bool NotificationARNsHasBeenSet() const { return m_notificationARNsHasBeenSet; }
157 template<typename NotificationARNsT = Aws::Vector<Aws::String>>
158 void SetNotificationARNs(NotificationARNsT&& value) { m_notificationARNsHasBeenSet = true; m_notificationARNs = std::forward<NotificationARNsT>(value); }
159 template<typename NotificationARNsT = Aws::Vector<Aws::String>>
160 CreateStackRequest& WithNotificationARNs(NotificationARNsT&& value) { SetNotificationARNs(std::forward<NotificationARNsT>(value)); return *this;}
161 template<typename NotificationARNsT = Aws::String>
162 CreateStackRequest& AddNotificationARNs(NotificationARNsT&& value) { m_notificationARNsHasBeenSet = true; m_notificationARNs.emplace_back(std::forward<NotificationARNsT>(value)); return *this; }
164
166
228 inline const Aws::Vector<Capability>& GetCapabilities() const { return m_capabilities; }
229 inline bool CapabilitiesHasBeenSet() const { return m_capabilitiesHasBeenSet; }
230 template<typename CapabilitiesT = Aws::Vector<Capability>>
231 void SetCapabilities(CapabilitiesT&& value) { m_capabilitiesHasBeenSet = true; m_capabilities = std::forward<CapabilitiesT>(value); }
232 template<typename CapabilitiesT = Aws::Vector<Capability>>
233 CreateStackRequest& WithCapabilities(CapabilitiesT&& value) { SetCapabilities(std::forward<CapabilitiesT>(value)); return *this;}
234 inline CreateStackRequest& AddCapabilities(Capability value) { m_capabilitiesHasBeenSet = true; m_capabilities.push_back(value); return *this; }
236
238
258 inline const Aws::Vector<Aws::String>& GetResourceTypes() const { return m_resourceTypes; }
259 inline bool ResourceTypesHasBeenSet() const { return m_resourceTypesHasBeenSet; }
260 template<typename ResourceTypesT = Aws::Vector<Aws::String>>
261 void SetResourceTypes(ResourceTypesT&& value) { m_resourceTypesHasBeenSet = true; m_resourceTypes = std::forward<ResourceTypesT>(value); }
262 template<typename ResourceTypesT = Aws::Vector<Aws::String>>
263 CreateStackRequest& WithResourceTypes(ResourceTypesT&& value) { SetResourceTypes(std::forward<ResourceTypesT>(value)); return *this;}
264 template<typename ResourceTypesT = Aws::String>
265 CreateStackRequest& AddResourceTypes(ResourceTypesT&& value) { m_resourceTypesHasBeenSet = true; m_resourceTypes.emplace_back(std::forward<ResourceTypesT>(value)); return *this; }
267
269
280 inline const Aws::String& GetRoleARN() const { return m_roleARN; }
281 inline bool RoleARNHasBeenSet() const { return m_roleARNHasBeenSet; }
282 template<typename RoleARNT = Aws::String>
283 void SetRoleARN(RoleARNT&& value) { m_roleARNHasBeenSet = true; m_roleARN = std::forward<RoleARNT>(value); }
284 template<typename RoleARNT = Aws::String>
285 CreateStackRequest& WithRoleARN(RoleARNT&& value) { SetRoleARN(std::forward<RoleARNT>(value)); return *this;}
287
289
295 inline OnFailure GetOnFailure() const { return m_onFailure; }
296 inline bool OnFailureHasBeenSet() const { return m_onFailureHasBeenSet; }
297 inline void SetOnFailure(OnFailure value) { m_onFailureHasBeenSet = true; m_onFailure = value; }
298 inline CreateStackRequest& WithOnFailure(OnFailure value) { SetOnFailure(value); return *this;}
300
302
309 inline const Aws::String& GetStackPolicyBody() const { return m_stackPolicyBody; }
310 inline bool StackPolicyBodyHasBeenSet() const { return m_stackPolicyBodyHasBeenSet; }
311 template<typename StackPolicyBodyT = Aws::String>
312 void SetStackPolicyBody(StackPolicyBodyT&& value) { m_stackPolicyBodyHasBeenSet = true; m_stackPolicyBody = std::forward<StackPolicyBodyT>(value); }
313 template<typename StackPolicyBodyT = Aws::String>
314 CreateStackRequest& WithStackPolicyBody(StackPolicyBodyT&& value) { SetStackPolicyBody(std::forward<StackPolicyBodyT>(value)); return *this;}
316
318
326 inline const Aws::String& GetStackPolicyURL() const { return m_stackPolicyURL; }
327 inline bool StackPolicyURLHasBeenSet() const { return m_stackPolicyURLHasBeenSet; }
328 template<typename StackPolicyURLT = Aws::String>
329 void SetStackPolicyURL(StackPolicyURLT&& value) { m_stackPolicyURLHasBeenSet = true; m_stackPolicyURL = std::forward<StackPolicyURLT>(value); }
330 template<typename StackPolicyURLT = Aws::String>
331 CreateStackRequest& WithStackPolicyURL(StackPolicyURLT&& value) { SetStackPolicyURL(std::forward<StackPolicyURLT>(value)); return *this;}
333
335
340 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
341 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
342 template<typename TagsT = Aws::Vector<Tag>>
343 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
344 template<typename TagsT = Aws::Vector<Tag>>
345 CreateStackRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
346 template<typename TagsT = Tag>
347 CreateStackRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
349
351
369 inline const Aws::String& GetClientRequestToken() const { return m_clientRequestToken; }
370 inline bool ClientRequestTokenHasBeenSet() const { return m_clientRequestTokenHasBeenSet; }
371 template<typename ClientRequestTokenT = Aws::String>
372 void SetClientRequestToken(ClientRequestTokenT&& value) { m_clientRequestTokenHasBeenSet = true; m_clientRequestToken = std::forward<ClientRequestTokenT>(value); }
373 template<typename ClientRequestTokenT = Aws::String>
374 CreateStackRequest& WithClientRequestToken(ClientRequestTokenT&& value) { SetClientRequestToken(std::forward<ClientRequestTokenT>(value)); return *this;}
376
378
390 inline bool GetEnableTerminationProtection() const { return m_enableTerminationProtection; }
391 inline bool EnableTerminationProtectionHasBeenSet() const { return m_enableTerminationProtectionHasBeenSet; }
392 inline void SetEnableTerminationProtection(bool value) { m_enableTerminationProtectionHasBeenSet = true; m_enableTerminationProtection = value; }
395
397
402 inline bool GetRetainExceptOnCreate() const { return m_retainExceptOnCreate; }
403 inline bool RetainExceptOnCreateHasBeenSet() const { return m_retainExceptOnCreateHasBeenSet; }
404 inline void SetRetainExceptOnCreate(bool value) { m_retainExceptOnCreateHasBeenSet = true; m_retainExceptOnCreate = value; }
405 inline CreateStackRequest& WithRetainExceptOnCreate(bool value) { SetRetainExceptOnCreate(value); return *this;}
407 private:
408
409 Aws::String m_stackName;
410 bool m_stackNameHasBeenSet = false;
411
412 Aws::String m_templateBody;
413 bool m_templateBodyHasBeenSet = false;
414
415 Aws::String m_templateURL;
416 bool m_templateURLHasBeenSet = false;
417
418 Aws::Vector<Parameter> m_parameters;
419 bool m_parametersHasBeenSet = false;
420
421 bool m_disableRollback{false};
422 bool m_disableRollbackHasBeenSet = false;
423
424 RollbackConfiguration m_rollbackConfiguration;
425 bool m_rollbackConfigurationHasBeenSet = false;
426
427 int m_timeoutInMinutes{0};
428 bool m_timeoutInMinutesHasBeenSet = false;
429
430 Aws::Vector<Aws::String> m_notificationARNs;
431 bool m_notificationARNsHasBeenSet = false;
432
433 Aws::Vector<Capability> m_capabilities;
434 bool m_capabilitiesHasBeenSet = false;
435
436 Aws::Vector<Aws::String> m_resourceTypes;
437 bool m_resourceTypesHasBeenSet = false;
438
439 Aws::String m_roleARN;
440 bool m_roleARNHasBeenSet = false;
441
442 OnFailure m_onFailure{OnFailure::NOT_SET};
443 bool m_onFailureHasBeenSet = false;
444
445 Aws::String m_stackPolicyBody;
446 bool m_stackPolicyBodyHasBeenSet = false;
447
448 Aws::String m_stackPolicyURL;
449 bool m_stackPolicyURLHasBeenSet = false;
450
451 Aws::Vector<Tag> m_tags;
452 bool m_tagsHasBeenSet = false;
453
454 Aws::String m_clientRequestToken;
455 bool m_clientRequestTokenHasBeenSet = false;
456
457 bool m_enableTerminationProtection{false};
458 bool m_enableTerminationProtectionHasBeenSet = false;
459
460 bool m_retainExceptOnCreate{false};
461 bool m_retainExceptOnCreateHasBeenSet = false;
462 };
463
464} // namespace Model
465} // namespace CloudFormation
466} // namespace Aws
void SetStackPolicyBody(StackPolicyBodyT &&value)
virtual const char * GetServiceRequestName() const override
CreateStackRequest & AddNotificationARNs(NotificationARNsT &&value)
const RollbackConfiguration & GetRollbackConfiguration() const
CreateStackRequest & WithParameters(ParametersT &&value)
CreateStackRequest & WithOnFailure(OnFailure value)
CreateStackRequest & WithTimeoutInMinutes(int value)
AWS_CLOUDFORMATION_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
CreateStackRequest & WithRollbackConfiguration(RollbackConfigurationT &&value)
CreateStackRequest & WithRoleARN(RoleARNT &&value)
CreateStackRequest & WithRetainExceptOnCreate(bool value)
CreateStackRequest & AddCapabilities(Capability value)
CreateStackRequest & AddParameters(ParametersT &&value)
const Aws::Vector< Parameter > & GetParameters() const
CreateStackRequest & WithStackPolicyBody(StackPolicyBodyT &&value)
const Aws::Vector< Capability > & GetCapabilities() const
CreateStackRequest & AddResourceTypes(ResourceTypesT &&value)
const Aws::Vector< Tag > & GetTags() const
CreateStackRequest & WithCapabilities(CapabilitiesT &&value)
CreateStackRequest & WithDisableRollback(bool value)
void SetClientRequestToken(ClientRequestTokenT &&value)
CreateStackRequest & WithEnableTerminationProtection(bool value)
CreateStackRequest & AddTags(TagsT &&value)
CreateStackRequest & WithStackPolicyURL(StackPolicyURLT &&value)
CreateStackRequest & WithTemplateBody(TemplateBodyT &&value)
CreateStackRequest & WithTemplateURL(TemplateURLT &&value)
const Aws::Vector< Aws::String > & GetNotificationARNs() const
void SetNotificationARNs(NotificationARNsT &&value)
void SetRollbackConfiguration(RollbackConfigurationT &&value)
const Aws::Vector< Aws::String > & GetResourceTypes() const
CreateStackRequest & WithClientRequestToken(ClientRequestTokenT &&value)
CreateStackRequest & WithResourceTypes(ResourceTypesT &&value)
AWS_CLOUDFORMATION_API CreateStackRequest()=default
CreateStackRequest & WithTags(TagsT &&value)
AWS_CLOUDFORMATION_API Aws::String SerializePayload() const override
CreateStackRequest & WithNotificationARNs(NotificationARNsT &&value)
CreateStackRequest & WithStackName(StackNameT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector