AWS SDK for C++  1.9.151
AWS SDK for C++
MetricStat.h
Go to the documentation of this file.
1 
6 #pragma once
12 #include <utility>
13 
14 namespace Aws
15 {
16 namespace Utils
17 {
18 namespace Xml
19 {
20  class XmlNode;
21 } // namespace Xml
22 } // namespace Utils
23 namespace CloudWatch
24 {
25 namespace Model
26 {
27 
35  {
36  public:
40 
41  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
42  void OutputToStream(Aws::OStream& oStream, const char* location) const;
43 
44 
49  inline const Metric& GetMetric() const{ return m_metric; }
50 
55  inline bool MetricHasBeenSet() const { return m_metricHasBeenSet; }
56 
61  inline void SetMetric(const Metric& value) { m_metricHasBeenSet = true; m_metric = value; }
62 
67  inline void SetMetric(Metric&& value) { m_metricHasBeenSet = true; m_metric = std::move(value); }
68 
73  inline MetricStat& WithMetric(const Metric& value) { SetMetric(value); return *this;}
74 
79  inline MetricStat& WithMetric(Metric&& value) { SetMetric(std::move(value)); return *this;}
80 
81 
97  inline int GetPeriod() const{ return m_period; }
98 
114  inline bool PeriodHasBeenSet() const { return m_periodHasBeenSet; }
115 
131  inline void SetPeriod(int value) { m_periodHasBeenSet = true; m_period = value; }
132 
148  inline MetricStat& WithPeriod(int value) { SetPeriod(value); return *this;}
149 
150 
155  inline const Aws::String& GetStat() const{ return m_stat; }
156 
161  inline bool StatHasBeenSet() const { return m_statHasBeenSet; }
162 
167  inline void SetStat(const Aws::String& value) { m_statHasBeenSet = true; m_stat = value; }
168 
173  inline void SetStat(Aws::String&& value) { m_statHasBeenSet = true; m_stat = std::move(value); }
174 
179  inline void SetStat(const char* value) { m_statHasBeenSet = true; m_stat.assign(value); }
180 
185  inline MetricStat& WithStat(const Aws::String& value) { SetStat(value); return *this;}
186 
191  inline MetricStat& WithStat(Aws::String&& value) { SetStat(std::move(value)); return *this;}
192 
197  inline MetricStat& WithStat(const char* value) { SetStat(value); return *this;}
198 
199 
210  inline const StandardUnit& GetUnit() const{ return m_unit; }
211 
222  inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; }
223 
234  inline void SetUnit(const StandardUnit& value) { m_unitHasBeenSet = true; m_unit = value; }
235 
246  inline void SetUnit(StandardUnit&& value) { m_unitHasBeenSet = true; m_unit = std::move(value); }
247 
258  inline MetricStat& WithUnit(const StandardUnit& value) { SetUnit(value); return *this;}
259 
270  inline MetricStat& WithUnit(StandardUnit&& value) { SetUnit(std::move(value)); return *this;}
271 
272  private:
273 
274  Metric m_metric;
275  bool m_metricHasBeenSet;
276 
277  int m_period;
278  bool m_periodHasBeenSet;
279 
280  Aws::String m_stat;
281  bool m_statHasBeenSet;
282 
283  StandardUnit m_unit;
284  bool m_unitHasBeenSet;
285  };
286 
287 } // namespace Model
288 } // namespace CloudWatch
289 } // namespace Aws
Aws::CloudWatch::Model::MetricStat::SetStat
void SetStat(const Aws::String &value)
Definition: MetricStat.h:167
Aws::CloudWatch::Model::MetricStat::WithMetric
MetricStat & WithMetric(Metric &&value)
Definition: MetricStat.h:79
Aws::CloudWatch::Model::StandardUnit
StandardUnit
Definition: StandardUnit.h:17
Aws::CloudWatch::Model::MetricStat::WithUnit
MetricStat & WithUnit(const StandardUnit &value)
Definition: MetricStat.h:258
Aws::CloudWatch::Model::MetricStat::OutputToStream
void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
AWS_CLOUDWATCH_API
#define AWS_CLOUDWATCH_API
Definition: CloudWatch_EXPORTS.h:28
Aws::CloudWatch::Model::MetricStat::WithStat
MetricStat & WithStat(const char *value)
Definition: MetricStat.h:197
Metric.h
Aws::CloudWatch::Model::MetricStat::GetStat
const Aws::String & GetStat() const
Definition: MetricStat.h:155
Aws::CloudWatch::Model::Metric
Definition: Metric.h:34
Aws::CloudWatch::Model::MetricStat::WithMetric
MetricStat & WithMetric(const Metric &value)
Definition: MetricStat.h:73
AWSStreamFwd.h
Aws::CloudWatch::Model::MetricStat::StatHasBeenSet
bool StatHasBeenSet() const
Definition: MetricStat.h:161
Aws::CloudWatch::Model::MetricStat::operator=
MetricStat & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
Aws::CloudWatch::Model::MetricStat::SetStat
void SetStat(const char *value)
Definition: MetricStat.h:179
Aws::CloudWatch::Model::MetricStat
Definition: MetricStat.h:35
Aws::CloudWatch::Model::MetricStat::WithStat
MetricStat & WithStat(const Aws::String &value)
Definition: MetricStat.h:185
Aws::OStream
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:21
Aws::CloudWatch::Model::MetricStat::SetUnit
void SetUnit(const StandardUnit &value)
Definition: MetricStat.h:234
Aws::CloudWatch::Model::MetricStat::WithUnit
MetricStat & WithUnit(StandardUnit &&value)
Definition: MetricStat.h:270
Aws::CloudWatch::Model::MetricStat::PeriodHasBeenSet
bool PeriodHasBeenSet() const
Definition: MetricStat.h:114
Aws::CloudWatch::Model::MetricStat::SetMetric
void SetMetric(Metric &&value)
Definition: MetricStat.h:67
Aws::CloudWatch::Model::MetricStat::SetUnit
void SetUnit(StandardUnit &&value)
Definition: MetricStat.h:246
Aws::CloudWatch::Model::MetricStat::GetMetric
const Metric & GetMetric() const
Definition: MetricStat.h:49
StandardUnit.h
Aws::Utils::Xml::XmlNode
Definition: XmlSerializer.h:53
Aws::CloudWatch::Model::MetricStat::GetUnit
const StandardUnit & GetUnit() const
Definition: MetricStat.h:210
Aws::CloudWatch::Model::MetricStat::MetricHasBeenSet
bool MetricHasBeenSet() const
Definition: MetricStat.h:55
Aws::CloudWatch::Model::MetricStat::OutputToStream
void OutputToStream(Aws::OStream &oStream, const char *location) const
Aws::CloudWatch::Model::MetricStat::WithPeriod
MetricStat & WithPeriod(int value)
Definition: MetricStat.h:148
AWSString.h
Aws::CloudWatch::Model::MetricStat::MetricStat
MetricStat()
Aws::CloudWatch::Model::MetricStat::MetricStat
MetricStat(const Aws::Utils::Xml::XmlNode &xmlNode)
Aws::CloudWatch::Model::MetricStat::GetPeriod
int GetPeriod() const
Definition: MetricStat.h:97
CloudWatch_EXPORTS.h
Aws::CloudWatch::Model::MetricStat::UnitHasBeenSet
bool UnitHasBeenSet() const
Definition: MetricStat.h:222
Aws::CloudWatch::Model::MetricStat::WithStat
MetricStat & WithStat(Aws::String &&value)
Definition: MetricStat.h:191
Aws
Definition: AccessManagementClient.h:15
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
index
int index
Definition: cJSON.h:181
Aws::CloudWatch::Model::MetricStat::SetMetric
void SetMetric(const Metric &value)
Definition: MetricStat.h:61
Aws::CloudWatch::Model::MetricStat::SetPeriod
void SetPeriod(int value)
Definition: MetricStat.h:131
Aws::CloudWatch::Model::MetricStat::SetStat
void SetStat(Aws::String &&value)
Definition: MetricStat.h:173