AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
CreatePolicyRequest.h
1
6#pragma once
7#include <aws/organizations/Organizations_EXPORTS.h>
8#include <aws/organizations/OrganizationsRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/organizations/model/PolicyType.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <aws/organizations/model/Tag.h>
13#include <utility>
14
15namespace Aws
16{
17namespace Organizations
18{
19namespace Model
20{
21
25 {
26 public:
27 AWS_ORGANIZATIONS_API CreatePolicyRequest() = 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 "CreatePolicy"; }
34
35 AWS_ORGANIZATIONS_API Aws::String SerializePayload() const override;
36
37 AWS_ORGANIZATIONS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
38
39
41
49 inline const Aws::String& GetContent() const { return m_content; }
50 inline bool ContentHasBeenSet() const { return m_contentHasBeenSet; }
51 template<typename ContentT = Aws::String>
52 void SetContent(ContentT&& value) { m_contentHasBeenSet = true; m_content = std::forward<ContentT>(value); }
53 template<typename ContentT = Aws::String>
54 CreatePolicyRequest& WithContent(ContentT&& value) { SetContent(std::forward<ContentT>(value)); return *this;}
56
58
61 inline const Aws::String& GetDescription() const { return m_description; }
62 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
63 template<typename DescriptionT = Aws::String>
64 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
65 template<typename DescriptionT = Aws::String>
66 CreatePolicyRequest& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
68
70
76 inline const Aws::String& GetName() const { return m_name; }
77 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
78 template<typename NameT = Aws::String>
79 void SetName(NameT&& value) { m_nameHasBeenSet = true; m_name = std::forward<NameT>(value); }
80 template<typename NameT = Aws::String>
81 CreatePolicyRequest& WithName(NameT&& value) { SetName(std::forward<NameT>(value)); return *this;}
83
85
105 inline PolicyType GetType() const { return m_type; }
106 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
107 inline void SetType(PolicyType value) { m_typeHasBeenSet = true; m_type = value; }
108 inline CreatePolicyRequest& WithType(PolicyType value) { SetType(value); return *this;}
110
112
123 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
124 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
125 template<typename TagsT = Aws::Vector<Tag>>
126 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
127 template<typename TagsT = Aws::Vector<Tag>>
128 CreatePolicyRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
129 template<typename TagsT = Tag>
130 CreatePolicyRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
132 private:
133
134 Aws::String m_content;
135 bool m_contentHasBeenSet = false;
136
137 Aws::String m_description;
138 bool m_descriptionHasBeenSet = false;
139
140 Aws::String m_name;
141 bool m_nameHasBeenSet = false;
142
144 bool m_typeHasBeenSet = false;
145
146 Aws::Vector<Tag> m_tags;
147 bool m_tagsHasBeenSet = false;
148 };
149
150} // namespace Model
151} // namespace Organizations
152} // namespace Aws
CreatePolicyRequest & WithTags(TagsT &&value)
AWS_ORGANIZATIONS_API Aws::String SerializePayload() const override
AWS_ORGANIZATIONS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreatePolicyRequest & WithContent(ContentT &&value)
AWS_ORGANIZATIONS_API CreatePolicyRequest()=default
CreatePolicyRequest & WithDescription(DescriptionT &&value)
CreatePolicyRequest & WithName(NameT &&value)
CreatePolicyRequest & AddTags(TagsT &&value)
virtual const char * GetServiceRequestName() const override
CreatePolicyRequest & WithType(PolicyType value)
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector