AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
CreateCustomMetricRequest.h
1
6#pragma once
7#include <aws/iot/IoT_EXPORTS.h>
8#include <aws/iot/IoTRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/iot/model/CustomMetricType.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <aws/iot/model/Tag.h>
13#include <utility>
14#include <aws/core/utils/UUID.h>
15
16namespace Aws
17{
18namespace IoT
19{
20namespace Model
21{
22
26 {
27 public:
28 AWS_IOT_API CreateCustomMetricRequest() = default;
29
30 // Service request name is the Operation name which will send this request out,
31 // each operation should has unique request name, so that we can get operation's name from this request.
32 // Note: this is not true for response, multiple operations may have the same response name,
33 // so we can not get operation's name from response.
34 inline virtual const char* GetServiceRequestName() const override { return "CreateCustomMetric"; }
35
36 AWS_IOT_API Aws::String SerializePayload() const override;
37
38
40
45 inline const Aws::String& GetMetricName() const { return m_metricName; }
46 inline bool MetricNameHasBeenSet() const { return m_metricNameHasBeenSet; }
47 template<typename MetricNameT = Aws::String>
48 void SetMetricName(MetricNameT&& value) { m_metricNameHasBeenSet = true; m_metricName = std::forward<MetricNameT>(value); }
49 template<typename MetricNameT = Aws::String>
50 CreateCustomMetricRequest& WithMetricName(MetricNameT&& value) { SetMetricName(std::forward<MetricNameT>(value)); return *this;}
52
54
59 inline const Aws::String& GetDisplayName() const { return m_displayName; }
60 inline bool DisplayNameHasBeenSet() const { return m_displayNameHasBeenSet; }
61 template<typename DisplayNameT = Aws::String>
62 void SetDisplayName(DisplayNameT&& value) { m_displayNameHasBeenSet = true; m_displayName = std::forward<DisplayNameT>(value); }
63 template<typename DisplayNameT = Aws::String>
64 CreateCustomMetricRequest& WithDisplayName(DisplayNameT&& value) { SetDisplayName(std::forward<DisplayNameT>(value)); return *this;}
66
68
74 inline CustomMetricType GetMetricType() const { return m_metricType; }
75 inline bool MetricTypeHasBeenSet() const { return m_metricTypeHasBeenSet; }
76 inline void SetMetricType(CustomMetricType value) { m_metricTypeHasBeenSet = true; m_metricType = value; }
79
81
84 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
85 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
86 template<typename TagsT = Aws::Vector<Tag>>
87 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
88 template<typename TagsT = Aws::Vector<Tag>>
89 CreateCustomMetricRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
90 template<typename TagsT = Tag>
91 CreateCustomMetricRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
93
95
101 inline const Aws::String& GetClientRequestToken() const { return m_clientRequestToken; }
102 inline bool ClientRequestTokenHasBeenSet() const { return m_clientRequestTokenHasBeenSet; }
103 template<typename ClientRequestTokenT = Aws::String>
104 void SetClientRequestToken(ClientRequestTokenT&& value) { m_clientRequestTokenHasBeenSet = true; m_clientRequestToken = std::forward<ClientRequestTokenT>(value); }
105 template<typename ClientRequestTokenT = Aws::String>
106 CreateCustomMetricRequest& WithClientRequestToken(ClientRequestTokenT&& value) { SetClientRequestToken(std::forward<ClientRequestTokenT>(value)); return *this;}
108 private:
109
110 Aws::String m_metricName;
111 bool m_metricNameHasBeenSet = false;
112
113 Aws::String m_displayName;
114 bool m_displayNameHasBeenSet = false;
115
117 bool m_metricTypeHasBeenSet = false;
118
119 Aws::Vector<Tag> m_tags;
120 bool m_tagsHasBeenSet = false;
121
122 Aws::String m_clientRequestToken{Aws::Utils::UUID::PseudoRandomUUID()};
123 bool m_clientRequestTokenHasBeenSet = true;
124 };
125
126} // namespace Model
127} // namespace IoT
128} // namespace Aws
CreateCustomMetricRequest & WithDisplayName(DisplayNameT &&value)
CreateCustomMetricRequest & AddTags(TagsT &&value)
AWS_IOT_API Aws::String SerializePayload() const override
void SetClientRequestToken(ClientRequestTokenT &&value)
virtual const char * GetServiceRequestName() const override
CreateCustomMetricRequest & WithTags(TagsT &&value)
CreateCustomMetricRequest & WithMetricType(CustomMetricType value)
AWS_IOT_API CreateCustomMetricRequest()=default
CreateCustomMetricRequest & WithMetricName(MetricNameT &&value)
CreateCustomMetricRequest & WithClientRequestToken(ClientRequestTokenT &&value)
static Aws::Utils::UUID PseudoRandomUUID()
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector