AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
CreateSecurityGroupRequest.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/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/ec2/model/TagSpecification.h>
12#include <utility>
13
14namespace Aws
15{
16namespace EC2
17{
18namespace Model
19{
20
24 {
25 public:
26 AWS_EC2_API CreateSecurityGroupRequest() = default;
27
28 // Service request name is the Operation name which will send this request out,
29 // each operation should has unique request name, so that we can get operation's name from this request.
30 // Note: this is not true for response, multiple operations may have the same response name,
31 // so we can not get operation's name from response.
32 inline virtual const char* GetServiceRequestName() const override { return "CreateSecurityGroup"; }
33
34 AWS_EC2_API Aws::String SerializePayload() const override;
35
36 protected:
37 AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
38
39 public:
40
42
47 inline const Aws::String& GetDescription() const { return m_description; }
48 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
49 template<typename DescriptionT = Aws::String>
50 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
51 template<typename DescriptionT = Aws::String>
52 CreateSecurityGroupRequest& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
54
56
62 inline const Aws::String& GetGroupName() const { return m_groupName; }
63 inline bool GroupNameHasBeenSet() const { return m_groupNameHasBeenSet; }
64 template<typename GroupNameT = Aws::String>
65 void SetGroupName(GroupNameT&& value) { m_groupNameHasBeenSet = true; m_groupName = std::forward<GroupNameT>(value); }
66 template<typename GroupNameT = Aws::String>
67 CreateSecurityGroupRequest& WithGroupName(GroupNameT&& value) { SetGroupName(std::forward<GroupNameT>(value)); return *this;}
69
71
74 inline const Aws::String& GetVpcId() const { return m_vpcId; }
75 inline bool VpcIdHasBeenSet() const { return m_vpcIdHasBeenSet; }
76 template<typename VpcIdT = Aws::String>
77 void SetVpcId(VpcIdT&& value) { m_vpcIdHasBeenSet = true; m_vpcId = std::forward<VpcIdT>(value); }
78 template<typename VpcIdT = Aws::String>
79 CreateSecurityGroupRequest& WithVpcId(VpcIdT&& value) { SetVpcId(std::forward<VpcIdT>(value)); return *this;}
81
83
86 inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const { return m_tagSpecifications; }
87 inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
88 template<typename TagSpecificationsT = Aws::Vector<TagSpecification>>
89 void SetTagSpecifications(TagSpecificationsT&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications = std::forward<TagSpecificationsT>(value); }
90 template<typename TagSpecificationsT = Aws::Vector<TagSpecification>>
91 CreateSecurityGroupRequest& WithTagSpecifications(TagSpecificationsT&& value) { SetTagSpecifications(std::forward<TagSpecificationsT>(value)); return *this;}
92 template<typename TagSpecificationsT = TagSpecification>
93 CreateSecurityGroupRequest& AddTagSpecifications(TagSpecificationsT&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications.emplace_back(std::forward<TagSpecificationsT>(value)); return *this; }
95
97
103 inline bool GetDryRun() const { return m_dryRun; }
104 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
105 inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
106 inline CreateSecurityGroupRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
108 private:
109
110 Aws::String m_description;
111 bool m_descriptionHasBeenSet = false;
112
113 Aws::String m_groupName;
114 bool m_groupNameHasBeenSet = false;
115
116 Aws::String m_vpcId;
117 bool m_vpcIdHasBeenSet = false;
118
119 Aws::Vector<TagSpecification> m_tagSpecifications;
120 bool m_tagSpecificationsHasBeenSet = false;
121
122 bool m_dryRun{false};
123 bool m_dryRunHasBeenSet = false;
124 };
125
126} // namespace Model
127} // namespace EC2
128} // namespace Aws
CreateSecurityGroupRequest & WithVpcId(VpcIdT &&value)
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
virtual const char * GetServiceRequestName() const override
CreateSecurityGroupRequest & AddTagSpecifications(TagSpecificationsT &&value)
CreateSecurityGroupRequest & WithDryRun(bool value)
CreateSecurityGroupRequest & WithGroupName(GroupNameT &&value)
void SetTagSpecifications(TagSpecificationsT &&value)
CreateSecurityGroupRequest & WithDescription(DescriptionT &&value)
CreateSecurityGroupRequest & WithTagSpecifications(TagSpecificationsT &&value)
AWS_EC2_API CreateSecurityGroupRequest()=default
AWS_EC2_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