AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
MetricDatum.h
1
6#pragma once
7#include <aws/monitoring/CloudWatch_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/core/utils/DateTime.h>
12#include <aws/monitoring/model/StatisticSet.h>
13#include <aws/monitoring/model/StandardUnit.h>
14#include <aws/monitoring/model/Dimension.h>
15#include <utility>
16
17namespace Aws
18{
19namespace Utils
20{
21namespace Xml
22{
23 class XmlNode;
24} // namespace Xml
25} // namespace Utils
26namespace CloudWatch
27{
28namespace Model
29{
30
38 {
39 public:
40 AWS_CLOUDWATCH_API MetricDatum();
41 AWS_CLOUDWATCH_API MetricDatum(const Aws::Utils::Xml::XmlNode& xmlNode);
42 AWS_CLOUDWATCH_API MetricDatum& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
43
44 AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
45 AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
46
47
49
52 inline const Aws::String& GetMetricName() const{ return m_metricName; }
53 inline bool MetricNameHasBeenSet() const { return m_metricNameHasBeenSet; }
54 inline void SetMetricName(const Aws::String& value) { m_metricNameHasBeenSet = true; m_metricName = value; }
55 inline void SetMetricName(Aws::String&& value) { m_metricNameHasBeenSet = true; m_metricName = std::move(value); }
56 inline void SetMetricName(const char* value) { m_metricNameHasBeenSet = true; m_metricName.assign(value); }
57 inline MetricDatum& WithMetricName(const Aws::String& value) { SetMetricName(value); return *this;}
58 inline MetricDatum& WithMetricName(Aws::String&& value) { SetMetricName(std::move(value)); return *this;}
59 inline MetricDatum& WithMetricName(const char* value) { SetMetricName(value); return *this;}
61
63
66 inline const Aws::Vector<Dimension>& GetDimensions() const{ return m_dimensions; }
67 inline bool DimensionsHasBeenSet() const { return m_dimensionsHasBeenSet; }
68 inline void SetDimensions(const Aws::Vector<Dimension>& value) { m_dimensionsHasBeenSet = true; m_dimensions = value; }
69 inline void SetDimensions(Aws::Vector<Dimension>&& value) { m_dimensionsHasBeenSet = true; m_dimensions = std::move(value); }
70 inline MetricDatum& WithDimensions(const Aws::Vector<Dimension>& value) { SetDimensions(value); return *this;}
71 inline MetricDatum& WithDimensions(Aws::Vector<Dimension>&& value) { SetDimensions(std::move(value)); return *this;}
72 inline MetricDatum& AddDimensions(const Dimension& value) { m_dimensionsHasBeenSet = true; m_dimensions.push_back(value); return *this; }
73 inline MetricDatum& AddDimensions(Dimension&& value) { m_dimensionsHasBeenSet = true; m_dimensions.push_back(std::move(value)); return *this; }
75
77
81 inline const Aws::Utils::DateTime& GetTimestamp() const{ return m_timestamp; }
82 inline bool TimestampHasBeenSet() const { return m_timestampHasBeenSet; }
83 inline void SetTimestamp(const Aws::Utils::DateTime& value) { m_timestampHasBeenSet = true; m_timestamp = value; }
84 inline void SetTimestamp(Aws::Utils::DateTime&& value) { m_timestampHasBeenSet = true; m_timestamp = std::move(value); }
85 inline MetricDatum& WithTimestamp(const Aws::Utils::DateTime& value) { SetTimestamp(value); return *this;}
86 inline MetricDatum& WithTimestamp(Aws::Utils::DateTime&& value) { SetTimestamp(std::move(value)); return *this;}
88
90
96 inline double GetValue() const{ return m_value; }
97 inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; }
98 inline void SetValue(double value) { m_valueHasBeenSet = true; m_value = value; }
99 inline MetricDatum& WithValue(double value) { SetValue(value); return *this;}
101
103
106 inline const StatisticSet& GetStatisticValues() const{ return m_statisticValues; }
107 inline bool StatisticValuesHasBeenSet() const { return m_statisticValuesHasBeenSet; }
108 inline void SetStatisticValues(const StatisticSet& value) { m_statisticValuesHasBeenSet = true; m_statisticValues = value; }
109 inline void SetStatisticValues(StatisticSet&& value) { m_statisticValuesHasBeenSet = true; m_statisticValues = std::move(value); }
110 inline MetricDatum& WithStatisticValues(const StatisticSet& value) { SetStatisticValues(value); return *this;}
111 inline MetricDatum& WithStatisticValues(StatisticSet&& value) { SetStatisticValues(std::move(value)); return *this;}
113
115
126 inline const Aws::Vector<double>& GetValues() const{ return m_values; }
127 inline bool ValuesHasBeenSet() const { return m_valuesHasBeenSet; }
128 inline void SetValues(const Aws::Vector<double>& value) { m_valuesHasBeenSet = true; m_values = value; }
129 inline void SetValues(Aws::Vector<double>&& value) { m_valuesHasBeenSet = true; m_values = std::move(value); }
130 inline MetricDatum& WithValues(const Aws::Vector<double>& value) { SetValues(value); return *this;}
131 inline MetricDatum& WithValues(Aws::Vector<double>&& value) { SetValues(std::move(value)); return *this;}
132 inline MetricDatum& AddValues(double value) { m_valuesHasBeenSet = true; m_values.push_back(value); return *this; }
134
136
144 inline const Aws::Vector<double>& GetCounts() const{ return m_counts; }
145 inline bool CountsHasBeenSet() const { return m_countsHasBeenSet; }
146 inline void SetCounts(const Aws::Vector<double>& value) { m_countsHasBeenSet = true; m_counts = value; }
147 inline void SetCounts(Aws::Vector<double>&& value) { m_countsHasBeenSet = true; m_counts = std::move(value); }
148 inline MetricDatum& WithCounts(const Aws::Vector<double>& value) { SetCounts(value); return *this;}
149 inline MetricDatum& WithCounts(Aws::Vector<double>&& value) { SetCounts(std::move(value)); return *this;}
150 inline MetricDatum& AddCounts(double value) { m_countsHasBeenSet = true; m_counts.push_back(value); return *this; }
152
154
159 inline const StandardUnit& GetUnit() const{ return m_unit; }
160 inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; }
161 inline void SetUnit(const StandardUnit& value) { m_unitHasBeenSet = true; m_unit = value; }
162 inline void SetUnit(StandardUnit&& value) { m_unitHasBeenSet = true; m_unit = std::move(value); }
163 inline MetricDatum& WithUnit(const StandardUnit& value) { SetUnit(value); return *this;}
164 inline MetricDatum& WithUnit(StandardUnit&& value) { SetUnit(std::move(value)); return *this;}
166
168
179 inline int GetStorageResolution() const{ return m_storageResolution; }
180 inline bool StorageResolutionHasBeenSet() const { return m_storageResolutionHasBeenSet; }
181 inline void SetStorageResolution(int value) { m_storageResolutionHasBeenSet = true; m_storageResolution = value; }
182 inline MetricDatum& WithStorageResolution(int value) { SetStorageResolution(value); return *this;}
184 private:
185
186 Aws::String m_metricName;
187 bool m_metricNameHasBeenSet = false;
188
189 Aws::Vector<Dimension> m_dimensions;
190 bool m_dimensionsHasBeenSet = false;
191
192 Aws::Utils::DateTime m_timestamp;
193 bool m_timestampHasBeenSet = false;
194
195 double m_value;
196 bool m_valueHasBeenSet = false;
197
198 StatisticSet m_statisticValues;
199 bool m_statisticValuesHasBeenSet = false;
200
201 Aws::Vector<double> m_values;
202 bool m_valuesHasBeenSet = false;
203
204 Aws::Vector<double> m_counts;
205 bool m_countsHasBeenSet = false;
206
207 StandardUnit m_unit;
208 bool m_unitHasBeenSet = false;
209
210 int m_storageResolution;
211 bool m_storageResolutionHasBeenSet = false;
212 };
213
214} // namespace Model
215} // namespace CloudWatch
216} // namespace Aws
void SetTimestamp(Aws::Utils::DateTime &&value)
Definition MetricDatum.h:84
void SetMetricName(const Aws::String &value)
Definition MetricDatum.h:54
void SetMetricName(const char *value)
Definition MetricDatum.h:56
void SetStatisticValues(StatisticSet &&value)
void SetDimensions(const Aws::Vector< Dimension > &value)
Definition MetricDatum.h:68
AWS_CLOUDWATCH_API MetricDatum & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
MetricDatum & WithTimestamp(const Aws::Utils::DateTime &value)
Definition MetricDatum.h:85
MetricDatum & WithTimestamp(Aws::Utils::DateTime &&value)
Definition MetricDatum.h:86
MetricDatum & WithDimensions(const Aws::Vector< Dimension > &value)
Definition MetricDatum.h:70
const Aws::Vector< Dimension > & GetDimensions() const
Definition MetricDatum.h:66
void SetCounts(const Aws::Vector< double > &value)
MetricDatum & AddDimensions(const Dimension &value)
Definition MetricDatum.h:72
const StandardUnit & GetUnit() const
AWS_CLOUDWATCH_API MetricDatum(const Aws::Utils::Xml::XmlNode &xmlNode)
void SetValues(Aws::Vector< double > &&value)
void SetValues(const Aws::Vector< double > &value)
void SetStatisticValues(const StatisticSet &value)
const Aws::Vector< double > & GetCounts() const
MetricDatum & WithValue(double value)
Definition MetricDatum.h:99
MetricDatum & AddDimensions(Dimension &&value)
Definition MetricDatum.h:73
void SetUnit(StandardUnit &&value)
void SetTimestamp(const Aws::Utils::DateTime &value)
Definition MetricDatum.h:83
AWS_CLOUDWATCH_API MetricDatum()
void SetUnit(const StandardUnit &value)
const Aws::Vector< double > & GetValues() const
MetricDatum & WithUnit(const StandardUnit &value)
MetricDatum & WithStorageResolution(int value)
void SetMetricName(Aws::String &&value)
Definition MetricDatum.h:55
MetricDatum & WithUnit(StandardUnit &&value)
MetricDatum & WithCounts(Aws::Vector< double > &&value)
const StatisticSet & GetStatisticValues() const
AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
const Aws::String & GetMetricName() const
Definition MetricDatum.h:52
MetricDatum & WithMetricName(const char *value)
Definition MetricDatum.h:59
void SetCounts(Aws::Vector< double > &&value)
MetricDatum & AddCounts(double value)
AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream &oStream, const char *location) const
MetricDatum & WithCounts(const Aws::Vector< double > &value)
MetricDatum & WithDimensions(Aws::Vector< Dimension > &&value)
Definition MetricDatum.h:71
const Aws::Utils::DateTime & GetTimestamp() const
Definition MetricDatum.h:81
MetricDatum & WithStatisticValues(StatisticSet &&value)
MetricDatum & AddValues(double value)
MetricDatum & WithMetricName(const Aws::String &value)
Definition MetricDatum.h:57
MetricDatum & WithMetricName(Aws::String &&value)
Definition MetricDatum.h:58
MetricDatum & WithValues(const Aws::Vector< double > &value)
MetricDatum & WithValues(Aws::Vector< double > &&value)
MetricDatum & WithStatisticValues(const StatisticSet &value)
void SetDimensions(Aws::Vector< Dimension > &&value)
Definition MetricDatum.h:69
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
std::basic_ostream< char, std::char_traits< char > > OStream