AWS SDK for C++

AWS SDK for C++ Version 1.11.901

Loading...
Searching...
No Matches
InfrastructureConfiguration.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSMap.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/imagebuilder/Imagebuilder_EXPORTS.h>
11#include <aws/imagebuilder/model/InstanceMetadataOptions.h>
12#include <aws/imagebuilder/model/Logging.h>
13#include <aws/imagebuilder/model/Placement.h>
14
15#include <utility>
16
17namespace Aws {
18namespace Utils {
19namespace Json {
20class JsonValue;
21class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace imagebuilder {
25namespace Model {
26
33 public:
34 AWS_IMAGEBUILDER_API InfrastructureConfiguration() = default;
37 AWS_IMAGEBUILDER_API Aws::Utils::Json::JsonValue Jsonize() const;
38
40
43 inline const Aws::String& GetArn() const { return m_arn; }
44 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
45 template <typename ArnT = Aws::String>
46 void SetArn(ArnT&& value) {
47 m_arnHasBeenSet = true;
48 m_arn = std::forward<ArnT>(value);
49 }
50 template <typename ArnT = Aws::String>
52 SetArn(std::forward<ArnT>(value));
53 return *this;
54 }
56
58
61 inline const Aws::String& GetName() const { return m_name; }
62 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
63 template <typename NameT = Aws::String>
64 void SetName(NameT&& value) {
65 m_nameHasBeenSet = true;
66 m_name = std::forward<NameT>(value);
67 }
68 template <typename NameT = Aws::String>
70 SetName(std::forward<NameT>(value));
71 return *this;
72 }
74
76
79 inline const Aws::String& GetDescription() const { return m_description; }
80 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
81 template <typename DescriptionT = Aws::String>
82 void SetDescription(DescriptionT&& value) {
83 m_descriptionHasBeenSet = true;
84 m_description = std::forward<DescriptionT>(value);
85 }
86 template <typename DescriptionT = Aws::String>
88 SetDescription(std::forward<DescriptionT>(value));
89 return *this;
90 }
92
94
97 inline const Aws::Vector<Aws::String>& GetInstanceTypes() const { return m_instanceTypes; }
98 inline bool InstanceTypesHasBeenSet() const { return m_instanceTypesHasBeenSet; }
99 template <typename InstanceTypesT = Aws::Vector<Aws::String>>
100 void SetInstanceTypes(InstanceTypesT&& value) {
101 m_instanceTypesHasBeenSet = true;
102 m_instanceTypes = std::forward<InstanceTypesT>(value);
103 }
104 template <typename InstanceTypesT = Aws::Vector<Aws::String>>
106 SetInstanceTypes(std::forward<InstanceTypesT>(value));
107 return *this;
108 }
109 template <typename InstanceTypesT = Aws::String>
111 m_instanceTypesHasBeenSet = true;
112 m_instanceTypes.emplace_back(std::forward<InstanceTypesT>(value));
113 return *this;
114 }
116
118
121 inline const Aws::String& GetInstanceProfileName() const { return m_instanceProfileName; }
122 inline bool InstanceProfileNameHasBeenSet() const { return m_instanceProfileNameHasBeenSet; }
123 template <typename InstanceProfileNameT = Aws::String>
124 void SetInstanceProfileName(InstanceProfileNameT&& value) {
125 m_instanceProfileNameHasBeenSet = true;
126 m_instanceProfileName = std::forward<InstanceProfileNameT>(value);
127 }
128 template <typename InstanceProfileNameT = Aws::String>
130 SetInstanceProfileName(std::forward<InstanceProfileNameT>(value));
131 return *this;
132 }
134
136
139 inline const Aws::Vector<Aws::String>& GetSecurityGroupIds() const { return m_securityGroupIds; }
140 inline bool SecurityGroupIdsHasBeenSet() const { return m_securityGroupIdsHasBeenSet; }
141 template <typename SecurityGroupIdsT = Aws::Vector<Aws::String>>
142 void SetSecurityGroupIds(SecurityGroupIdsT&& value) {
143 m_securityGroupIdsHasBeenSet = true;
144 m_securityGroupIds = std::forward<SecurityGroupIdsT>(value);
145 }
146 template <typename SecurityGroupIdsT = Aws::Vector<Aws::String>>
148 SetSecurityGroupIds(std::forward<SecurityGroupIdsT>(value));
149 return *this;
150 }
151 template <typename SecurityGroupIdsT = Aws::String>
153 m_securityGroupIdsHasBeenSet = true;
154 m_securityGroupIds.emplace_back(std::forward<SecurityGroupIdsT>(value));
155 return *this;
156 }
158
160
163 inline const Aws::String& GetSubnetId() const { return m_subnetId; }
164 inline bool SubnetIdHasBeenSet() const { return m_subnetIdHasBeenSet; }
165 template <typename SubnetIdT = Aws::String>
166 void SetSubnetId(SubnetIdT&& value) {
167 m_subnetIdHasBeenSet = true;
168 m_subnetId = std::forward<SubnetIdT>(value);
169 }
170 template <typename SubnetIdT = Aws::String>
172 SetSubnetId(std::forward<SubnetIdT>(value));
173 return *this;
174 }
176
178
183 inline const Logging& GetLogging() const { return m_logging; }
184 inline bool LoggingHasBeenSet() const { return m_loggingHasBeenSet; }
185 template <typename LoggingT = Logging>
186 void SetLogging(LoggingT&& value) {
187 m_loggingHasBeenSet = true;
188 m_logging = std::forward<LoggingT>(value);
189 }
190 template <typename LoggingT = Logging>
192 SetLogging(std::forward<LoggingT>(value));
193 return *this;
194 }
196
198
201 inline const Aws::String& GetKeyPair() const { return m_keyPair; }
202 inline bool KeyPairHasBeenSet() const { return m_keyPairHasBeenSet; }
203 template <typename KeyPairT = Aws::String>
204 void SetKeyPair(KeyPairT&& value) {
205 m_keyPairHasBeenSet = true;
206 m_keyPair = std::forward<KeyPairT>(value);
207 }
208 template <typename KeyPairT = Aws::String>
210 SetKeyPair(std::forward<KeyPairT>(value));
211 return *this;
212 }
214
216
221 inline bool GetTerminateInstanceOnFailure() const { return m_terminateInstanceOnFailure; }
222 inline bool TerminateInstanceOnFailureHasBeenSet() const { return m_terminateInstanceOnFailureHasBeenSet; }
223 inline void SetTerminateInstanceOnFailure(bool value) {
224 m_terminateInstanceOnFailureHasBeenSet = true;
225 m_terminateInstanceOnFailure = value;
226 }
229 return *this;
230 }
232
234
242 inline const Aws::String& GetSnsTopicArn() const { return m_snsTopicArn; }
243 inline bool SnsTopicArnHasBeenSet() const { return m_snsTopicArnHasBeenSet; }
244 template <typename SnsTopicArnT = Aws::String>
245 void SetSnsTopicArn(SnsTopicArnT&& value) {
246 m_snsTopicArnHasBeenSet = true;
247 m_snsTopicArn = std::forward<SnsTopicArnT>(value);
248 }
249 template <typename SnsTopicArnT = Aws::String>
251 SetSnsTopicArn(std::forward<SnsTopicArnT>(value));
252 return *this;
253 }
255
257
260 inline const Aws::String& GetDateCreated() const { return m_dateCreated; }
261 inline bool DateCreatedHasBeenSet() const { return m_dateCreatedHasBeenSet; }
262 template <typename DateCreatedT = Aws::String>
263 void SetDateCreated(DateCreatedT&& value) {
264 m_dateCreatedHasBeenSet = true;
265 m_dateCreated = std::forward<DateCreatedT>(value);
266 }
267 template <typename DateCreatedT = Aws::String>
269 SetDateCreated(std::forward<DateCreatedT>(value));
270 return *this;
271 }
273
275
278 inline const Aws::String& GetDateUpdated() const { return m_dateUpdated; }
279 inline bool DateUpdatedHasBeenSet() const { return m_dateUpdatedHasBeenSet; }
280 template <typename DateUpdatedT = Aws::String>
281 void SetDateUpdated(DateUpdatedT&& value) {
282 m_dateUpdatedHasBeenSet = true;
283 m_dateUpdated = std::forward<DateUpdatedT>(value);
284 }
285 template <typename DateUpdatedT = Aws::String>
287 SetDateUpdated(std::forward<DateUpdatedT>(value));
288 return *this;
289 }
291
293
297 inline const Aws::Map<Aws::String, Aws::String>& GetResourceTags() const { return m_resourceTags; }
298 inline bool ResourceTagsHasBeenSet() const { return m_resourceTagsHasBeenSet; }
299 template <typename ResourceTagsT = Aws::Map<Aws::String, Aws::String>>
300 void SetResourceTags(ResourceTagsT&& value) {
301 m_resourceTagsHasBeenSet = true;
302 m_resourceTags = std::forward<ResourceTagsT>(value);
303 }
304 template <typename ResourceTagsT = Aws::Map<Aws::String, Aws::String>>
306 SetResourceTags(std::forward<ResourceTagsT>(value));
307 return *this;
308 }
309 template <typename ResourceTagsKeyT = Aws::String, typename ResourceTagsValueT = Aws::String>
310 InfrastructureConfiguration& AddResourceTags(ResourceTagsKeyT&& key, ResourceTagsValueT&& value) {
311 m_resourceTagsHasBeenSet = true;
312 m_resourceTags.emplace(std::forward<ResourceTagsKeyT>(key), std::forward<ResourceTagsValueT>(value));
313 return *this;
314 }
316
318
322 inline const InstanceMetadataOptions& GetInstanceMetadataOptions() const { return m_instanceMetadataOptions; }
323 inline bool InstanceMetadataOptionsHasBeenSet() const { return m_instanceMetadataOptionsHasBeenSet; }
324 template <typename InstanceMetadataOptionsT = InstanceMetadataOptions>
325 void SetInstanceMetadataOptions(InstanceMetadataOptionsT&& value) {
326 m_instanceMetadataOptionsHasBeenSet = true;
327 m_instanceMetadataOptions = std::forward<InstanceMetadataOptionsT>(value);
328 }
329 template <typename InstanceMetadataOptionsT = InstanceMetadataOptions>
330 InfrastructureConfiguration& WithInstanceMetadataOptions(InstanceMetadataOptionsT&& value) {
331 SetInstanceMetadataOptions(std::forward<InstanceMetadataOptionsT>(value));
332 return *this;
333 }
335
337
340 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
341 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
342 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
343 void SetTags(TagsT&& value) {
344 m_tagsHasBeenSet = true;
345 m_tags = std::forward<TagsT>(value);
346 }
347 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
349 SetTags(std::forward<TagsT>(value));
350 return *this;
351 }
352 template <typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
353 InfrastructureConfiguration& AddTags(TagsKeyT&& key, TagsValueT&& value) {
354 m_tagsHasBeenSet = true;
355 m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value));
356 return *this;
357 }
359
361
366 inline const Placement& GetPlacement() const { return m_placement; }
367 inline bool PlacementHasBeenSet() const { return m_placementHasBeenSet; }
368 template <typename PlacementT = Placement>
369 void SetPlacement(PlacementT&& value) {
370 m_placementHasBeenSet = true;
371 m_placement = std::forward<PlacementT>(value);
372 }
373 template <typename PlacementT = Placement>
375 SetPlacement(std::forward<PlacementT>(value));
376 return *this;
377 }
379 private:
380 Aws::String m_arn;
381
382 Aws::String m_name;
383
384 Aws::String m_description;
385
386 Aws::Vector<Aws::String> m_instanceTypes;
387
388 Aws::String m_instanceProfileName;
389
390 Aws::Vector<Aws::String> m_securityGroupIds;
391
392 Aws::String m_subnetId;
393
394 Logging m_logging;
395
396 Aws::String m_keyPair;
397
398 bool m_terminateInstanceOnFailure{false};
399
400 Aws::String m_snsTopicArn;
401
402 Aws::String m_dateCreated;
403
404 Aws::String m_dateUpdated;
405
407
408 InstanceMetadataOptions m_instanceMetadataOptions;
409
411
412 Placement m_placement;
413 bool m_arnHasBeenSet = false;
414 bool m_nameHasBeenSet = false;
415 bool m_descriptionHasBeenSet = false;
416 bool m_instanceTypesHasBeenSet = false;
417 bool m_instanceProfileNameHasBeenSet = false;
418 bool m_securityGroupIdsHasBeenSet = false;
419 bool m_subnetIdHasBeenSet = false;
420 bool m_loggingHasBeenSet = false;
421 bool m_keyPairHasBeenSet = false;
422 bool m_terminateInstanceOnFailureHasBeenSet = false;
423 bool m_snsTopicArnHasBeenSet = false;
424 bool m_dateCreatedHasBeenSet = false;
425 bool m_dateUpdatedHasBeenSet = false;
426 bool m_resourceTagsHasBeenSet = false;
427 bool m_instanceMetadataOptionsHasBeenSet = false;
428 bool m_tagsHasBeenSet = false;
429 bool m_placementHasBeenSet = false;
430};
431
432} // namespace Model
433} // namespace imagebuilder
434} // namespace Aws
InfrastructureConfiguration & WithResourceTags(ResourceTagsT &&value)
InfrastructureConfiguration & WithDateCreated(DateCreatedT &&value)
InfrastructureConfiguration & WithSnsTopicArn(SnsTopicArnT &&value)
InfrastructureConfiguration & WithSubnetId(SubnetIdT &&value)
InfrastructureConfiguration & WithTerminateInstanceOnFailure(bool value)
const InstanceMetadataOptions & GetInstanceMetadataOptions() const
AWS_IMAGEBUILDER_API InfrastructureConfiguration()=default
InfrastructureConfiguration & AddInstanceTypes(InstanceTypesT &&value)
InfrastructureConfiguration & WithKeyPair(KeyPairT &&value)
const Aws::Map< Aws::String, Aws::String > & GetResourceTags() const
InfrastructureConfiguration & WithLogging(LoggingT &&value)
const Aws::Map< Aws::String, Aws::String > & GetTags() const
InfrastructureConfiguration & WithInstanceProfileName(InstanceProfileNameT &&value)
InfrastructureConfiguration & WithInstanceTypes(InstanceTypesT &&value)
InfrastructureConfiguration & WithTags(TagsT &&value)
InfrastructureConfiguration & AddTags(TagsKeyT &&key, TagsValueT &&value)
AWS_IMAGEBUILDER_API InfrastructureConfiguration & operator=(Aws::Utils::Json::JsonView jsonValue)
InfrastructureConfiguration & WithDescription(DescriptionT &&value)
void SetInstanceMetadataOptions(InstanceMetadataOptionsT &&value)
AWS_IMAGEBUILDER_API Aws::Utils::Json::JsonValue Jsonize() const
InfrastructureConfiguration & AddSecurityGroupIds(SecurityGroupIdsT &&value)
InfrastructureConfiguration & WithSecurityGroupIds(SecurityGroupIdsT &&value)
InfrastructureConfiguration & WithName(NameT &&value)
InfrastructureConfiguration & WithPlacement(PlacementT &&value)
const Aws::Vector< Aws::String > & GetInstanceTypes() const
InfrastructureConfiguration & AddResourceTags(ResourceTagsKeyT &&key, ResourceTagsValueT &&value)
AWS_IMAGEBUILDER_API InfrastructureConfiguration(Aws::Utils::Json::JsonView jsonValue)
InfrastructureConfiguration & WithDateUpdated(DateUpdatedT &&value)
const Aws::Vector< Aws::String > & GetSecurityGroupIds() const
InfrastructureConfiguration & WithInstanceMetadataOptions(InstanceMetadataOptionsT &&value)
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue