AWS SDK for C++

AWS SDK for C++ Version 1.11.759

Loading...
Searching...
No Matches
MetricResultV2.h
1
6#pragma once
7#include <aws/connect/Connect_EXPORTS.h>
8#include <aws/connect/model/MetricDataV2.h>
9#include <aws/connect/model/MetricInterval.h>
10#include <aws/core/utils/memory/stl/AWSMap.h>
11#include <aws/core/utils/memory/stl/AWSString.h>
12#include <aws/core/utils/memory/stl/AWSVector.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace Connect {
24namespace Model {
25
32 public:
33 AWS_CONNECT_API MetricResultV2() = default;
34 AWS_CONNECT_API MetricResultV2(Aws::Utils::Json::JsonView jsonValue);
36 AWS_CONNECT_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
42 inline const Aws::Map<Aws::String, Aws::String>& GetDimensions() const { return m_dimensions; }
43 inline bool DimensionsHasBeenSet() const { return m_dimensionsHasBeenSet; }
44 template <typename DimensionsT = Aws::Map<Aws::String, Aws::String>>
45 void SetDimensions(DimensionsT&& value) {
46 m_dimensionsHasBeenSet = true;
47 m_dimensions = std::forward<DimensionsT>(value);
48 }
49 template <typename DimensionsT = Aws::Map<Aws::String, Aws::String>>
50 MetricResultV2& WithDimensions(DimensionsT&& value) {
51 SetDimensions(std::forward<DimensionsT>(value));
52 return *this;
53 }
54 template <typename DimensionsKeyT = Aws::String, typename DimensionsValueT = Aws::String>
55 MetricResultV2& AddDimensions(DimensionsKeyT&& key, DimensionsValueT&& value) {
56 m_dimensionsHasBeenSet = true;
57 m_dimensions.emplace(std::forward<DimensionsKeyT>(key), std::forward<DimensionsValueT>(value));
58 return *this;
59 }
61
63
66 inline const MetricInterval& GetMetricInterval() const { return m_metricInterval; }
67 inline bool MetricIntervalHasBeenSet() const { return m_metricIntervalHasBeenSet; }
68 template <typename MetricIntervalT = MetricInterval>
69 void SetMetricInterval(MetricIntervalT&& value) {
70 m_metricIntervalHasBeenSet = true;
71 m_metricInterval = std::forward<MetricIntervalT>(value);
72 }
73 template <typename MetricIntervalT = MetricInterval>
74 MetricResultV2& WithMetricInterval(MetricIntervalT&& value) {
75 SetMetricInterval(std::forward<MetricIntervalT>(value));
76 return *this;
77 }
79
81
84 inline const Aws::Vector<MetricDataV2>& GetCollections() const { return m_collections; }
85 inline bool CollectionsHasBeenSet() const { return m_collectionsHasBeenSet; }
86 template <typename CollectionsT = Aws::Vector<MetricDataV2>>
87 void SetCollections(CollectionsT&& value) {
88 m_collectionsHasBeenSet = true;
89 m_collections = std::forward<CollectionsT>(value);
90 }
91 template <typename CollectionsT = Aws::Vector<MetricDataV2>>
92 MetricResultV2& WithCollections(CollectionsT&& value) {
93 SetCollections(std::forward<CollectionsT>(value));
94 return *this;
95 }
96 template <typename CollectionsT = MetricDataV2>
97 MetricResultV2& AddCollections(CollectionsT&& value) {
98 m_collectionsHasBeenSet = true;
99 m_collections.emplace_back(std::forward<CollectionsT>(value));
100 return *this;
101 }
103 private:
105
106 MetricInterval m_metricInterval;
107
108 Aws::Vector<MetricDataV2> m_collections;
109 bool m_dimensionsHasBeenSet = false;
110 bool m_metricIntervalHasBeenSet = false;
111 bool m_collectionsHasBeenSet = false;
112};
113
114} // namespace Model
115} // namespace Connect
116} // namespace Aws
const Aws::Map< Aws::String, Aws::String > & GetDimensions() const
AWS_CONNECT_API MetricResultV2 & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_CONNECT_API MetricResultV2(Aws::Utils::Json::JsonView jsonValue)
const MetricInterval & GetMetricInterval() const
MetricResultV2 & WithMetricInterval(MetricIntervalT &&value)
void SetMetricInterval(MetricIntervalT &&value)
void SetDimensions(DimensionsT &&value)
MetricResultV2 & AddDimensions(DimensionsKeyT &&key, DimensionsValueT &&value)
AWS_CONNECT_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::Vector< MetricDataV2 > & GetCollections() const
MetricResultV2 & WithCollections(CollectionsT &&value)
MetricResultV2 & WithDimensions(DimensionsT &&value)
AWS_CONNECT_API MetricResultV2()=default
void SetCollections(CollectionsT &&value)
MetricResultV2 & AddCollections(CollectionsT &&value)
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue