AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
ImportKeyPairRequest.h
1
6#pragma once
7#include <aws/ec2/EC2_EXPORTS.h>
8#include <aws/ec2/EC2Request.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/core/utils/Array.h>
12#include <aws/ec2/model/TagSpecification.h>
13#include <utility>
14
15namespace Aws
16{
17namespace EC2
18{
19namespace Model
20{
21
25 {
26 public:
27 AWS_EC2_API ImportKeyPairRequest() = default;
28
29 // Service request name is the Operation name which will send this request out,
30 // each operation should has unique request name, so that we can get operation's name from this request.
31 // Note: this is not true for response, multiple operations may have the same response name,
32 // so we can not get operation's name from response.
33 inline virtual const char* GetServiceRequestName() const override { return "ImportKeyPair"; }
34
35 AWS_EC2_API Aws::String SerializePayload() const override;
36
37 protected:
38 AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
39
40 public:
41
43
46 inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const { return m_tagSpecifications; }
47 inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
48 template<typename TagSpecificationsT = Aws::Vector<TagSpecification>>
49 void SetTagSpecifications(TagSpecificationsT&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications = std::forward<TagSpecificationsT>(value); }
50 template<typename TagSpecificationsT = Aws::Vector<TagSpecification>>
51 ImportKeyPairRequest& WithTagSpecifications(TagSpecificationsT&& value) { SetTagSpecifications(std::forward<TagSpecificationsT>(value)); return *this;}
52 template<typename TagSpecificationsT = TagSpecification>
53 ImportKeyPairRequest& AddTagSpecifications(TagSpecificationsT&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications.emplace_back(std::forward<TagSpecificationsT>(value)); return *this; }
55
57
63 inline bool GetDryRun() const { return m_dryRun; }
64 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
65 inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
66 inline ImportKeyPairRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
68
70
73 inline const Aws::String& GetKeyName() const { return m_keyName; }
74 inline bool KeyNameHasBeenSet() const { return m_keyNameHasBeenSet; }
75 template<typename KeyNameT = Aws::String>
76 void SetKeyName(KeyNameT&& value) { m_keyNameHasBeenSet = true; m_keyName = std::forward<KeyNameT>(value); }
77 template<typename KeyNameT = Aws::String>
78 ImportKeyPairRequest& WithKeyName(KeyNameT&& value) { SetKeyName(std::forward<KeyNameT>(value)); return *this;}
80
82
85 inline const Aws::Utils::ByteBuffer& GetPublicKeyMaterial() const { return m_publicKeyMaterial; }
86 inline bool PublicKeyMaterialHasBeenSet() const { return m_publicKeyMaterialHasBeenSet; }
87 template<typename PublicKeyMaterialT = Aws::Utils::ByteBuffer>
88 void SetPublicKeyMaterial(PublicKeyMaterialT&& value) { m_publicKeyMaterialHasBeenSet = true; m_publicKeyMaterial = std::forward<PublicKeyMaterialT>(value); }
89 template<typename PublicKeyMaterialT = Aws::Utils::ByteBuffer>
90 ImportKeyPairRequest& WithPublicKeyMaterial(PublicKeyMaterialT&& value) { SetPublicKeyMaterial(std::forward<PublicKeyMaterialT>(value)); return *this;}
92 private:
93
94 Aws::Vector<TagSpecification> m_tagSpecifications;
95 bool m_tagSpecificationsHasBeenSet = false;
96
97 bool m_dryRun{false};
98 bool m_dryRunHasBeenSet = false;
99
100 Aws::String m_keyName;
101 bool m_keyNameHasBeenSet = false;
102
103 Aws::Utils::ByteBuffer m_publicKeyMaterial{};
104 bool m_publicKeyMaterialHasBeenSet = false;
105 };
106
107} // namespace Model
108} // namespace EC2
109} // namespace Aws
void SetTagSpecifications(TagSpecificationsT &&value)
const Aws::Utils::ByteBuffer & GetPublicKeyMaterial() const
void SetPublicKeyMaterial(PublicKeyMaterialT &&value)
ImportKeyPairRequest & WithPublicKeyMaterial(PublicKeyMaterialT &&value)
AWS_EC2_API ImportKeyPairRequest()=default
ImportKeyPairRequest & WithDryRun(bool value)
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
virtual const char * GetServiceRequestName() const override
ImportKeyPairRequest & AddTagSpecifications(TagSpecificationsT &&value)
AWS_EC2_API Aws::String SerializePayload() const override
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
ImportKeyPairRequest & WithKeyName(KeyNameT &&value)
ImportKeyPairRequest & WithTagSpecifications(TagSpecificationsT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector