AWS SDK for C++

AWS SDK for C++ Version 1.11.941

Loading...
Searching...
No Matches
PutEventRequest.h
1
6#pragma once
7#include <aws/appmonetization/AppMonetizationRequest.h>
8#include <aws/appmonetization/AppMonetization_EXPORTS.h>
9#include <aws/appmonetization/model/RequestScope.h>
10#include <aws/core/utils/DateTime.h>
11#include <aws/core/utils/UUID.h>
12#include <aws/core/utils/memory/stl/AWSMap.h>
13#include <aws/core/utils/memory/stl/AWSString.h>
14
15#include <utility>
16
17namespace Aws {
18namespace Http {
19class URI;
20} // namespace Http
21namespace AppMonetization {
22namespace Model {
23
30 public:
31 AWS_APPMONETIZATION_API PutEventRequest() = default;
32
33 // Service request name is the Operation name which will send this request out,
34 // each operation should has unique request name, so that we can get operation's name from this request.
35 // Note: this is not true for response, multiple operations may have the same response name,
36 // so we can not get operation's name from response.
37 inline virtual const char* GetServiceRequestName() const override { return "PutEvent"; }
38
39 AWS_APPMONETIZATION_API Aws::String SerializePayload() const override;
40
41 AWS_APPMONETIZATION_API void AddQueryStringParameters(Aws::Http::URI& uri) const override;
42
44
47 inline const Aws::String& GetAppId() const { return m_appId; }
48 inline bool AppIdHasBeenSet() const { return m_appIdHasBeenSet; }
49 template <typename AppIdT = Aws::String>
50 void SetAppId(AppIdT&& value) {
51 m_appIdHasBeenSet = true;
52 m_appId = std::forward<AppIdT>(value);
53 }
54 template <typename AppIdT = Aws::String>
55 PutEventRequest& WithAppId(AppIdT&& value) {
56 SetAppId(std::forward<AppIdT>(value));
57 return *this;
58 }
60
62
67 inline const Aws::String& GetClientToken() const { return m_clientToken; }
68 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
69 template <typename ClientTokenT = Aws::String>
70 void SetClientToken(ClientTokenT&& value) {
71 m_clientTokenHasBeenSet = true;
72 m_clientToken = std::forward<ClientTokenT>(value);
73 }
74 template <typename ClientTokenT = Aws::String>
75 PutEventRequest& WithClientToken(ClientTokenT&& value) {
76 SetClientToken(std::forward<ClientTokenT>(value));
77 return *this;
78 }
80
82
86 inline const Aws::String& GetUserId() const { return m_userId; }
87 inline bool UserIdHasBeenSet() const { return m_userIdHasBeenSet; }
88 template <typename UserIdT = Aws::String>
89 void SetUserId(UserIdT&& value) {
90 m_userIdHasBeenSet = true;
91 m_userId = std::forward<UserIdT>(value);
92 }
93 template <typename UserIdT = Aws::String>
94 PutEventRequest& WithUserId(UserIdT&& value) {
95 SetUserId(std::forward<UserIdT>(value));
96 return *this;
97 }
99
101
105 inline const Aws::String& GetEventType() const { return m_eventType; }
106 inline bool EventTypeHasBeenSet() const { return m_eventTypeHasBeenSet; }
107 template <typename EventTypeT = Aws::String>
108 void SetEventType(EventTypeT&& value) {
109 m_eventTypeHasBeenSet = true;
110 m_eventType = std::forward<EventTypeT>(value);
111 }
112 template <typename EventTypeT = Aws::String>
113 PutEventRequest& WithEventType(EventTypeT&& value) {
114 SetEventType(std::forward<EventTypeT>(value));
115 return *this;
116 }
118
120
124 inline const Aws::String& GetQuantity() const { return m_quantity; }
125 inline bool QuantityHasBeenSet() const { return m_quantityHasBeenSet; }
126 template <typename QuantityT = Aws::String>
127 void SetQuantity(QuantityT&& value) {
128 m_quantityHasBeenSet = true;
129 m_quantity = std::forward<QuantityT>(value);
130 }
131 template <typename QuantityT = Aws::String>
132 PutEventRequest& WithQuantity(QuantityT&& value) {
133 SetQuantity(std::forward<QuantityT>(value));
134 return *this;
135 }
137
139
142 inline const Aws::Utils::DateTime& GetTimestamp() const { return m_timestamp; }
143 inline bool TimestampHasBeenSet() const { return m_timestampHasBeenSet; }
144 template <typename TimestampT = Aws::Utils::DateTime>
145 void SetTimestamp(TimestampT&& value) {
146 m_timestampHasBeenSet = true;
147 m_timestamp = std::forward<TimestampT>(value);
148 }
149 template <typename TimestampT = Aws::Utils::DateTime>
150 PutEventRequest& WithTimestamp(TimestampT&& value) {
151 SetTimestamp(std::forward<TimestampT>(value));
152 return *this;
153 }
155
157
164 inline const Aws::Map<Aws::String, Aws::String>& GetProperties() const { return m_properties; }
165 inline bool PropertiesHasBeenSet() const { return m_propertiesHasBeenSet; }
166 template <typename PropertiesT = Aws::Map<Aws::String, Aws::String>>
167 void SetProperties(PropertiesT&& value) {
168 m_propertiesHasBeenSet = true;
169 m_properties = std::forward<PropertiesT>(value);
170 }
171 template <typename PropertiesT = Aws::Map<Aws::String, Aws::String>>
172 PutEventRequest& WithProperties(PropertiesT&& value) {
173 SetProperties(std::forward<PropertiesT>(value));
174 return *this;
175 }
176 template <typename PropertiesKeyT = Aws::String, typename PropertiesValueT = Aws::String>
177 PutEventRequest& AddProperties(PropertiesKeyT&& key, PropertiesValueT&& value) {
178 m_propertiesHasBeenSet = true;
179 m_properties.emplace(std::forward<PropertiesKeyT>(key), std::forward<PropertiesValueT>(value));
180 return *this;
181 }
183
185
189 inline RequestScope GetScope() const { return m_scope; }
190 inline bool ScopeHasBeenSet() const { return m_scopeHasBeenSet; }
191 inline void SetScope(RequestScope value) {
192 m_scopeHasBeenSet = true;
193 m_scope = value;
194 }
196 SetScope(value);
197 return *this;
198 }
200 private:
201 Aws::String m_appId;
202
204
205 Aws::String m_userId;
206
207 Aws::String m_eventType;
208
209 Aws::String m_quantity;
210
211 Aws::Utils::DateTime m_timestamp{};
212
214
216 bool m_appIdHasBeenSet = false;
217 bool m_clientTokenHasBeenSet = true;
218 bool m_userIdHasBeenSet = false;
219 bool m_eventTypeHasBeenSet = false;
220 bool m_quantityHasBeenSet = false;
221 bool m_timestampHasBeenSet = false;
222 bool m_propertiesHasBeenSet = false;
223 bool m_scopeHasBeenSet = false;
224};
225
226} // namespace Model
227} // namespace AppMonetization
228} // namespace Aws
PutEventRequest & WithProperties(PropertiesT &&value)
PutEventRequest & WithClientToken(ClientTokenT &&value)
const Aws::Map< Aws::String, Aws::String > & GetProperties() const
virtual const char * GetServiceRequestName() const override
PutEventRequest & WithTimestamp(TimestampT &&value)
PutEventRequest & WithScope(RequestScope value)
PutEventRequest & AddProperties(PropertiesKeyT &&key, PropertiesValueT &&value)
PutEventRequest & WithEventType(EventTypeT &&value)
AWS_APPMONETIZATION_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
PutEventRequest & WithUserId(UserIdT &&value)
PutEventRequest & WithQuantity(QuantityT &&value)
AWS_APPMONETIZATION_API Aws::String SerializePayload() const override
AWS_APPMONETIZATION_API PutEventRequest()=default
PutEventRequest & WithAppId(AppIdT &&value)
const Aws::Utils::DateTime & GetTimestamp() const
static Aws::Utils::UUID PseudoRandomUUID()
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String