AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
PortRange.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
8#include <aws/ec2/EC2_EXPORTS.h>
9
10namespace Aws {
11namespace Utils {
12namespace Xml {
13class XmlNode;
14} // namespace Xml
15} // namespace Utils
16namespace EC2 {
17namespace Model {
18
24class PortRange {
25 public:
26 AWS_EC2_API PortRange() = default;
27 AWS_EC2_API PortRange(const Aws::Utils::Xml::XmlNode& xmlNode);
28 AWS_EC2_API PortRange& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
29
30 AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
31 AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
32
34
37 inline int GetFrom() const { return m_from; }
38 inline bool FromHasBeenSet() const { return m_fromHasBeenSet; }
39 inline void SetFrom(int value) {
40 m_fromHasBeenSet = true;
41 m_from = value;
42 }
43 inline PortRange& WithFrom(int value) {
44 SetFrom(value);
45 return *this;
46 }
48
50
53 inline int GetTo() const { return m_to; }
54 inline bool ToHasBeenSet() const { return m_toHasBeenSet; }
55 inline void SetTo(int value) {
56 m_toHasBeenSet = true;
57 m_to = value;
58 }
59 inline PortRange& WithTo(int value) {
60 SetTo(value);
61 return *this;
62 }
64 private:
65 int m_from{0};
66
67 int m_to{0};
68 bool m_fromHasBeenSet = false;
69 bool m_toHasBeenSet = false;
70};
71
72} // namespace Model
73} // namespace EC2
74} // namespace Aws
AWS_EC2_API void OutputToStream(Aws::OStream &oStream, const char *location) const
void SetFrom(int value)
Definition PortRange.h:39
bool ToHasBeenSet() const
Definition PortRange.h:54
AWS_EC2_API PortRange & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
AWS_EC2_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
bool FromHasBeenSet() const
Definition PortRange.h:38
PortRange & WithTo(int value)
Definition PortRange.h:59
AWS_EC2_API PortRange(const Aws::Utils::Xml::XmlNode &xmlNode)
AWS_EC2_API PortRange()=default
void SetTo(int value)
Definition PortRange.h:55
PortRange & WithFrom(int value)
Definition PortRange.h:43
std::basic_ostream< char, std::char_traits< char > > OStream