AWS SDK for C++

AWS SDK for C++ Version 1.11.719

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
181 inline const Logging& GetLogging() const { return m_logging; }
182 inline bool LoggingHasBeenSet() const { return m_loggingHasBeenSet; }
183 template <typename LoggingT = Logging>
184 void SetLogging(LoggingT&& value) {
185 m_loggingHasBeenSet = true;
186 m_logging = std::forward<LoggingT>(value);
187 }
188 template <typename LoggingT = Logging>
190 SetLogging(std::forward<LoggingT>(value));
191 return *this;
192 }
194
196
199 inline const Aws::String& GetKeyPair() const { return m_keyPair; }
200 inline bool KeyPairHasBeenSet() const { return m_keyPairHasBeenSet; }
201 template <typename KeyPairT = Aws::String>
202 void SetKeyPair(KeyPairT&& value) {
203 m_keyPairHasBeenSet = true;
204 m_keyPair = std::forward<KeyPairT>(value);
205 }
206 template <typename KeyPairT = Aws::String>
208 SetKeyPair(std::forward<KeyPairT>(value));
209 return *this;
210 }
212
214
218 inline bool GetTerminateInstanceOnFailure() const { return m_terminateInstanceOnFailure; }
219 inline bool TerminateInstanceOnFailureHasBeenSet() const { return m_terminateInstanceOnFailureHasBeenSet; }
220 inline void SetTerminateInstanceOnFailure(bool value) {
221 m_terminateInstanceOnFailureHasBeenSet = true;
222 m_terminateInstanceOnFailure = value;
223 }
226 return *this;
227 }
229
231
238 inline const Aws::String& GetSnsTopicArn() const { return m_snsTopicArn; }
239 inline bool SnsTopicArnHasBeenSet() const { return m_snsTopicArnHasBeenSet; }
240 template <typename SnsTopicArnT = Aws::String>
241 void SetSnsTopicArn(SnsTopicArnT&& value) {
242 m_snsTopicArnHasBeenSet = true;
243 m_snsTopicArn = std::forward<SnsTopicArnT>(value);
244 }
245 template <typename SnsTopicArnT = Aws::String>
247 SetSnsTopicArn(std::forward<SnsTopicArnT>(value));
248 return *this;
249 }
251
253
256 inline const Aws::String& GetDateCreated() const { return m_dateCreated; }
257 inline bool DateCreatedHasBeenSet() const { return m_dateCreatedHasBeenSet; }
258 template <typename DateCreatedT = Aws::String>
259 void SetDateCreated(DateCreatedT&& value) {
260 m_dateCreatedHasBeenSet = true;
261 m_dateCreated = std::forward<DateCreatedT>(value);
262 }
263 template <typename DateCreatedT = Aws::String>
265 SetDateCreated(std::forward<DateCreatedT>(value));
266 return *this;
267 }
269
271
274 inline const Aws::String& GetDateUpdated() const { return m_dateUpdated; }
275 inline bool DateUpdatedHasBeenSet() const { return m_dateUpdatedHasBeenSet; }
276 template <typename DateUpdatedT = Aws::String>
277 void SetDateUpdated(DateUpdatedT&& value) {
278 m_dateUpdatedHasBeenSet = true;
279 m_dateUpdated = std::forward<DateUpdatedT>(value);
280 }
281 template <typename DateUpdatedT = Aws::String>
283 SetDateUpdated(std::forward<DateUpdatedT>(value));
284 return *this;
285 }
287
289
292 inline const Aws::Map<Aws::String, Aws::String>& GetResourceTags() const { return m_resourceTags; }
293 inline bool ResourceTagsHasBeenSet() const { return m_resourceTagsHasBeenSet; }
294 template <typename ResourceTagsT = Aws::Map<Aws::String, Aws::String>>
295 void SetResourceTags(ResourceTagsT&& value) {
296 m_resourceTagsHasBeenSet = true;
297 m_resourceTags = std::forward<ResourceTagsT>(value);
298 }
299 template <typename ResourceTagsT = Aws::Map<Aws::String, Aws::String>>
301 SetResourceTags(std::forward<ResourceTagsT>(value));
302 return *this;
303 }
304 template <typename ResourceTagsKeyT = Aws::String, typename ResourceTagsValueT = Aws::String>
305 InfrastructureConfiguration& AddResourceTags(ResourceTagsKeyT&& key, ResourceTagsValueT&& value) {
306 m_resourceTagsHasBeenSet = true;
307 m_resourceTags.emplace(std::forward<ResourceTagsKeyT>(key), std::forward<ResourceTagsValueT>(value));
308 return *this;
309 }
311
313
317 inline const InstanceMetadataOptions& GetInstanceMetadataOptions() const { return m_instanceMetadataOptions; }
318 inline bool InstanceMetadataOptionsHasBeenSet() const { return m_instanceMetadataOptionsHasBeenSet; }
319 template <typename InstanceMetadataOptionsT = InstanceMetadataOptions>
320 void SetInstanceMetadataOptions(InstanceMetadataOptionsT&& value) {
321 m_instanceMetadataOptionsHasBeenSet = true;
322 m_instanceMetadataOptions = std::forward<InstanceMetadataOptionsT>(value);
323 }
324 template <typename InstanceMetadataOptionsT = InstanceMetadataOptions>
325 InfrastructureConfiguration& WithInstanceMetadataOptions(InstanceMetadataOptionsT&& value) {
326 SetInstanceMetadataOptions(std::forward<InstanceMetadataOptionsT>(value));
327 return *this;
328 }
330
332
335 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
336 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
337 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
338 void SetTags(TagsT&& value) {
339 m_tagsHasBeenSet = true;
340 m_tags = std::forward<TagsT>(value);
341 }
342 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
344 SetTags(std::forward<TagsT>(value));
345 return *this;
346 }
347 template <typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
348 InfrastructureConfiguration& AddTags(TagsKeyT&& key, TagsValueT&& value) {
349 m_tagsHasBeenSet = true;
350 m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value));
351 return *this;
352 }
354
356
360 inline const Placement& GetPlacement() const { return m_placement; }
361 inline bool PlacementHasBeenSet() const { return m_placementHasBeenSet; }
362 template <typename PlacementT = Placement>
363 void SetPlacement(PlacementT&& value) {
364 m_placementHasBeenSet = true;
365 m_placement = std::forward<PlacementT>(value);
366 }
367 template <typename PlacementT = Placement>
369 SetPlacement(std::forward<PlacementT>(value));
370 return *this;
371 }
373 private:
374 Aws::String m_arn;
375
376 Aws::String m_name;
377
378 Aws::String m_description;
379
380 Aws::Vector<Aws::String> m_instanceTypes;
381
382 Aws::String m_instanceProfileName;
383
384 Aws::Vector<Aws::String> m_securityGroupIds;
385
386 Aws::String m_subnetId;
387
388 Logging m_logging;
389
390 Aws::String m_keyPair;
391
392 bool m_terminateInstanceOnFailure{false};
393
394 Aws::String m_snsTopicArn;
395
396 Aws::String m_dateCreated;
397
398 Aws::String m_dateUpdated;
399
401
402 InstanceMetadataOptions m_instanceMetadataOptions;
403
405
406 Placement m_placement;
407 bool m_arnHasBeenSet = false;
408 bool m_nameHasBeenSet = false;
409 bool m_descriptionHasBeenSet = false;
410 bool m_instanceTypesHasBeenSet = false;
411 bool m_instanceProfileNameHasBeenSet = false;
412 bool m_securityGroupIdsHasBeenSet = false;
413 bool m_subnetIdHasBeenSet = false;
414 bool m_loggingHasBeenSet = false;
415 bool m_keyPairHasBeenSet = false;
416 bool m_terminateInstanceOnFailureHasBeenSet = false;
417 bool m_snsTopicArnHasBeenSet = false;
418 bool m_dateCreatedHasBeenSet = false;
419 bool m_dateUpdatedHasBeenSet = false;
420 bool m_resourceTagsHasBeenSet = false;
421 bool m_instanceMetadataOptionsHasBeenSet = false;
422 bool m_tagsHasBeenSet = false;
423 bool m_placementHasBeenSet = false;
424};
425
426} // namespace Model
427} // namespace imagebuilder
428} // 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