AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
CloudFormationTarget.h
1
6#pragma once
7#include <aws/codedeploy/CodeDeploy_EXPORTS.h>
8#include <aws/codedeploy/model/LifecycleEvent.h>
9#include <aws/codedeploy/model/TargetStatus.h>
10#include <aws/core/utils/DateTime.h>
11#include <aws/core/utils/memory/stl/AWSString.h>
12#include <aws/core/utils/memory/stl/AWSVector.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace CodeDeploy {
24namespace Model {
25
34 public:
35 AWS_CODEDEPLOY_API CloudFormationTarget() = default;
36 AWS_CODEDEPLOY_API CloudFormationTarget(Aws::Utils::Json::JsonView jsonValue);
38 AWS_CODEDEPLOY_API Aws::Utils::Json::JsonValue Jsonize() const;
39
41
44 inline const Aws::String& GetDeploymentId() const { return m_deploymentId; }
45 inline bool DeploymentIdHasBeenSet() const { return m_deploymentIdHasBeenSet; }
46 template <typename DeploymentIdT = Aws::String>
47 void SetDeploymentId(DeploymentIdT&& value) {
48 m_deploymentIdHasBeenSet = true;
49 m_deploymentId = std::forward<DeploymentIdT>(value);
50 }
51 template <typename DeploymentIdT = Aws::String>
52 CloudFormationTarget& WithDeploymentId(DeploymentIdT&& value) {
53 SetDeploymentId(std::forward<DeploymentIdT>(value));
54 return *this;
55 }
57
59
63 inline const Aws::String& GetTargetId() const { return m_targetId; }
64 inline bool TargetIdHasBeenSet() const { return m_targetIdHasBeenSet; }
65 template <typename TargetIdT = Aws::String>
66 void SetTargetId(TargetIdT&& value) {
67 m_targetIdHasBeenSet = true;
68 m_targetId = std::forward<TargetIdT>(value);
69 }
70 template <typename TargetIdT = Aws::String>
71 CloudFormationTarget& WithTargetId(TargetIdT&& value) {
72 SetTargetId(std::forward<TargetIdT>(value));
73 return *this;
74 }
76
78
82 inline const Aws::Utils::DateTime& GetLastUpdatedAt() const { return m_lastUpdatedAt; }
83 inline bool LastUpdatedAtHasBeenSet() const { return m_lastUpdatedAtHasBeenSet; }
84 template <typename LastUpdatedAtT = Aws::Utils::DateTime>
85 void SetLastUpdatedAt(LastUpdatedAtT&& value) {
86 m_lastUpdatedAtHasBeenSet = true;
87 m_lastUpdatedAt = std::forward<LastUpdatedAtT>(value);
88 }
89 template <typename LastUpdatedAtT = Aws::Utils::DateTime>
90 CloudFormationTarget& WithLastUpdatedAt(LastUpdatedAtT&& value) {
91 SetLastUpdatedAt(std::forward<LastUpdatedAtT>(value));
92 return *this;
93 }
95
97
101 inline const Aws::Vector<LifecycleEvent>& GetLifecycleEvents() const { return m_lifecycleEvents; }
102 inline bool LifecycleEventsHasBeenSet() const { return m_lifecycleEventsHasBeenSet; }
103 template <typename LifecycleEventsT = Aws::Vector<LifecycleEvent>>
104 void SetLifecycleEvents(LifecycleEventsT&& value) {
105 m_lifecycleEventsHasBeenSet = true;
106 m_lifecycleEvents = std::forward<LifecycleEventsT>(value);
107 }
108 template <typename LifecycleEventsT = Aws::Vector<LifecycleEvent>>
109 CloudFormationTarget& WithLifecycleEvents(LifecycleEventsT&& value) {
110 SetLifecycleEvents(std::forward<LifecycleEventsT>(value));
111 return *this;
112 }
113 template <typename LifecycleEventsT = LifecycleEvent>
114 CloudFormationTarget& AddLifecycleEvents(LifecycleEventsT&& value) {
115 m_lifecycleEventsHasBeenSet = true;
116 m_lifecycleEvents.emplace_back(std::forward<LifecycleEventsT>(value));
117 return *this;
118 }
120
122
126 inline TargetStatus GetStatus() const { return m_status; }
127 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
128 inline void SetStatus(TargetStatus value) {
129 m_statusHasBeenSet = true;
130 m_status = value;
131 }
133 SetStatus(value);
134 return *this;
135 }
137
139
142 inline const Aws::String& GetResourceType() const { return m_resourceType; }
143 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
144 template <typename ResourceTypeT = Aws::String>
145 void SetResourceType(ResourceTypeT&& value) {
146 m_resourceTypeHasBeenSet = true;
147 m_resourceType = std::forward<ResourceTypeT>(value);
148 }
149 template <typename ResourceTypeT = Aws::String>
150 CloudFormationTarget& WithResourceType(ResourceTypeT&& value) {
151 SetResourceType(std::forward<ResourceTypeT>(value));
152 return *this;
153 }
155
157
161 inline double GetTargetVersionWeight() const { return m_targetVersionWeight; }
162 inline bool TargetVersionWeightHasBeenSet() const { return m_targetVersionWeightHasBeenSet; }
163 inline void SetTargetVersionWeight(double value) {
164 m_targetVersionWeightHasBeenSet = true;
165 m_targetVersionWeight = value;
166 }
169 return *this;
170 }
172 private:
173 Aws::String m_deploymentId;
174
175 Aws::String m_targetId;
176
177 Aws::Utils::DateTime m_lastUpdatedAt{};
178
179 Aws::Vector<LifecycleEvent> m_lifecycleEvents;
180
182
183 Aws::String m_resourceType;
184
185 double m_targetVersionWeight{0.0};
186 bool m_deploymentIdHasBeenSet = false;
187 bool m_targetIdHasBeenSet = false;
188 bool m_lastUpdatedAtHasBeenSet = false;
189 bool m_lifecycleEventsHasBeenSet = false;
190 bool m_statusHasBeenSet = false;
191 bool m_resourceTypeHasBeenSet = false;
192 bool m_targetVersionWeightHasBeenSet = false;
193};
194
195} // namespace Model
196} // namespace CodeDeploy
197} // namespace Aws
CloudFormationTarget & AddLifecycleEvents(LifecycleEventsT &&value)
CloudFormationTarget & WithTargetId(TargetIdT &&value)
AWS_CODEDEPLOY_API CloudFormationTarget()=default
CloudFormationTarget & WithTargetVersionWeight(double value)
AWS_CODEDEPLOY_API CloudFormationTarget & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::Utils::DateTime & GetLastUpdatedAt() const
CloudFormationTarget & WithResourceType(ResourceTypeT &&value)
void SetLifecycleEvents(LifecycleEventsT &&value)
AWS_CODEDEPLOY_API CloudFormationTarget(Aws::Utils::Json::JsonView jsonValue)
const Aws::Vector< LifecycleEvent > & GetLifecycleEvents() const
CloudFormationTarget & WithLastUpdatedAt(LastUpdatedAtT &&value)
AWS_CODEDEPLOY_API Aws::Utils::Json::JsonValue Jsonize() const
CloudFormationTarget & WithStatus(TargetStatus value)
CloudFormationTarget & WithLifecycleEvents(LifecycleEventsT &&value)
CloudFormationTarget & WithDeploymentId(DeploymentIdT &&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