AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
EntityMetricData.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSVector.h>
8#include <aws/crt/cbor/Cbor.h>
9#include <aws/monitoring/CloudWatch_EXPORTS.h>
10#include <aws/monitoring/model/Entity.h>
11#include <aws/monitoring/model/MetricDatum.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Cbor {
18class CborValue;
19} // namespace Cbor
20} // namespace Utils
21namespace CloudWatch {
22namespace Model {
23
32 public:
33 AWS_CLOUDWATCH_API EntityMetricData() = default;
34 AWS_CLOUDWATCH_API EntityMetricData(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
35 AWS_CLOUDWATCH_API EntityMetricData& operator=(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
36 AWS_CLOUDWATCH_API void CborEncode(Aws::Crt::Cbor::CborEncoder& encoder) const;
37
39
42 inline const Entity& GetEntity() const { return m_entity; }
43 inline bool EntityHasBeenSet() const { return m_entityHasBeenSet; }
44 template <typename EntityT = Entity>
45 void SetEntity(EntityT&& value) {
46 m_entityHasBeenSet = true;
47 m_entity = std::forward<EntityT>(value);
48 }
49 template <typename EntityT = Entity>
50 EntityMetricData& WithEntity(EntityT&& value) {
51 SetEntity(std::forward<EntityT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::Vector<MetricDatum>& GetMetricData() const { return m_metricData; }
61 inline bool MetricDataHasBeenSet() const { return m_metricDataHasBeenSet; }
62 template <typename MetricDataT = Aws::Vector<MetricDatum>>
63 void SetMetricData(MetricDataT&& value) {
64 m_metricDataHasBeenSet = true;
65 m_metricData = std::forward<MetricDataT>(value);
66 }
67 template <typename MetricDataT = Aws::Vector<MetricDatum>>
68 EntityMetricData& WithMetricData(MetricDataT&& value) {
69 SetMetricData(std::forward<MetricDataT>(value));
70 return *this;
71 }
72 template <typename MetricDataT = MetricDatum>
73 EntityMetricData& AddMetricData(MetricDataT&& value) {
74 m_metricDataHasBeenSet = true;
75 m_metricData.emplace_back(std::forward<MetricDataT>(value));
76 return *this;
77 }
79 private:
80 Entity m_entity;
81
82 Aws::Vector<MetricDatum> m_metricData;
83 bool m_entityHasBeenSet = false;
84 bool m_metricDataHasBeenSet = false;
85};
86
87} // namespace Model
88} // namespace CloudWatch
89} // namespace Aws
AWS_CLOUDWATCH_API EntityMetricData()=default
AWS_CLOUDWATCH_API void CborEncode(Aws::Crt::Cbor::CborEncoder &encoder) const
AWS_CLOUDWATCH_API EntityMetricData & operator=(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
EntityMetricData & WithMetricData(MetricDataT &&value)
EntityMetricData & AddMetricData(MetricDataT &&value)
const Aws::Vector< MetricDatum > & GetMetricData() const
EntityMetricData & WithEntity(EntityT &&value)
AWS_CLOUDWATCH_API EntityMetricData(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
std::vector< T, Aws::Allocator< T > > Vector