AWS SDK for C++

AWS SDK for C++ Version 1.11.743

Loading...
Searching...
No Matches
CreatePermissionRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/ram/RAMRequest.h>
10#include <aws/ram/RAM_EXPORTS.h>
11#include <aws/ram/model/Tag.h>
12
13#include <utility>
14
15namespace Aws {
16namespace RAM {
17namespace Model {
18
22 public:
23 AWS_RAM_API CreatePermissionRequest() = default;
24
25 // Service request name is the Operation name which will send this request out,
26 // each operation should has unique request name, so that we can get operation's name from this request.
27 // Note: this is not true for response, multiple operations may have the same response name,
28 // so we can not get operation's name from response.
29 inline virtual const char* GetServiceRequestName() const override { return "CreatePermission"; }
30
31 AWS_RAM_API Aws::String SerializePayload() const override;
32
34
38 inline const Aws::String& GetName() const { return m_name; }
39 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
40 template <typename NameT = Aws::String>
41 void SetName(NameT&& value) {
42 m_nameHasBeenSet = true;
43 m_name = std::forward<NameT>(value);
44 }
45 template <typename NameT = Aws::String>
47 SetName(std::forward<NameT>(value));
48 return *this;
49 }
51
53
62 inline const Aws::String& GetResourceType() const { return m_resourceType; }
63 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
64 template <typename ResourceTypeT = Aws::String>
65 void SetResourceType(ResourceTypeT&& value) {
66 m_resourceTypeHasBeenSet = true;
67 m_resourceType = std::forward<ResourceTypeT>(value);
68 }
69 template <typename ResourceTypeT = Aws::String>
70 CreatePermissionRequest& WithResourceType(ResourceTypeT&& value) {
71 SetResourceType(std::forward<ResourceTypeT>(value));
72 return *this;
73 }
75
77
99 inline const Aws::String& GetPolicyTemplate() const { return m_policyTemplate; }
100 inline bool PolicyTemplateHasBeenSet() const { return m_policyTemplateHasBeenSet; }
101 template <typename PolicyTemplateT = Aws::String>
102 void SetPolicyTemplate(PolicyTemplateT&& value) {
103 m_policyTemplateHasBeenSet = true;
104 m_policyTemplate = std::forward<PolicyTemplateT>(value);
105 }
106 template <typename PolicyTemplateT = Aws::String>
107 CreatePermissionRequest& WithPolicyTemplate(PolicyTemplateT&& value) {
108 SetPolicyTemplate(std::forward<PolicyTemplateT>(value));
109 return *this;
110 }
112
114
126 inline const Aws::String& GetClientToken() const { return m_clientToken; }
127 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
128 template <typename ClientTokenT = Aws::String>
129 void SetClientToken(ClientTokenT&& value) {
130 m_clientTokenHasBeenSet = true;
131 m_clientToken = std::forward<ClientTokenT>(value);
132 }
133 template <typename ClientTokenT = Aws::String>
135 SetClientToken(std::forward<ClientTokenT>(value));
136 return *this;
137 }
139
141
145 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
146 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
147 template <typename TagsT = Aws::Vector<Tag>>
148 void SetTags(TagsT&& value) {
149 m_tagsHasBeenSet = true;
150 m_tags = std::forward<TagsT>(value);
151 }
152 template <typename TagsT = Aws::Vector<Tag>>
154 SetTags(std::forward<TagsT>(value));
155 return *this;
156 }
157 template <typename TagsT = Tag>
159 m_tagsHasBeenSet = true;
160 m_tags.emplace_back(std::forward<TagsT>(value));
161 return *this;
162 }
164 private:
165 Aws::String m_name;
166
167 Aws::String m_resourceType;
168
169 Aws::String m_policyTemplate;
170
171 Aws::String m_clientToken;
172
173 Aws::Vector<Tag> m_tags;
174 bool m_nameHasBeenSet = false;
175 bool m_resourceTypeHasBeenSet = false;
176 bool m_policyTemplateHasBeenSet = false;
177 bool m_clientTokenHasBeenSet = false;
178 bool m_tagsHasBeenSet = false;
179};
180
181} // namespace Model
182} // namespace RAM
183} // namespace Aws
CreatePermissionRequest & WithPolicyTemplate(PolicyTemplateT &&value)
CreatePermissionRequest & WithClientToken(ClientTokenT &&value)
CreatePermissionRequest & AddTags(TagsT &&value)
AWS_RAM_API CreatePermissionRequest()=default
CreatePermissionRequest & WithTags(TagsT &&value)
virtual const char * GetServiceRequestName() const override
CreatePermissionRequest & WithResourceType(ResourceTypeT &&value)
const Aws::Vector< Tag > & GetTags() const
CreatePermissionRequest & WithName(NameT &&value)
AWS_RAM_API Aws::String SerializePayload() const override
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector