AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
IpPermission.h
1
6#pragma once
7#include <aws/gamelift/GameLift_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/gamelift/model/IpProtocol.h>
10#include <utility>
11
12namespace Aws
13{
14namespace Utils
15{
16namespace Json
17{
18 class JsonValue;
19 class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace GameLift
23{
24namespace Model
25{
26
38 {
39 public:
40 AWS_GAMELIFT_API IpPermission() = default;
41 AWS_GAMELIFT_API IpPermission(Aws::Utils::Json::JsonView jsonValue);
43 AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const;
44
45
47
53 inline int GetFromPort() const { return m_fromPort; }
54 inline bool FromPortHasBeenSet() const { return m_fromPortHasBeenSet; }
55 inline void SetFromPort(int value) { m_fromPortHasBeenSet = true; m_fromPort = value; }
56 inline IpPermission& WithFromPort(int value) { SetFromPort(value); return *this;}
58
60
67 inline int GetToPort() const { return m_toPort; }
68 inline bool ToPortHasBeenSet() const { return m_toPortHasBeenSet; }
69 inline void SetToPort(int value) { m_toPortHasBeenSet = true; m_toPort = value; }
70 inline IpPermission& WithToPort(int value) { SetToPort(value); return *this;}
72
74
79 inline const Aws::String& GetIpRange() const { return m_ipRange; }
80 inline bool IpRangeHasBeenSet() const { return m_ipRangeHasBeenSet; }
81 template<typename IpRangeT = Aws::String>
82 void SetIpRange(IpRangeT&& value) { m_ipRangeHasBeenSet = true; m_ipRange = std::forward<IpRangeT>(value); }
83 template<typename IpRangeT = Aws::String>
84 IpPermission& WithIpRange(IpRangeT&& value) { SetIpRange(std::forward<IpRangeT>(value)); return *this;}
86
88
91 inline IpProtocol GetProtocol() const { return m_protocol; }
92 inline bool ProtocolHasBeenSet() const { return m_protocolHasBeenSet; }
93 inline void SetProtocol(IpProtocol value) { m_protocolHasBeenSet = true; m_protocol = value; }
94 inline IpPermission& WithProtocol(IpProtocol value) { SetProtocol(value); return *this;}
96 private:
97
98 int m_fromPort{0};
99 bool m_fromPortHasBeenSet = false;
100
101 int m_toPort{0};
102 bool m_toPortHasBeenSet = false;
103
104 Aws::String m_ipRange;
105 bool m_ipRangeHasBeenSet = false;
106
108 bool m_protocolHasBeenSet = false;
109 };
110
111} // namespace Model
112} // namespace GameLift
113} // namespace Aws
AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const
IpPermission & WithIpRange(IpRangeT &&value)
AWS_GAMELIFT_API IpPermission(Aws::Utils::Json::JsonView jsonValue)
AWS_GAMELIFT_API IpPermission & operator=(Aws::Utils::Json::JsonView jsonValue)
IpPermission & WithProtocol(IpProtocol value)
const Aws::String & GetIpRange() const
IpPermission & WithToPort(int value)
void SetProtocol(IpProtocol value)
void SetIpRange(IpRangeT &&value)
AWS_GAMELIFT_API IpPermission()=default
IpPermission & WithFromPort(int value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue