AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
SecurityGroupRuleRequest.h
1
6#pragma once
7#include <aws/ec2/EC2_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <utility>
11
12namespace Aws
13{
14namespace Utils
15{
16namespace Xml
17{
18 class XmlNode;
19} // namespace Xml
20} // namespace Utils
21namespace EC2
22{
23namespace Model
24{
25
38 {
39 public:
43
44 AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
45 AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
46
47
49
55 inline const Aws::String& GetIpProtocol() const{ return m_ipProtocol; }
56 inline bool IpProtocolHasBeenSet() const { return m_ipProtocolHasBeenSet; }
57 inline void SetIpProtocol(const Aws::String& value) { m_ipProtocolHasBeenSet = true; m_ipProtocol = value; }
58 inline void SetIpProtocol(Aws::String&& value) { m_ipProtocolHasBeenSet = true; m_ipProtocol = std::move(value); }
59 inline void SetIpProtocol(const char* value) { m_ipProtocolHasBeenSet = true; m_ipProtocol.assign(value); }
60 inline SecurityGroupRuleRequest& WithIpProtocol(const Aws::String& value) { SetIpProtocol(value); return *this;}
61 inline SecurityGroupRuleRequest& WithIpProtocol(Aws::String&& value) { SetIpProtocol(std::move(value)); return *this;}
62 inline SecurityGroupRuleRequest& WithIpProtocol(const char* value) { SetIpProtocol(value); return *this;}
64
66
70 inline int GetFromPort() const{ return m_fromPort; }
71 inline bool FromPortHasBeenSet() const { return m_fromPortHasBeenSet; }
72 inline void SetFromPort(int value) { m_fromPortHasBeenSet = true; m_fromPort = value; }
73 inline SecurityGroupRuleRequest& WithFromPort(int value) { SetFromPort(value); return *this;}
75
77
83 inline int GetToPort() const{ return m_toPort; }
84 inline bool ToPortHasBeenSet() const { return m_toPortHasBeenSet; }
85 inline void SetToPort(int value) { m_toPortHasBeenSet = true; m_toPort = value; }
86 inline SecurityGroupRuleRequest& WithToPort(int value) { SetToPort(value); return *this;}
88
90
94 inline const Aws::String& GetCidrIpv4() const{ return m_cidrIpv4; }
95 inline bool CidrIpv4HasBeenSet() const { return m_cidrIpv4HasBeenSet; }
96 inline void SetCidrIpv4(const Aws::String& value) { m_cidrIpv4HasBeenSet = true; m_cidrIpv4 = value; }
97 inline void SetCidrIpv4(Aws::String&& value) { m_cidrIpv4HasBeenSet = true; m_cidrIpv4 = std::move(value); }
98 inline void SetCidrIpv4(const char* value) { m_cidrIpv4HasBeenSet = true; m_cidrIpv4.assign(value); }
99 inline SecurityGroupRuleRequest& WithCidrIpv4(const Aws::String& value) { SetCidrIpv4(value); return *this;}
100 inline SecurityGroupRuleRequest& WithCidrIpv4(Aws::String&& value) { SetCidrIpv4(std::move(value)); return *this;}
101 inline SecurityGroupRuleRequest& WithCidrIpv4(const char* value) { SetCidrIpv4(value); return *this;}
103
105
109 inline const Aws::String& GetCidrIpv6() const{ return m_cidrIpv6; }
110 inline bool CidrIpv6HasBeenSet() const { return m_cidrIpv6HasBeenSet; }
111 inline void SetCidrIpv6(const Aws::String& value) { m_cidrIpv6HasBeenSet = true; m_cidrIpv6 = value; }
112 inline void SetCidrIpv6(Aws::String&& value) { m_cidrIpv6HasBeenSet = true; m_cidrIpv6 = std::move(value); }
113 inline void SetCidrIpv6(const char* value) { m_cidrIpv6HasBeenSet = true; m_cidrIpv6.assign(value); }
114 inline SecurityGroupRuleRequest& WithCidrIpv6(const Aws::String& value) { SetCidrIpv6(value); return *this;}
115 inline SecurityGroupRuleRequest& WithCidrIpv6(Aws::String&& value) { SetCidrIpv6(std::move(value)); return *this;}
116 inline SecurityGroupRuleRequest& WithCidrIpv6(const char* value) { SetCidrIpv6(value); return *this;}
118
120
123 inline const Aws::String& GetPrefixListId() const{ return m_prefixListId; }
124 inline bool PrefixListIdHasBeenSet() const { return m_prefixListIdHasBeenSet; }
125 inline void SetPrefixListId(const Aws::String& value) { m_prefixListIdHasBeenSet = true; m_prefixListId = value; }
126 inline void SetPrefixListId(Aws::String&& value) { m_prefixListIdHasBeenSet = true; m_prefixListId = std::move(value); }
127 inline void SetPrefixListId(const char* value) { m_prefixListIdHasBeenSet = true; m_prefixListId.assign(value); }
128 inline SecurityGroupRuleRequest& WithPrefixListId(const Aws::String& value) { SetPrefixListId(value); return *this;}
129 inline SecurityGroupRuleRequest& WithPrefixListId(Aws::String&& value) { SetPrefixListId(std::move(value)); return *this;}
130 inline SecurityGroupRuleRequest& WithPrefixListId(const char* value) { SetPrefixListId(value); return *this;}
132
134
138 inline const Aws::String& GetReferencedGroupId() const{ return m_referencedGroupId; }
139 inline bool ReferencedGroupIdHasBeenSet() const { return m_referencedGroupIdHasBeenSet; }
140 inline void SetReferencedGroupId(const Aws::String& value) { m_referencedGroupIdHasBeenSet = true; m_referencedGroupId = value; }
141 inline void SetReferencedGroupId(Aws::String&& value) { m_referencedGroupIdHasBeenSet = true; m_referencedGroupId = std::move(value); }
142 inline void SetReferencedGroupId(const char* value) { m_referencedGroupIdHasBeenSet = true; m_referencedGroupId.assign(value); }
144 inline SecurityGroupRuleRequest& WithReferencedGroupId(Aws::String&& value) { SetReferencedGroupId(std::move(value)); return *this;}
145 inline SecurityGroupRuleRequest& WithReferencedGroupId(const char* value) { SetReferencedGroupId(value); return *this;}
147
149
152 inline const Aws::String& GetDescription() const{ return m_description; }
153 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
154 inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; }
155 inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); }
156 inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); }
157 inline SecurityGroupRuleRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;}
158 inline SecurityGroupRuleRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;}
159 inline SecurityGroupRuleRequest& WithDescription(const char* value) { SetDescription(value); return *this;}
161 private:
162
163 Aws::String m_ipProtocol;
164 bool m_ipProtocolHasBeenSet = false;
165
166 int m_fromPort;
167 bool m_fromPortHasBeenSet = false;
168
169 int m_toPort;
170 bool m_toPortHasBeenSet = false;
171
172 Aws::String m_cidrIpv4;
173 bool m_cidrIpv4HasBeenSet = false;
174
175 Aws::String m_cidrIpv6;
176 bool m_cidrIpv6HasBeenSet = false;
177
178 Aws::String m_prefixListId;
179 bool m_prefixListIdHasBeenSet = false;
180
181 Aws::String m_referencedGroupId;
182 bool m_referencedGroupIdHasBeenSet = false;
183
184 Aws::String m_description;
185 bool m_descriptionHasBeenSet = false;
186 };
187
188} // namespace Model
189} // namespace EC2
190} // namespace Aws
void SetReferencedGroupId(const Aws::String &value)
SecurityGroupRuleRequest & WithIpProtocol(const Aws::String &value)
SecurityGroupRuleRequest & WithPrefixListId(const char *value)
AWS_EC2_API SecurityGroupRuleRequest(const Aws::Utils::Xml::XmlNode &xmlNode)
SecurityGroupRuleRequest & WithReferencedGroupId(Aws::String &&value)
SecurityGroupRuleRequest & WithCidrIpv6(Aws::String &&value)
SecurityGroupRuleRequest & WithFromPort(int value)
SecurityGroupRuleRequest & WithReferencedGroupId(const char *value)
SecurityGroupRuleRequest & WithReferencedGroupId(const Aws::String &value)
SecurityGroupRuleRequest & WithDescription(const Aws::String &value)
SecurityGroupRuleRequest & WithCidrIpv6(const Aws::String &value)
SecurityGroupRuleRequest & WithDescription(const char *value)
AWS_EC2_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
SecurityGroupRuleRequest & WithToPort(int value)
SecurityGroupRuleRequest & WithPrefixListId(const Aws::String &value)
SecurityGroupRuleRequest & WithIpProtocol(Aws::String &&value)
SecurityGroupRuleRequest & WithPrefixListId(Aws::String &&value)
AWS_EC2_API SecurityGroupRuleRequest & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
SecurityGroupRuleRequest & WithCidrIpv4(Aws::String &&value)
SecurityGroupRuleRequest & WithCidrIpv4(const Aws::String &value)
SecurityGroupRuleRequest & WithCidrIpv4(const char *value)
AWS_EC2_API void OutputToStream(Aws::OStream &oStream, const char *location) const
SecurityGroupRuleRequest & WithDescription(Aws::String &&value)
SecurityGroupRuleRequest & WithCidrIpv6(const char *value)
SecurityGroupRuleRequest & WithIpProtocol(const char *value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::basic_ostream< char, std::char_traits< char > > OStream