AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
StatefulRule.h
1
6#pragma once
7#include <aws/network-firewall/NetworkFirewall_EXPORTS.h>
8#include <aws/network-firewall/model/StatefulAction.h>
9#include <aws/network-firewall/model/Header.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/network-firewall/model/RuleOption.h>
12#include <utility>
13
14namespace Aws
15{
16namespace Utils
17{
18namespace Json
19{
20 class JsonValue;
21 class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace NetworkFirewall
25{
26namespace Model
27{
28
40 {
41 public:
42 AWS_NETWORKFIREWALL_API StatefulRule() = default;
43 AWS_NETWORKFIREWALL_API StatefulRule(Aws::Utils::Json::JsonView jsonValue);
44 AWS_NETWORKFIREWALL_API StatefulRule& operator=(Aws::Utils::Json::JsonView jsonValue);
45 AWS_NETWORKFIREWALL_API Aws::Utils::Json::JsonValue Jsonize() const;
46
47
49
69 inline StatefulAction GetAction() const { return m_action; }
70 inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; }
71 inline void SetAction(StatefulAction value) { m_actionHasBeenSet = true; m_action = value; }
72 inline StatefulRule& WithAction(StatefulAction value) { SetAction(value); return *this;}
74
76
80 inline const Header& GetHeader() const { return m_header; }
81 inline bool HeaderHasBeenSet() const { return m_headerHasBeenSet; }
82 template<typename HeaderT = Header>
83 void SetHeader(HeaderT&& value) { m_headerHasBeenSet = true; m_header = std::forward<HeaderT>(value); }
84 template<typename HeaderT = Header>
85 StatefulRule& WithHeader(HeaderT&& value) { SetHeader(std::forward<HeaderT>(value)); return *this;}
87
89
93 inline const Aws::Vector<RuleOption>& GetRuleOptions() const { return m_ruleOptions; }
94 inline bool RuleOptionsHasBeenSet() const { return m_ruleOptionsHasBeenSet; }
95 template<typename RuleOptionsT = Aws::Vector<RuleOption>>
96 void SetRuleOptions(RuleOptionsT&& value) { m_ruleOptionsHasBeenSet = true; m_ruleOptions = std::forward<RuleOptionsT>(value); }
97 template<typename RuleOptionsT = Aws::Vector<RuleOption>>
98 StatefulRule& WithRuleOptions(RuleOptionsT&& value) { SetRuleOptions(std::forward<RuleOptionsT>(value)); return *this;}
99 template<typename RuleOptionsT = RuleOption>
100 StatefulRule& AddRuleOptions(RuleOptionsT&& value) { m_ruleOptionsHasBeenSet = true; m_ruleOptions.emplace_back(std::forward<RuleOptionsT>(value)); return *this; }
102 private:
103
105 bool m_actionHasBeenSet = false;
106
107 Header m_header;
108 bool m_headerHasBeenSet = false;
109
110 Aws::Vector<RuleOption> m_ruleOptions;
111 bool m_ruleOptionsHasBeenSet = false;
112 };
113
114} // namespace Model
115} // namespace NetworkFirewall
116} // namespace Aws
AWS_NETWORKFIREWALL_API StatefulRule()=default
AWS_NETWORKFIREWALL_API StatefulRule(Aws::Utils::Json::JsonView jsonValue)
AWS_NETWORKFIREWALL_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::Vector< RuleOption > & GetRuleOptions() const
void SetRuleOptions(RuleOptionsT &&value)
void SetAction(StatefulAction value)
StatefulRule & WithHeader(HeaderT &&value)
StatefulRule & WithRuleOptions(RuleOptionsT &&value)
StatefulRule & WithAction(StatefulAction value)
AWS_NETWORKFIREWALL_API StatefulRule & operator=(Aws::Utils::Json::JsonView jsonValue)
StatefulRule & AddRuleOptions(RuleOptionsT &&value)
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue