AWS SDK for C++

AWS SDK for C++ Version 1.11.440

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();
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 inline void SetContent(const Aws::String& value) { m_contentHasBeenSet = true; m_content = value; }
52 inline void SetContent(Aws::String&& value) { m_contentHasBeenSet = true; m_content = std::move(value); }
53 inline void SetContent(const char* value) { m_contentHasBeenSet = true; m_content.assign(value); }
54 inline CreatePolicyRequest& WithContent(const Aws::String& value) { SetContent(value); return *this;}
55 inline CreatePolicyRequest& WithContent(Aws::String&& value) { SetContent(std::move(value)); return *this;}
56 inline CreatePolicyRequest& WithContent(const char* value) { SetContent(value); return *this;}
58
60
63 inline const Aws::String& GetDescription() const{ return m_description; }
64 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
65 inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; }
66 inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); }
67 inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); }
68 inline CreatePolicyRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;}
69 inline CreatePolicyRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;}
70 inline CreatePolicyRequest& WithDescription(const char* value) { SetDescription(value); return *this;}
72
74
80 inline const Aws::String& GetName() const{ return m_name; }
81 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
82 inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; }
83 inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); }
84 inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); }
85 inline CreatePolicyRequest& WithName(const Aws::String& value) { SetName(value); return *this;}
86 inline CreatePolicyRequest& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;}
87 inline CreatePolicyRequest& WithName(const char* value) { SetName(value); return *this;}
89
91
105 inline const PolicyType& GetType() const{ return m_type; }
106 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
107 inline void SetType(const PolicyType& value) { m_typeHasBeenSet = true; m_type = value; }
108 inline void SetType(PolicyType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); }
109 inline CreatePolicyRequest& WithType(const PolicyType& value) { SetType(value); return *this;}
110 inline CreatePolicyRequest& WithType(PolicyType&& value) { SetType(std::move(value)); return *this;}
112
114
125 inline const Aws::Vector<Tag>& GetTags() const{ return m_tags; }
126 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
127 inline void SetTags(const Aws::Vector<Tag>& value) { m_tagsHasBeenSet = true; m_tags = value; }
128 inline void SetTags(Aws::Vector<Tag>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); }
129 inline CreatePolicyRequest& WithTags(const Aws::Vector<Tag>& value) { SetTags(value); return *this;}
130 inline CreatePolicyRequest& WithTags(Aws::Vector<Tag>&& value) { SetTags(std::move(value)); return *this;}
131 inline CreatePolicyRequest& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
132 inline CreatePolicyRequest& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; }
134 private:
135
136 Aws::String m_content;
137 bool m_contentHasBeenSet = false;
138
139 Aws::String m_description;
140 bool m_descriptionHasBeenSet = false;
141
142 Aws::String m_name;
143 bool m_nameHasBeenSet = false;
144
145 PolicyType m_type;
146 bool m_typeHasBeenSet = false;
147
148 Aws::Vector<Tag> m_tags;
149 bool m_tagsHasBeenSet = false;
150 };
151
152} // namespace Model
153} // namespace Organizations
154} // namespace Aws
CreatePolicyRequest & WithType(const PolicyType &value)
AWS_ORGANIZATIONS_API Aws::String SerializePayload() const override
CreatePolicyRequest & WithTags(Aws::Vector< Tag > &&value)
CreatePolicyRequest & WithDescription(Aws::String &&value)
AWS_ORGANIZATIONS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreatePolicyRequest & WithContent(const char *value)
CreatePolicyRequest & WithName(const char *value)
CreatePolicyRequest & WithDescription(const char *value)
CreatePolicyRequest & WithType(PolicyType &&value)
void SetTags(const Aws::Vector< Tag > &value)
CreatePolicyRequest & WithDescription(const Aws::String &value)
CreatePolicyRequest & WithContent(Aws::String &&value)
CreatePolicyRequest & WithName(const Aws::String &value)
CreatePolicyRequest & WithContent(const Aws::String &value)
CreatePolicyRequest & AddTags(const Tag &value)
CreatePolicyRequest & WithTags(const Aws::Vector< Tag > &value)
virtual const char * GetServiceRequestName() const override
CreatePolicyRequest & WithName(Aws::String &&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