AWS SDK for C++

AWS SDK for C++ Version 1.11.812

Loading...
Searching...
No Matches
DeploymentLifecycleHook.h
1
6#pragma once
7#include <aws/core/utils/Document.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/ecs/ECS_EXPORTS.h>
11#include <aws/ecs/model/DeploymentLifecycleHookStage.h>
12#include <aws/ecs/model/DeploymentLifecycleHookTargetType.h>
13#include <aws/ecs/model/DeploymentLifecycleHookTimeoutConfiguration.h>
14
15#include <utility>
16
17namespace Aws {
18namespace Utils {
19namespace Json {
20class JsonValue;
21class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace ECS {
25namespace Model {
26
38 public:
39 AWS_ECS_API DeploymentLifecycleHook() = default;
43
45
54 inline DeploymentLifecycleHookTargetType GetTargetType() const { return m_targetType; }
55 inline bool TargetTypeHasBeenSet() const { return m_targetTypeHasBeenSet; }
57 m_targetTypeHasBeenSet = true;
58 m_targetType = value;
59 }
61 SetTargetType(value);
62 return *this;
63 }
65
67
72 inline const Aws::String& GetHookTargetArn() const { return m_hookTargetArn; }
73 inline bool HookTargetArnHasBeenSet() const { return m_hookTargetArnHasBeenSet; }
74 template <typename HookTargetArnT = Aws::String>
75 void SetHookTargetArn(HookTargetArnT&& value) {
76 m_hookTargetArnHasBeenSet = true;
77 m_hookTargetArn = std::forward<HookTargetArnT>(value);
78 }
79 template <typename HookTargetArnT = Aws::String>
80 DeploymentLifecycleHook& WithHookTargetArn(HookTargetArnT&& value) {
81 SetHookTargetArn(std::forward<HookTargetArnT>(value));
82 return *this;
83 }
85
87
95 inline const Aws::String& GetRoleArn() const { return m_roleArn; }
96 inline bool RoleArnHasBeenSet() const { return m_roleArnHasBeenSet; }
97 template <typename RoleArnT = Aws::String>
98 void SetRoleArn(RoleArnT&& value) {
99 m_roleArnHasBeenSet = true;
100 m_roleArn = std::forward<RoleArnT>(value);
101 }
102 template <typename RoleArnT = Aws::String>
104 SetRoleArn(std::forward<RoleArnT>(value));
105 return *this;
106 }
108
110
136 inline const Aws::Vector<DeploymentLifecycleHookStage>& GetLifecycleStages() const { return m_lifecycleStages; }
137 inline bool LifecycleStagesHasBeenSet() const { return m_lifecycleStagesHasBeenSet; }
138 template <typename LifecycleStagesT = Aws::Vector<DeploymentLifecycleHookStage>>
139 void SetLifecycleStages(LifecycleStagesT&& value) {
140 m_lifecycleStagesHasBeenSet = true;
141 m_lifecycleStages = std::forward<LifecycleStagesT>(value);
142 }
143 template <typename LifecycleStagesT = Aws::Vector<DeploymentLifecycleHookStage>>
144 DeploymentLifecycleHook& WithLifecycleStages(LifecycleStagesT&& value) {
145 SetLifecycleStages(std::forward<LifecycleStagesT>(value));
146 return *this;
147 }
149 m_lifecycleStagesHasBeenSet = true;
150 m_lifecycleStages.push_back(value);
151 return *this;
152 }
154
156
160 inline Aws::Utils::DocumentView GetHookDetails() const { return m_hookDetails; }
161 inline bool HookDetailsHasBeenSet() const { return m_hookDetailsHasBeenSet; }
162 template <typename HookDetailsT = Aws::Utils::Document>
163 void SetHookDetails(HookDetailsT&& value) {
164 m_hookDetailsHasBeenSet = true;
165 m_hookDetails = std::forward<HookDetailsT>(value);
166 }
167 template <typename HookDetailsT = Aws::Utils::Document>
169 SetHookDetails(std::forward<HookDetailsT>(value));
170 return *this;
171 }
173
175
180 inline const DeploymentLifecycleHookTimeoutConfiguration& GetTimeoutConfiguration() const { return m_timeoutConfiguration; }
181 inline bool TimeoutConfigurationHasBeenSet() const { return m_timeoutConfigurationHasBeenSet; }
182 template <typename TimeoutConfigurationT = DeploymentLifecycleHookTimeoutConfiguration>
183 void SetTimeoutConfiguration(TimeoutConfigurationT&& value) {
184 m_timeoutConfigurationHasBeenSet = true;
185 m_timeoutConfiguration = std::forward<TimeoutConfigurationT>(value);
186 }
187 template <typename TimeoutConfigurationT = DeploymentLifecycleHookTimeoutConfiguration>
188 DeploymentLifecycleHook& WithTimeoutConfiguration(TimeoutConfigurationT&& value) {
189 SetTimeoutConfiguration(std::forward<TimeoutConfigurationT>(value));
190 return *this;
191 }
193 private:
195
196 Aws::String m_hookTargetArn;
197
198 Aws::String m_roleArn;
199
201
202 Aws::Utils::Document m_hookDetails;
203
204 DeploymentLifecycleHookTimeoutConfiguration m_timeoutConfiguration;
205 bool m_targetTypeHasBeenSet = false;
206 bool m_hookTargetArnHasBeenSet = false;
207 bool m_roleArnHasBeenSet = false;
208 bool m_lifecycleStagesHasBeenSet = false;
209 bool m_hookDetailsHasBeenSet = false;
210 bool m_timeoutConfigurationHasBeenSet = false;
211};
212
213} // namespace Model
214} // namespace ECS
215} // namespace Aws
DeploymentLifecycleHook & WithTargetType(DeploymentLifecycleHookTargetType value)
DeploymentLifecycleHook & WithRoleArn(RoleArnT &&value)
Aws::Utils::DocumentView GetHookDetails() const
DeploymentLifecycleHook & WithLifecycleStages(LifecycleStagesT &&value)
DeploymentLifecycleHook & WithTimeoutConfiguration(TimeoutConfigurationT &&value)
AWS_ECS_API DeploymentLifecycleHook()=default
DeploymentLifecycleHook & WithHookTargetArn(HookTargetArnT &&value)
DeploymentLifecycleHook & AddLifecycleStages(DeploymentLifecycleHookStage value)
DeploymentLifecycleHook & WithHookDetails(HookDetailsT &&value)
AWS_ECS_API DeploymentLifecycleHook & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetLifecycleStages(LifecycleStagesT &&value)
DeploymentLifecycleHookTargetType GetTargetType() const
AWS_ECS_API Aws::Utils::Json::JsonValue Jsonize() const
const DeploymentLifecycleHookTimeoutConfiguration & GetTimeoutConfiguration() const
AWS_ECS_API DeploymentLifecycleHook(Aws::Utils::Json::JsonView jsonValue)
void SetTimeoutConfiguration(TimeoutConfigurationT &&value)
const Aws::Vector< DeploymentLifecycleHookStage > & GetLifecycleStages() const
void SetTargetType(DeploymentLifecycleHookTargetType 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