AWS SDK for C++

AWS SDK for C++ Version 1.11.759

Loading...
Searching...
No Matches
CustomizedScalingMetricSpecification.h
1
6#pragma once
7#include <aws/autoscaling-plans/AutoScalingPlans_EXPORTS.h>
8#include <aws/autoscaling-plans/model/MetricDimension.h>
9#include <aws/autoscaling-plans/model/MetricStatistic.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace AutoScalingPlans {
23namespace Model {
24
46 public:
47 AWS_AUTOSCALINGPLANS_API CustomizedScalingMetricSpecification() = default;
50 AWS_AUTOSCALINGPLANS_API Aws::Utils::Json::JsonValue Jsonize() const;
51
53
56 inline const Aws::String& GetMetricName() const { return m_metricName; }
57 inline bool MetricNameHasBeenSet() const { return m_metricNameHasBeenSet; }
58 template <typename MetricNameT = Aws::String>
59 void SetMetricName(MetricNameT&& value) {
60 m_metricNameHasBeenSet = true;
61 m_metricName = std::forward<MetricNameT>(value);
62 }
63 template <typename MetricNameT = Aws::String>
65 SetMetricName(std::forward<MetricNameT>(value));
66 return *this;
67 }
69
71
74 inline const Aws::String& GetNamespace() const { return m_namespace; }
75 inline bool NamespaceHasBeenSet() const { return m_namespaceHasBeenSet; }
76 template <typename NamespaceT = Aws::String>
77 void SetNamespace(NamespaceT&& value) {
78 m_namespaceHasBeenSet = true;
79 m_namespace = std::forward<NamespaceT>(value);
80 }
81 template <typename NamespaceT = Aws::String>
83 SetNamespace(std::forward<NamespaceT>(value));
84 return *this;
85 }
87
89
94 inline const Aws::Vector<MetricDimension>& GetDimensions() const { return m_dimensions; }
95 inline bool DimensionsHasBeenSet() const { return m_dimensionsHasBeenSet; }
96 template <typename DimensionsT = Aws::Vector<MetricDimension>>
97 void SetDimensions(DimensionsT&& value) {
98 m_dimensionsHasBeenSet = true;
99 m_dimensions = std::forward<DimensionsT>(value);
100 }
101 template <typename DimensionsT = Aws::Vector<MetricDimension>>
103 SetDimensions(std::forward<DimensionsT>(value));
104 return *this;
105 }
106 template <typename DimensionsT = MetricDimension>
108 m_dimensionsHasBeenSet = true;
109 m_dimensions.emplace_back(std::forward<DimensionsT>(value));
110 return *this;
111 }
113
115
118 inline MetricStatistic GetStatistic() const { return m_statistic; }
119 inline bool StatisticHasBeenSet() const { return m_statisticHasBeenSet; }
120 inline void SetStatistic(MetricStatistic value) {
121 m_statisticHasBeenSet = true;
122 m_statistic = value;
123 }
125 SetStatistic(value);
126 return *this;
127 }
129
131
134 inline const Aws::String& GetUnit() const { return m_unit; }
135 inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; }
136 template <typename UnitT = Aws::String>
137 void SetUnit(UnitT&& value) {
138 m_unitHasBeenSet = true;
139 m_unit = std::forward<UnitT>(value);
140 }
141 template <typename UnitT = Aws::String>
143 SetUnit(std::forward<UnitT>(value));
144 return *this;
145 }
147 private:
148 Aws::String m_metricName;
149
150 Aws::String m_namespace;
151
152 Aws::Vector<MetricDimension> m_dimensions;
153
155
156 Aws::String m_unit;
157 bool m_metricNameHasBeenSet = false;
158 bool m_namespaceHasBeenSet = false;
159 bool m_dimensionsHasBeenSet = false;
160 bool m_statisticHasBeenSet = false;
161 bool m_unitHasBeenSet = false;
162};
163
164} // namespace Model
165} // namespace AutoScalingPlans
166} // namespace Aws
AWS_AUTOSCALINGPLANS_API CustomizedScalingMetricSpecification & operator=(Aws::Utils::Json::JsonView jsonValue)
CustomizedScalingMetricSpecification & WithDimensions(DimensionsT &&value)
CustomizedScalingMetricSpecification & WithNamespace(NamespaceT &&value)
AWS_AUTOSCALINGPLANS_API CustomizedScalingMetricSpecification()=default
AWS_AUTOSCALINGPLANS_API CustomizedScalingMetricSpecification(Aws::Utils::Json::JsonView jsonValue)
AWS_AUTOSCALINGPLANS_API Aws::Utils::Json::JsonValue Jsonize() const
CustomizedScalingMetricSpecification & WithMetricName(MetricNameT &&value)
CustomizedScalingMetricSpecification & AddDimensions(DimensionsT &&value)
CustomizedScalingMetricSpecification & WithStatistic(MetricStatistic value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue