AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
GCMMessage.h
1
6#pragma once
7#include <aws/pinpoint/Pinpoint_EXPORTS.h>
8#include <aws/pinpoint/model/Action.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSMap.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <utility>
13
14namespace Aws
15{
16namespace Utils
17{
18namespace Json
19{
20 class JsonValue;
21 class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace Pinpoint
25{
26namespace Model
27{
28
38 {
39 public:
40 AWS_PINPOINT_API GCMMessage() = default;
41 AWS_PINPOINT_API GCMMessage(Aws::Utils::Json::JsonView jsonValue);
42 AWS_PINPOINT_API GCMMessage& operator=(Aws::Utils::Json::JsonView jsonValue);
43 AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const;
44
45
47
56 inline Action GetAction() const { return m_action; }
57 inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; }
58 inline void SetAction(Action value) { m_actionHasBeenSet = true; m_action = value; }
59 inline GCMMessage& WithAction(Action value) { SetAction(value); return *this;}
61
63
66 inline const Aws::String& GetBody() const { return m_body; }
67 inline bool BodyHasBeenSet() const { return m_bodyHasBeenSet; }
68 template<typename BodyT = Aws::String>
69 void SetBody(BodyT&& value) { m_bodyHasBeenSet = true; m_body = std::forward<BodyT>(value); }
70 template<typename BodyT = Aws::String>
71 GCMMessage& WithBody(BodyT&& value) { SetBody(std::forward<BodyT>(value)); return *this;}
73
75
83 inline const Aws::String& GetCollapseKey() const { return m_collapseKey; }
84 inline bool CollapseKeyHasBeenSet() const { return m_collapseKeyHasBeenSet; }
85 template<typename CollapseKeyT = Aws::String>
86 void SetCollapseKey(CollapseKeyT&& value) { m_collapseKeyHasBeenSet = true; m_collapseKey = std::forward<CollapseKeyT>(value); }
87 template<typename CollapseKeyT = Aws::String>
88 GCMMessage& WithCollapseKey(CollapseKeyT&& value) { SetCollapseKey(std::forward<CollapseKeyT>(value)); return *this;}
90
92
97 inline const Aws::Map<Aws::String, Aws::String>& GetData() const { return m_data; }
98 inline bool DataHasBeenSet() const { return m_dataHasBeenSet; }
99 template<typename DataT = Aws::Map<Aws::String, Aws::String>>
100 void SetData(DataT&& value) { m_dataHasBeenSet = true; m_data = std::forward<DataT>(value); }
101 template<typename DataT = Aws::Map<Aws::String, Aws::String>>
102 GCMMessage& WithData(DataT&& value) { SetData(std::forward<DataT>(value)); return *this;}
103 template<typename DataKeyT = Aws::String, typename DataValueT = Aws::String>
104 GCMMessage& AddData(DataKeyT&& key, DataValueT&& value) {
105 m_dataHasBeenSet = true; m_data.emplace(std::forward<DataKeyT>(key), std::forward<DataValueT>(value)); return *this;
106 }
108
110
113 inline const Aws::String& GetIconReference() const { return m_iconReference; }
114 inline bool IconReferenceHasBeenSet() const { return m_iconReferenceHasBeenSet; }
115 template<typename IconReferenceT = Aws::String>
116 void SetIconReference(IconReferenceT&& value) { m_iconReferenceHasBeenSet = true; m_iconReference = std::forward<IconReferenceT>(value); }
117 template<typename IconReferenceT = Aws::String>
118 GCMMessage& WithIconReference(IconReferenceT&& value) { SetIconReference(std::forward<IconReferenceT>(value)); return *this;}
120
122
126 inline const Aws::String& GetImageIconUrl() const { return m_imageIconUrl; }
127 inline bool ImageIconUrlHasBeenSet() const { return m_imageIconUrlHasBeenSet; }
128 template<typename ImageIconUrlT = Aws::String>
129 void SetImageIconUrl(ImageIconUrlT&& value) { m_imageIconUrlHasBeenSet = true; m_imageIconUrl = std::forward<ImageIconUrlT>(value); }
130 template<typename ImageIconUrlT = Aws::String>
131 GCMMessage& WithImageIconUrl(ImageIconUrlT&& value) { SetImageIconUrl(std::forward<ImageIconUrlT>(value)); return *this;}
133
135
138 inline const Aws::String& GetImageUrl() const { return m_imageUrl; }
139 inline bool ImageUrlHasBeenSet() const { return m_imageUrlHasBeenSet; }
140 template<typename ImageUrlT = Aws::String>
141 void SetImageUrl(ImageUrlT&& value) { m_imageUrlHasBeenSet = true; m_imageUrl = std::forward<ImageUrlT>(value); }
142 template<typename ImageUrlT = Aws::String>
143 GCMMessage& WithImageUrl(ImageUrlT&& value) { SetImageUrl(std::forward<ImageUrlT>(value)); return *this;}
145
147
151 inline const Aws::String& GetPreferredAuthenticationMethod() const { return m_preferredAuthenticationMethod; }
152 inline bool PreferredAuthenticationMethodHasBeenSet() const { return m_preferredAuthenticationMethodHasBeenSet; }
153 template<typename PreferredAuthenticationMethodT = Aws::String>
154 void SetPreferredAuthenticationMethod(PreferredAuthenticationMethodT&& value) { m_preferredAuthenticationMethodHasBeenSet = true; m_preferredAuthenticationMethod = std::forward<PreferredAuthenticationMethodT>(value); }
155 template<typename PreferredAuthenticationMethodT = Aws::String>
156 GCMMessage& WithPreferredAuthenticationMethod(PreferredAuthenticationMethodT&& value) { SetPreferredAuthenticationMethod(std::forward<PreferredAuthenticationMethodT>(value)); return *this;}
158
160
171 inline const Aws::String& GetPriority() const { return m_priority; }
172 inline bool PriorityHasBeenSet() const { return m_priorityHasBeenSet; }
173 template<typename PriorityT = Aws::String>
174 void SetPriority(PriorityT&& value) { m_priorityHasBeenSet = true; m_priority = std::forward<PriorityT>(value); }
175 template<typename PriorityT = Aws::String>
176 GCMMessage& WithPriority(PriorityT&& value) { SetPriority(std::forward<PriorityT>(value)); return *this;}
178
180
185 inline const Aws::String& GetRawContent() const { return m_rawContent; }
186 inline bool RawContentHasBeenSet() const { return m_rawContentHasBeenSet; }
187 template<typename RawContentT = Aws::String>
188 void SetRawContent(RawContentT&& value) { m_rawContentHasBeenSet = true; m_rawContent = std::forward<RawContentT>(value); }
189 template<typename RawContentT = Aws::String>
190 GCMMessage& WithRawContent(RawContentT&& value) { SetRawContent(std::forward<RawContentT>(value)); return *this;}
192
194
198 inline const Aws::String& GetRestrictedPackageName() const { return m_restrictedPackageName; }
199 inline bool RestrictedPackageNameHasBeenSet() const { return m_restrictedPackageNameHasBeenSet; }
200 template<typename RestrictedPackageNameT = Aws::String>
201 void SetRestrictedPackageName(RestrictedPackageNameT&& value) { m_restrictedPackageNameHasBeenSet = true; m_restrictedPackageName = std::forward<RestrictedPackageNameT>(value); }
202 template<typename RestrictedPackageNameT = Aws::String>
203 GCMMessage& WithRestrictedPackageName(RestrictedPackageNameT&& value) { SetRestrictedPackageName(std::forward<RestrictedPackageNameT>(value)); return *this;}
205
207
213 inline bool GetSilentPush() const { return m_silentPush; }
214 inline bool SilentPushHasBeenSet() const { return m_silentPushHasBeenSet; }
215 inline void SetSilentPush(bool value) { m_silentPushHasBeenSet = true; m_silentPush = value; }
216 inline GCMMessage& WithSilentPush(bool value) { SetSilentPush(value); return *this;}
218
220
224 inline const Aws::String& GetSmallImageIconUrl() const { return m_smallImageIconUrl; }
225 inline bool SmallImageIconUrlHasBeenSet() const { return m_smallImageIconUrlHasBeenSet; }
226 template<typename SmallImageIconUrlT = Aws::String>
227 void SetSmallImageIconUrl(SmallImageIconUrlT&& value) { m_smallImageIconUrlHasBeenSet = true; m_smallImageIconUrl = std::forward<SmallImageIconUrlT>(value); }
228 template<typename SmallImageIconUrlT = Aws::String>
229 GCMMessage& WithSmallImageIconUrl(SmallImageIconUrlT&& value) { SetSmallImageIconUrl(std::forward<SmallImageIconUrlT>(value)); return *this;}
231
233
239 inline const Aws::String& GetSound() const { return m_sound; }
240 inline bool SoundHasBeenSet() const { return m_soundHasBeenSet; }
241 template<typename SoundT = Aws::String>
242 void SetSound(SoundT&& value) { m_soundHasBeenSet = true; m_sound = std::forward<SoundT>(value); }
243 template<typename SoundT = Aws::String>
244 GCMMessage& WithSound(SoundT&& value) { SetSound(std::forward<SoundT>(value)); return *this;}
246
248
252 inline const Aws::Map<Aws::String, Aws::Vector<Aws::String>>& GetSubstitutions() const { return m_substitutions; }
253 inline bool SubstitutionsHasBeenSet() const { return m_substitutionsHasBeenSet; }
254 template<typename SubstitutionsT = Aws::Map<Aws::String, Aws::Vector<Aws::String>>>
255 void SetSubstitutions(SubstitutionsT&& value) { m_substitutionsHasBeenSet = true; m_substitutions = std::forward<SubstitutionsT>(value); }
256 template<typename SubstitutionsT = Aws::Map<Aws::String, Aws::Vector<Aws::String>>>
257 GCMMessage& WithSubstitutions(SubstitutionsT&& value) { SetSubstitutions(std::forward<SubstitutionsT>(value)); return *this;}
258 template<typename SubstitutionsKeyT = Aws::String, typename SubstitutionsValueT = Aws::Vector<Aws::String>>
259 GCMMessage& AddSubstitutions(SubstitutionsKeyT&& key, SubstitutionsValueT&& value) {
260 m_substitutionsHasBeenSet = true; m_substitutions.emplace(std::forward<SubstitutionsKeyT>(key), std::forward<SubstitutionsValueT>(value)); return *this;
261 }
263
265
273 inline int GetTimeToLive() const { return m_timeToLive; }
274 inline bool TimeToLiveHasBeenSet() const { return m_timeToLiveHasBeenSet; }
275 inline void SetTimeToLive(int value) { m_timeToLiveHasBeenSet = true; m_timeToLive = value; }
276 inline GCMMessage& WithTimeToLive(int value) { SetTimeToLive(value); return *this;}
278
280
284 inline const Aws::String& GetTitle() const { return m_title; }
285 inline bool TitleHasBeenSet() const { return m_titleHasBeenSet; }
286 template<typename TitleT = Aws::String>
287 void SetTitle(TitleT&& value) { m_titleHasBeenSet = true; m_title = std::forward<TitleT>(value); }
288 template<typename TitleT = Aws::String>
289 GCMMessage& WithTitle(TitleT&& value) { SetTitle(std::forward<TitleT>(value)); return *this;}
291
293
297 inline const Aws::String& GetUrl() const { return m_url; }
298 inline bool UrlHasBeenSet() const { return m_urlHasBeenSet; }
299 template<typename UrlT = Aws::String>
300 void SetUrl(UrlT&& value) { m_urlHasBeenSet = true; m_url = std::forward<UrlT>(value); }
301 template<typename UrlT = Aws::String>
302 GCMMessage& WithUrl(UrlT&& value) { SetUrl(std::forward<UrlT>(value)); return *this;}
304 private:
305
306 Action m_action{Action::NOT_SET};
307 bool m_actionHasBeenSet = false;
308
309 Aws::String m_body;
310 bool m_bodyHasBeenSet = false;
311
312 Aws::String m_collapseKey;
313 bool m_collapseKeyHasBeenSet = false;
314
316 bool m_dataHasBeenSet = false;
317
318 Aws::String m_iconReference;
319 bool m_iconReferenceHasBeenSet = false;
320
321 Aws::String m_imageIconUrl;
322 bool m_imageIconUrlHasBeenSet = false;
323
324 Aws::String m_imageUrl;
325 bool m_imageUrlHasBeenSet = false;
326
327 Aws::String m_preferredAuthenticationMethod;
328 bool m_preferredAuthenticationMethodHasBeenSet = false;
329
330 Aws::String m_priority;
331 bool m_priorityHasBeenSet = false;
332
333 Aws::String m_rawContent;
334 bool m_rawContentHasBeenSet = false;
335
336 Aws::String m_restrictedPackageName;
337 bool m_restrictedPackageNameHasBeenSet = false;
338
339 bool m_silentPush{false};
340 bool m_silentPushHasBeenSet = false;
341
342 Aws::String m_smallImageIconUrl;
343 bool m_smallImageIconUrlHasBeenSet = false;
344
345 Aws::String m_sound;
346 bool m_soundHasBeenSet = false;
347
349 bool m_substitutionsHasBeenSet = false;
350
351 int m_timeToLive{0};
352 bool m_timeToLiveHasBeenSet = false;
353
354 Aws::String m_title;
355 bool m_titleHasBeenSet = false;
356
357 Aws::String m_url;
358 bool m_urlHasBeenSet = false;
359 };
360
361} // namespace Model
362} // namespace Pinpoint
363} // namespace Aws
const Aws::String & GetImageUrl() const
Definition GCMMessage.h:138
void SetImageIconUrl(ImageIconUrlT &&value)
Definition GCMMessage.h:129
void SetAction(Action value)
Definition GCMMessage.h:58
const Aws::String & GetRawContent() const
Definition GCMMessage.h:185
GCMMessage & WithBody(BodyT &&value)
Definition GCMMessage.h:71
void SetRawContent(RawContentT &&value)
Definition GCMMessage.h:188
void SetBody(BodyT &&value)
Definition GCMMessage.h:69
void SetPreferredAuthenticationMethod(PreferredAuthenticationMethodT &&value)
Definition GCMMessage.h:154
AWS_PINPOINT_API GCMMessage()=default
GCMMessage & WithCollapseKey(CollapseKeyT &&value)
Definition GCMMessage.h:88
GCMMessage & WithRawContent(RawContentT &&value)
Definition GCMMessage.h:190
void SetRestrictedPackageName(RestrictedPackageNameT &&value)
Definition GCMMessage.h:201
GCMMessage & WithTimeToLive(int value)
Definition GCMMessage.h:276
const Aws::String & GetSmallImageIconUrl() const
Definition GCMMessage.h:224
GCMMessage & AddData(DataKeyT &&key, DataValueT &&value)
Definition GCMMessage.h:104
void SetImageUrl(ImageUrlT &&value)
Definition GCMMessage.h:141
void SetTitle(TitleT &&value)
Definition GCMMessage.h:287
GCMMessage & AddSubstitutions(SubstitutionsKeyT &&key, SubstitutionsValueT &&value)
Definition GCMMessage.h:259
GCMMessage & WithSubstitutions(SubstitutionsT &&value)
Definition GCMMessage.h:257
const Aws::Map< Aws::String, Aws::Vector< Aws::String > > & GetSubstitutions() const
Definition GCMMessage.h:252
void SetSmallImageIconUrl(SmallImageIconUrlT &&value)
Definition GCMMessage.h:227
bool PreferredAuthenticationMethodHasBeenSet() const
Definition GCMMessage.h:152
void SetCollapseKey(CollapseKeyT &&value)
Definition GCMMessage.h:86
GCMMessage & WithSound(SoundT &&value)
Definition GCMMessage.h:244
void SetSubstitutions(SubstitutionsT &&value)
Definition GCMMessage.h:255
const Aws::String & GetPriority() const
Definition GCMMessage.h:171
GCMMessage & WithSmallImageIconUrl(SmallImageIconUrlT &&value)
Definition GCMMessage.h:229
const Aws::String & GetImageIconUrl() const
Definition GCMMessage.h:126
const Aws::String & GetRestrictedPackageName() const
Definition GCMMessage.h:198
void SetSound(SoundT &&value)
Definition GCMMessage.h:242
GCMMessage & WithAction(Action value)
Definition GCMMessage.h:59
GCMMessage & WithUrl(UrlT &&value)
Definition GCMMessage.h:302
AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::String & GetUrl() const
Definition GCMMessage.h:297
GCMMessage & WithPriority(PriorityT &&value)
Definition GCMMessage.h:176
AWS_PINPOINT_API GCMMessage(Aws::Utils::Json::JsonView jsonValue)
bool RestrictedPackageNameHasBeenSet() const
Definition GCMMessage.h:199
GCMMessage & WithImageUrl(ImageUrlT &&value)
Definition GCMMessage.h:143
GCMMessage & WithData(DataT &&value)
Definition GCMMessage.h:102
const Aws::String & GetIconReference() const
Definition GCMMessage.h:113
GCMMessage & WithIconReference(IconReferenceT &&value)
Definition GCMMessage.h:118
GCMMessage & WithPreferredAuthenticationMethod(PreferredAuthenticationMethodT &&value)
Definition GCMMessage.h:156
void SetData(DataT &&value)
Definition GCMMessage.h:100
const Aws::String & GetBody() const
Definition GCMMessage.h:66
void SetPriority(PriorityT &&value)
Definition GCMMessage.h:174
const Aws::Map< Aws::String, Aws::String > & GetData() const
Definition GCMMessage.h:97
const Aws::String & GetCollapseKey() const
Definition GCMMessage.h:83
GCMMessage & WithSilentPush(bool value)
Definition GCMMessage.h:216
const Aws::String & GetTitle() const
Definition GCMMessage.h:284
GCMMessage & WithImageIconUrl(ImageIconUrlT &&value)
Definition GCMMessage.h:131
const Aws::String & GetPreferredAuthenticationMethod() const
Definition GCMMessage.h:151
void SetIconReference(IconReferenceT &&value)
Definition GCMMessage.h:116
GCMMessage & WithRestrictedPackageName(RestrictedPackageNameT &&value)
Definition GCMMessage.h:203
GCMMessage & WithTitle(TitleT &&value)
Definition GCMMessage.h:289
AWS_PINPOINT_API GCMMessage & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetSound() const
Definition GCMMessage.h:239
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
Aws::Utils::Json::JsonValue JsonValue