AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
KeyPair.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/lightsail/Lightsail_EXPORTS.h>
11#include <aws/lightsail/model/ResourceLocation.h>
12#include <aws/lightsail/model/ResourceType.h>
13#include <aws/lightsail/model/Tag.h>
14
15#include <utility>
16
17namespace Aws {
18namespace Utils {
19namespace Json {
20class JsonValue;
21class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace Lightsail {
25namespace Model {
26
32class KeyPair {
33 public:
34 AWS_LIGHTSAIL_API KeyPair() = default;
35 AWS_LIGHTSAIL_API KeyPair(Aws::Utils::Json::JsonView jsonValue);
36 AWS_LIGHTSAIL_API KeyPair& operator=(Aws::Utils::Json::JsonView jsonValue);
37 AWS_LIGHTSAIL_API Aws::Utils::Json::JsonValue Jsonize() const;
38
40
43 inline const Aws::String& GetName() const { return m_name; }
44 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
45 template <typename NameT = Aws::String>
46 void SetName(NameT&& value) {
47 m_nameHasBeenSet = true;
48 m_name = std::forward<NameT>(value);
49 }
50 template <typename NameT = Aws::String>
51 KeyPair& WithName(NameT&& value) {
52 SetName(std::forward<NameT>(value));
53 return *this;
54 }
56
58
62 inline const Aws::String& GetArn() const { return m_arn; }
63 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
64 template <typename ArnT = Aws::String>
65 void SetArn(ArnT&& value) {
66 m_arnHasBeenSet = true;
67 m_arn = std::forward<ArnT>(value);
68 }
69 template <typename ArnT = Aws::String>
70 KeyPair& WithArn(ArnT&& value) {
71 SetArn(std::forward<ArnT>(value));
72 return *this;
73 }
75
77
82 inline const Aws::String& GetSupportCode() const { return m_supportCode; }
83 inline bool SupportCodeHasBeenSet() const { return m_supportCodeHasBeenSet; }
84 template <typename SupportCodeT = Aws::String>
85 void SetSupportCode(SupportCodeT&& value) {
86 m_supportCodeHasBeenSet = true;
87 m_supportCode = std::forward<SupportCodeT>(value);
88 }
89 template <typename SupportCodeT = Aws::String>
90 KeyPair& WithSupportCode(SupportCodeT&& value) {
91 SetSupportCode(std::forward<SupportCodeT>(value));
92 return *this;
93 }
95
97
101 inline const Aws::Utils::DateTime& GetCreatedAt() const { return m_createdAt; }
102 inline bool CreatedAtHasBeenSet() const { return m_createdAtHasBeenSet; }
103 template <typename CreatedAtT = Aws::Utils::DateTime>
104 void SetCreatedAt(CreatedAtT&& value) {
105 m_createdAtHasBeenSet = true;
106 m_createdAt = std::forward<CreatedAtT>(value);
107 }
108 template <typename CreatedAtT = Aws::Utils::DateTime>
109 KeyPair& WithCreatedAt(CreatedAtT&& value) {
110 SetCreatedAt(std::forward<CreatedAtT>(value));
111 return *this;
112 }
114
116
119 inline const ResourceLocation& GetLocation() const { return m_location; }
120 inline bool LocationHasBeenSet() const { return m_locationHasBeenSet; }
121 template <typename LocationT = ResourceLocation>
122 void SetLocation(LocationT&& value) {
123 m_locationHasBeenSet = true;
124 m_location = std::forward<LocationT>(value);
125 }
126 template <typename LocationT = ResourceLocation>
127 KeyPair& WithLocation(LocationT&& value) {
128 SetLocation(std::forward<LocationT>(value));
129 return *this;
130 }
132
134
137 inline ResourceType GetResourceType() const { return m_resourceType; }
138 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
139 inline void SetResourceType(ResourceType value) {
140 m_resourceTypeHasBeenSet = true;
141 m_resourceType = value;
142 }
144 SetResourceType(value);
145 return *this;
146 }
148
150
156 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
157 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
158 template <typename TagsT = Aws::Vector<Tag>>
159 void SetTags(TagsT&& value) {
160 m_tagsHasBeenSet = true;
161 m_tags = std::forward<TagsT>(value);
162 }
163 template <typename TagsT = Aws::Vector<Tag>>
164 KeyPair& WithTags(TagsT&& value) {
165 SetTags(std::forward<TagsT>(value));
166 return *this;
167 }
168 template <typename TagsT = Tag>
169 KeyPair& AddTags(TagsT&& value) {
170 m_tagsHasBeenSet = true;
171 m_tags.emplace_back(std::forward<TagsT>(value));
172 return *this;
173 }
175
177
180 inline const Aws::String& GetFingerprint() const { return m_fingerprint; }
181 inline bool FingerprintHasBeenSet() const { return m_fingerprintHasBeenSet; }
182 template <typename FingerprintT = Aws::String>
183 void SetFingerprint(FingerprintT&& value) {
184 m_fingerprintHasBeenSet = true;
185 m_fingerprint = std::forward<FingerprintT>(value);
186 }
187 template <typename FingerprintT = Aws::String>
188 KeyPair& WithFingerprint(FingerprintT&& value) {
189 SetFingerprint(std::forward<FingerprintT>(value));
190 return *this;
191 }
193 private:
194 Aws::String m_name;
195
196 Aws::String m_arn;
197
198 Aws::String m_supportCode;
199
200 Aws::Utils::DateTime m_createdAt{};
201
202 ResourceLocation m_location;
203
204 ResourceType m_resourceType{ResourceType::NOT_SET};
205
206 Aws::Vector<Tag> m_tags;
207
208 Aws::String m_fingerprint;
209 bool m_nameHasBeenSet = false;
210 bool m_arnHasBeenSet = false;
211 bool m_supportCodeHasBeenSet = false;
212 bool m_createdAtHasBeenSet = false;
213 bool m_locationHasBeenSet = false;
214 bool m_resourceTypeHasBeenSet = false;
215 bool m_tagsHasBeenSet = false;
216 bool m_fingerprintHasBeenSet = false;
217};
218
219} // namespace Model
220} // namespace Lightsail
221} // namespace Aws
const Aws::Utils::DateTime & GetCreatedAt() const
Definition KeyPair.h:101
const Aws::Vector< Tag > & GetTags() const
Definition KeyPair.h:156
bool LocationHasBeenSet() const
Definition KeyPair.h:120
KeyPair & WithArn(ArnT &&value)
Definition KeyPair.h:70
const Aws::String & GetName() const
Definition KeyPair.h:43
AWS_LIGHTSAIL_API KeyPair()=default
KeyPair & WithName(NameT &&value)
Definition KeyPair.h:51
void SetFingerprint(FingerprintT &&value)
Definition KeyPair.h:183
ResourceType GetResourceType() const
Definition KeyPair.h:137
bool FingerprintHasBeenSet() const
Definition KeyPair.h:181
AWS_LIGHTSAIL_API KeyPair & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetCreatedAt(CreatedAtT &&value)
Definition KeyPair.h:104
KeyPair & AddTags(TagsT &&value)
Definition KeyPair.h:169
void SetTags(TagsT &&value)
Definition KeyPair.h:159
void SetSupportCode(SupportCodeT &&value)
Definition KeyPair.h:85
KeyPair & WithLocation(LocationT &&value)
Definition KeyPair.h:127
const Aws::String & GetSupportCode() const
Definition KeyPair.h:82
bool ResourceTypeHasBeenSet() const
Definition KeyPair.h:138
KeyPair & WithTags(TagsT &&value)
Definition KeyPair.h:164
KeyPair & WithSupportCode(SupportCodeT &&value)
Definition KeyPair.h:90
void SetName(NameT &&value)
Definition KeyPair.h:46
KeyPair & WithResourceType(ResourceType value)
Definition KeyPair.h:143
const Aws::String & GetFingerprint() const
Definition KeyPair.h:180
KeyPair & WithCreatedAt(CreatedAtT &&value)
Definition KeyPair.h:109
void SetResourceType(ResourceType value)
Definition KeyPair.h:139
void SetLocation(LocationT &&value)
Definition KeyPair.h:122
bool CreatedAtHasBeenSet() const
Definition KeyPair.h:102
bool SupportCodeHasBeenSet() const
Definition KeyPair.h:83
void SetArn(ArnT &&value)
Definition KeyPair.h:65
AWS_LIGHTSAIL_API KeyPair(Aws::Utils::Json::JsonView jsonValue)
const ResourceLocation & GetLocation() const
Definition KeyPair.h:119
const Aws::String & GetArn() const
Definition KeyPair.h:62
KeyPair & WithFingerprint(FingerprintT &&value)
Definition KeyPair.h:188
AWS_LIGHTSAIL_API Aws::Utils::Json::JsonValue Jsonize() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue