AWS SDK for C++

AWS SDK for C++ Version 1.11.749

Loading...
Searching...
No Matches
MetricStat.h
1
6#pragma once
7#include <aws/autoscaling/AutoScaling_EXPORTS.h>
8#include <aws/autoscaling/model/Metric.h>
9#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Xml {
17class XmlNode;
18} // namespace Xml
19} // namespace Utils
20namespace AutoScaling {
21namespace Model {
22
34 public:
35 AWS_AUTOSCALING_API MetricStat() = default;
36 AWS_AUTOSCALING_API MetricStat(const Aws::Utils::Xml::XmlNode& xmlNode);
37 AWS_AUTOSCALING_API MetricStat& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
38
39 AWS_AUTOSCALING_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
40 AWS_AUTOSCALING_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
41
43
51 inline const Metric& GetMetric() const { return m_metric; }
52 inline bool MetricHasBeenSet() const { return m_metricHasBeenSet; }
53 template <typename MetricT = Metric>
54 void SetMetric(MetricT&& value) {
55 m_metricHasBeenSet = true;
56 m_metric = std::forward<MetricT>(value);
57 }
58 template <typename MetricT = Metric>
59 MetricStat& WithMetric(MetricT&& value) {
60 SetMetric(std::forward<MetricT>(value));
61 return *this;
62 }
64
66
74 inline const Aws::String& GetStat() const { return m_stat; }
75 inline bool StatHasBeenSet() const { return m_statHasBeenSet; }
76 template <typename StatT = Aws::String>
77 void SetStat(StatT&& value) {
78 m_statHasBeenSet = true;
79 m_stat = std::forward<StatT>(value);
80 }
81 template <typename StatT = Aws::String>
82 MetricStat& WithStat(StatT&& value) {
83 SetStat(std::forward<StatT>(value));
84 return *this;
85 }
87
89
95 inline const Aws::String& GetUnit() const { return m_unit; }
96 inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; }
97 template <typename UnitT = Aws::String>
98 void SetUnit(UnitT&& value) {
99 m_unitHasBeenSet = true;
100 m_unit = std::forward<UnitT>(value);
101 }
102 template <typename UnitT = Aws::String>
103 MetricStat& WithUnit(UnitT&& value) {
104 SetUnit(std::forward<UnitT>(value));
105 return *this;
106 }
108 private:
109 Metric m_metric;
110
111 Aws::String m_stat;
112
113 Aws::String m_unit;
114 bool m_metricHasBeenSet = false;
115 bool m_statHasBeenSet = false;
116 bool m_unitHasBeenSet = false;
117};
118
119} // namespace Model
120} // namespace AutoScaling
121} // namespace Aws
AWS_AUTOSCALING_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
AWS_AUTOSCALING_API MetricStat & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
const Aws::String & GetStat() const
Definition MetricStat.h:74
AWS_AUTOSCALING_API void OutputToStream(Aws::OStream &oStream, const char *location) const
MetricStat & WithUnit(UnitT &&value)
Definition MetricStat.h:103
MetricStat & WithStat(StatT &&value)
Definition MetricStat.h:82
const Metric & GetMetric() const
Definition MetricStat.h:51
AWS_AUTOSCALING_API MetricStat()=default
const Aws::String & GetUnit() const
Definition MetricStat.h:95
AWS_AUTOSCALING_API MetricStat(const Aws::Utils::Xml::XmlNode &xmlNode)
MetricStat & WithMetric(MetricT &&value)
Definition MetricStat.h:59
void SetMetric(MetricT &&value)
Definition MetricStat.h:54
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::basic_ostream< char, std::char_traits< char > > OStream