AWS SDK for C++

AWS SDK for C++ Version 1.11.746

Loading...
Searching...
No Matches
EventDimensions.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSMap.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/pinpoint/Pinpoint_EXPORTS.h>
10#include <aws/pinpoint/model/AttributeDimension.h>
11#include <aws/pinpoint/model/MetricDimension.h>
12#include <aws/pinpoint/model/SetDimension.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace Pinpoint {
24namespace Model {
25
33 public:
34 AWS_PINPOINT_API EventDimensions() = default;
35 AWS_PINPOINT_API EventDimensions(Aws::Utils::Json::JsonView jsonValue);
37 AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const;
38
40
45 inline const Aws::Map<Aws::String, AttributeDimension>& GetAttributes() const { return m_attributes; }
46 inline bool AttributesHasBeenSet() const { return m_attributesHasBeenSet; }
47 template <typename AttributesT = Aws::Map<Aws::String, AttributeDimension>>
48 void SetAttributes(AttributesT&& value) {
49 m_attributesHasBeenSet = true;
50 m_attributes = std::forward<AttributesT>(value);
51 }
52 template <typename AttributesT = Aws::Map<Aws::String, AttributeDimension>>
53 EventDimensions& WithAttributes(AttributesT&& value) {
54 SetAttributes(std::forward<AttributesT>(value));
55 return *this;
56 }
57 template <typename AttributesKeyT = Aws::String, typename AttributesValueT = AttributeDimension>
58 EventDimensions& AddAttributes(AttributesKeyT&& key, AttributesValueT&& value) {
59 m_attributesHasBeenSet = true;
60 m_attributes.emplace(std::forward<AttributesKeyT>(key), std::forward<AttributesValueT>(value));
61 return *this;
62 }
64
66
75 inline const SetDimension& GetEventType() const { return m_eventType; }
76 inline bool EventTypeHasBeenSet() const { return m_eventTypeHasBeenSet; }
77 template <typename EventTypeT = SetDimension>
78 void SetEventType(EventTypeT&& value) {
79 m_eventTypeHasBeenSet = true;
80 m_eventType = std::forward<EventTypeT>(value);
81 }
82 template <typename EventTypeT = SetDimension>
83 EventDimensions& WithEventType(EventTypeT&& value) {
84 SetEventType(std::forward<EventTypeT>(value));
85 return *this;
86 }
88
90
95 inline const Aws::Map<Aws::String, MetricDimension>& GetMetrics() const { return m_metrics; }
96 inline bool MetricsHasBeenSet() const { return m_metricsHasBeenSet; }
97 template <typename MetricsT = Aws::Map<Aws::String, MetricDimension>>
98 void SetMetrics(MetricsT&& value) {
99 m_metricsHasBeenSet = true;
100 m_metrics = std::forward<MetricsT>(value);
101 }
102 template <typename MetricsT = Aws::Map<Aws::String, MetricDimension>>
103 EventDimensions& WithMetrics(MetricsT&& value) {
104 SetMetrics(std::forward<MetricsT>(value));
105 return *this;
106 }
107 template <typename MetricsKeyT = Aws::String, typename MetricsValueT = MetricDimension>
108 EventDimensions& AddMetrics(MetricsKeyT&& key, MetricsValueT&& value) {
109 m_metricsHasBeenSet = true;
110 m_metrics.emplace(std::forward<MetricsKeyT>(key), std::forward<MetricsValueT>(value));
111 return *this;
112 }
114 private:
116
117 SetDimension m_eventType;
118
120 bool m_attributesHasBeenSet = false;
121 bool m_eventTypeHasBeenSet = false;
122 bool m_metricsHasBeenSet = false;
123};
124
125} // namespace Model
126} // namespace Pinpoint
127} // namespace Aws
EventDimensions & WithAttributes(AttributesT &&value)
AWS_PINPOINT_API EventDimensions & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const
EventDimensions & AddMetrics(MetricsKeyT &&key, MetricsValueT &&value)
const Aws::Map< Aws::String, AttributeDimension > & GetAttributes() const
AWS_PINPOINT_API EventDimensions(Aws::Utils::Json::JsonView jsonValue)
AWS_PINPOINT_API EventDimensions()=default
EventDimensions & WithEventType(EventTypeT &&value)
const SetDimension & GetEventType() const
void SetAttributes(AttributesT &&value)
EventDimensions & AddAttributes(AttributesKeyT &&key, AttributesValueT &&value)
const Aws::Map< Aws::String, MetricDimension > & GetMetrics() const
EventDimensions & WithMetrics(MetricsT &&value)
void SetEventType(EventTypeT &&value)
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Aws::Utils::Json::JsonValue JsonValue