AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
RevokeSecurityGroupEgressRequest.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/ec2/model/IpPermission.h>
12#include <utility>
13
14namespace Aws
15{
16namespace EC2
17{
18namespace Model
19{
20
24 {
25 public:
26 AWS_EC2_API RevokeSecurityGroupEgressRequest() = 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 "RevokeSecurityGroupEgress"; }
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
45 inline const Aws::Vector<Aws::String>& GetSecurityGroupRuleIds() const { return m_securityGroupRuleIds; }
46 inline bool SecurityGroupRuleIdsHasBeenSet() const { return m_securityGroupRuleIdsHasBeenSet; }
47 template<typename SecurityGroupRuleIdsT = Aws::Vector<Aws::String>>
48 void SetSecurityGroupRuleIds(SecurityGroupRuleIdsT&& value) { m_securityGroupRuleIdsHasBeenSet = true; m_securityGroupRuleIds = std::forward<SecurityGroupRuleIdsT>(value); }
49 template<typename SecurityGroupRuleIdsT = Aws::Vector<Aws::String>>
50 RevokeSecurityGroupEgressRequest& WithSecurityGroupRuleIds(SecurityGroupRuleIdsT&& value) { SetSecurityGroupRuleIds(std::forward<SecurityGroupRuleIdsT>(value)); return *this;}
51 template<typename SecurityGroupRuleIdsT = Aws::String>
52 RevokeSecurityGroupEgressRequest& AddSecurityGroupRuleIds(SecurityGroupRuleIdsT&& value) { m_securityGroupRuleIdsHasBeenSet = true; m_securityGroupRuleIds.emplace_back(std::forward<SecurityGroupRuleIdsT>(value)); return *this; }
54
56
62 inline bool GetDryRun() const { return m_dryRun; }
63 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
64 inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
65 inline RevokeSecurityGroupEgressRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
67
69
72 inline const Aws::String& GetGroupId() const { return m_groupId; }
73 inline bool GroupIdHasBeenSet() const { return m_groupIdHasBeenSet; }
74 template<typename GroupIdT = Aws::String>
75 void SetGroupId(GroupIdT&& value) { m_groupIdHasBeenSet = true; m_groupId = std::forward<GroupIdT>(value); }
76 template<typename GroupIdT = Aws::String>
77 RevokeSecurityGroupEgressRequest& WithGroupId(GroupIdT&& value) { SetGroupId(std::forward<GroupIdT>(value)); return *this;}
79
81
85 inline const Aws::String& GetSourceSecurityGroupName() const { return m_sourceSecurityGroupName; }
86 inline bool SourceSecurityGroupNameHasBeenSet() const { return m_sourceSecurityGroupNameHasBeenSet; }
87 template<typename SourceSecurityGroupNameT = Aws::String>
88 void SetSourceSecurityGroupName(SourceSecurityGroupNameT&& value) { m_sourceSecurityGroupNameHasBeenSet = true; m_sourceSecurityGroupName = std::forward<SourceSecurityGroupNameT>(value); }
89 template<typename SourceSecurityGroupNameT = Aws::String>
90 RevokeSecurityGroupEgressRequest& WithSourceSecurityGroupName(SourceSecurityGroupNameT&& value) { SetSourceSecurityGroupName(std::forward<SourceSecurityGroupNameT>(value)); return *this;}
92
94
98 inline const Aws::String& GetSourceSecurityGroupOwnerId() const { return m_sourceSecurityGroupOwnerId; }
99 inline bool SourceSecurityGroupOwnerIdHasBeenSet() const { return m_sourceSecurityGroupOwnerIdHasBeenSet; }
100 template<typename SourceSecurityGroupOwnerIdT = Aws::String>
101 void SetSourceSecurityGroupOwnerId(SourceSecurityGroupOwnerIdT&& value) { m_sourceSecurityGroupOwnerIdHasBeenSet = true; m_sourceSecurityGroupOwnerId = std::forward<SourceSecurityGroupOwnerIdT>(value); }
102 template<typename SourceSecurityGroupOwnerIdT = Aws::String>
103 RevokeSecurityGroupEgressRequest& WithSourceSecurityGroupOwnerId(SourceSecurityGroupOwnerIdT&& value) { SetSourceSecurityGroupOwnerId(std::forward<SourceSecurityGroupOwnerIdT>(value)); return *this;}
105
107
111 inline const Aws::String& GetIpProtocol() const { return m_ipProtocol; }
112 inline bool IpProtocolHasBeenSet() const { return m_ipProtocolHasBeenSet; }
113 template<typename IpProtocolT = Aws::String>
114 void SetIpProtocol(IpProtocolT&& value) { m_ipProtocolHasBeenSet = true; m_ipProtocol = std::forward<IpProtocolT>(value); }
115 template<typename IpProtocolT = Aws::String>
116 RevokeSecurityGroupEgressRequest& WithIpProtocol(IpProtocolT&& value) { SetIpProtocol(std::forward<IpProtocolT>(value)); return *this;}
118
120
123 inline int GetFromPort() const { return m_fromPort; }
124 inline bool FromPortHasBeenSet() const { return m_fromPortHasBeenSet; }
125 inline void SetFromPort(int value) { m_fromPortHasBeenSet = true; m_fromPort = value; }
126 inline RevokeSecurityGroupEgressRequest& WithFromPort(int value) { SetFromPort(value); return *this;}
128
130
133 inline int GetToPort() const { return m_toPort; }
134 inline bool ToPortHasBeenSet() const { return m_toPortHasBeenSet; }
135 inline void SetToPort(int value) { m_toPortHasBeenSet = true; m_toPort = value; }
136 inline RevokeSecurityGroupEgressRequest& WithToPort(int value) { SetToPort(value); return *this;}
138
140
143 inline const Aws::String& GetCidrIp() const { return m_cidrIp; }
144 inline bool CidrIpHasBeenSet() const { return m_cidrIpHasBeenSet; }
145 template<typename CidrIpT = Aws::String>
146 void SetCidrIp(CidrIpT&& value) { m_cidrIpHasBeenSet = true; m_cidrIp = std::forward<CidrIpT>(value); }
147 template<typename CidrIpT = Aws::String>
148 RevokeSecurityGroupEgressRequest& WithCidrIp(CidrIpT&& value) { SetCidrIp(std::forward<CidrIpT>(value)); return *this;}
150
152
156 inline const Aws::Vector<IpPermission>& GetIpPermissions() const { return m_ipPermissions; }
157 inline bool IpPermissionsHasBeenSet() const { return m_ipPermissionsHasBeenSet; }
158 template<typename IpPermissionsT = Aws::Vector<IpPermission>>
159 void SetIpPermissions(IpPermissionsT&& value) { m_ipPermissionsHasBeenSet = true; m_ipPermissions = std::forward<IpPermissionsT>(value); }
160 template<typename IpPermissionsT = Aws::Vector<IpPermission>>
161 RevokeSecurityGroupEgressRequest& WithIpPermissions(IpPermissionsT&& value) { SetIpPermissions(std::forward<IpPermissionsT>(value)); return *this;}
162 template<typename IpPermissionsT = IpPermission>
163 RevokeSecurityGroupEgressRequest& AddIpPermissions(IpPermissionsT&& value) { m_ipPermissionsHasBeenSet = true; m_ipPermissions.emplace_back(std::forward<IpPermissionsT>(value)); return *this; }
165 private:
166
167 Aws::Vector<Aws::String> m_securityGroupRuleIds;
168 bool m_securityGroupRuleIdsHasBeenSet = false;
169
170 bool m_dryRun{false};
171 bool m_dryRunHasBeenSet = false;
172
173 Aws::String m_groupId;
174 bool m_groupIdHasBeenSet = false;
175
176 Aws::String m_sourceSecurityGroupName;
177 bool m_sourceSecurityGroupNameHasBeenSet = false;
178
179 Aws::String m_sourceSecurityGroupOwnerId;
180 bool m_sourceSecurityGroupOwnerIdHasBeenSet = false;
181
182 Aws::String m_ipProtocol;
183 bool m_ipProtocolHasBeenSet = false;
184
185 int m_fromPort{0};
186 bool m_fromPortHasBeenSet = false;
187
188 int m_toPort{0};
189 bool m_toPortHasBeenSet = false;
190
191 Aws::String m_cidrIp;
192 bool m_cidrIpHasBeenSet = false;
193
194 Aws::Vector<IpPermission> m_ipPermissions;
195 bool m_ipPermissionsHasBeenSet = false;
196 };
197
198} // namespace Model
199} // namespace EC2
200} // namespace Aws
void SetSourceSecurityGroupName(SourceSecurityGroupNameT &&value)
RevokeSecurityGroupEgressRequest & WithSourceSecurityGroupOwnerId(SourceSecurityGroupOwnerIdT &&value)
RevokeSecurityGroupEgressRequest & WithIpPermissions(IpPermissionsT &&value)
RevokeSecurityGroupEgressRequest & WithToPort(int value)
const Aws::Vector< IpPermission > & GetIpPermissions() const
RevokeSecurityGroupEgressRequest & WithIpProtocol(IpProtocolT &&value)
RevokeSecurityGroupEgressRequest & WithDryRun(bool value)
AWS_EC2_API Aws::String SerializePayload() const override
void SetSourceSecurityGroupOwnerId(SourceSecurityGroupOwnerIdT &&value)
RevokeSecurityGroupEgressRequest & WithFromPort(int value)
const Aws::Vector< Aws::String > & GetSecurityGroupRuleIds() const
RevokeSecurityGroupEgressRequest & AddIpPermissions(IpPermissionsT &&value)
RevokeSecurityGroupEgressRequest & WithSourceSecurityGroupName(SourceSecurityGroupNameT &&value)
RevokeSecurityGroupEgressRequest & AddSecurityGroupRuleIds(SecurityGroupRuleIdsT &&value)
RevokeSecurityGroupEgressRequest & WithCidrIp(CidrIpT &&value)
RevokeSecurityGroupEgressRequest & WithGroupId(GroupIdT &&value)
RevokeSecurityGroupEgressRequest & WithSecurityGroupRuleIds(SecurityGroupRuleIdsT &&value)
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector