AWS SDK for C++

AWS SDK for C++ Version 1.11.932

Loading...
Searching...
No Matches
VisibilityConfig.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/wafv2/WAFV2_EXPORTS.h>
9
10#include <utility>
11
12namespace Aws {
13namespace Utils {
14namespace Json {
15class JsonValue;
16class JsonView;
17} // namespace Json
18} // namespace Utils
19namespace WAFV2 {
20namespace Model {
21
29 public:
30 AWS_WAFV2_API VisibilityConfig() = default;
33 AWS_WAFV2_API Aws::Utils::Json::JsonValue Jsonize() const;
34
36
46 inline bool GetSampledRequestsEnabled() const { return m_sampledRequestsEnabled; }
47 inline bool SampledRequestsEnabledHasBeenSet() const { return m_sampledRequestsEnabledHasBeenSet; }
48 inline void SetSampledRequestsEnabled(bool value) {
49 m_sampledRequestsEnabledHasBeenSet = true;
50 m_sampledRequestsEnabled = value;
51 }
54 return *this;
55 }
57
59
70 inline bool GetCloudWatchMetricsEnabled() const { return m_cloudWatchMetricsEnabled; }
71 inline bool CloudWatchMetricsEnabledHasBeenSet() const { return m_cloudWatchMetricsEnabledHasBeenSet; }
72 inline void SetCloudWatchMetricsEnabled(bool value) {
73 m_cloudWatchMetricsEnabledHasBeenSet = true;
74 m_cloudWatchMetricsEnabled = value;
75 }
78 return *this;
79 }
81
83
90 inline const Aws::String& GetMetricName() const { return m_metricName; }
91 inline bool MetricNameHasBeenSet() const { return m_metricNameHasBeenSet; }
92 template <typename MetricNameT = Aws::String>
93 void SetMetricName(MetricNameT&& value) {
94 m_metricNameHasBeenSet = true;
95 m_metricName = std::forward<MetricNameT>(value);
96 }
97 template <typename MetricNameT = Aws::String>
98 VisibilityConfig& WithMetricName(MetricNameT&& value) {
99 SetMetricName(std::forward<MetricNameT>(value));
100 return *this;
101 }
103 private:
104 bool m_sampledRequestsEnabled{false};
105
106 bool m_cloudWatchMetricsEnabled{false};
107
108 Aws::String m_metricName;
109 bool m_sampledRequestsEnabledHasBeenSet = false;
110 bool m_cloudWatchMetricsEnabledHasBeenSet = false;
111 bool m_metricNameHasBeenSet = false;
112};
113
114} // namespace Model
115} // namespace WAFV2
116} // namespace Aws
VisibilityConfig & WithMetricName(MetricNameT &&value)
void SetMetricName(MetricNameT &&value)
AWS_WAFV2_API VisibilityConfig & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetMetricName() const
AWS_WAFV2_API VisibilityConfig(Aws::Utils::Json::JsonView jsonValue)
AWS_WAFV2_API Aws::Utils::Json::JsonValue Jsonize() const
VisibilityConfig & WithSampledRequestsEnabled(bool value)
AWS_WAFV2_API VisibilityConfig()=default
VisibilityConfig & WithCloudWatchMetricsEnabled(bool value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue