AWS SDK for C++

AWS SDK for C++ Version 1.11.741

Loading...
Searching...
No Matches
DefaultPushNotificationMessage.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/core/utils/memory/stl/AWSVector.h>
10#include <aws/pinpoint/Pinpoint_EXPORTS.h>
11#include <aws/pinpoint/model/Action.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace Pinpoint {
23namespace Model {
24
32 public:
33 AWS_PINPOINT_API DefaultPushNotificationMessage() = default;
36 AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
49 inline Action GetAction() const { return m_action; }
50 inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; }
51 inline void SetAction(Action value) {
52 m_actionHasBeenSet = true;
53 m_action = value;
54 }
56 SetAction(value);
57 return *this;
58 }
60
62
65 inline const Aws::String& GetBody() const { return m_body; }
66 inline bool BodyHasBeenSet() const { return m_bodyHasBeenSet; }
67 template <typename BodyT = Aws::String>
68 void SetBody(BodyT&& value) {
69 m_bodyHasBeenSet = true;
70 m_body = std::forward<BodyT>(value);
71 }
72 template <typename BodyT = Aws::String>
74 SetBody(std::forward<BodyT>(value));
75 return *this;
76 }
78
80
85 inline const Aws::Map<Aws::String, Aws::String>& GetData() const { return m_data; }
86 inline bool DataHasBeenSet() const { return m_dataHasBeenSet; }
87 template <typename DataT = Aws::Map<Aws::String, Aws::String>>
88 void SetData(DataT&& value) {
89 m_dataHasBeenSet = true;
90 m_data = std::forward<DataT>(value);
91 }
92 template <typename DataT = Aws::Map<Aws::String, Aws::String>>
94 SetData(std::forward<DataT>(value));
95 return *this;
96 }
97 template <typename DataKeyT = Aws::String, typename DataValueT = Aws::String>
98 DefaultPushNotificationMessage& AddData(DataKeyT&& key, DataValueT&& value) {
99 m_dataHasBeenSet = true;
100 m_data.emplace(std::forward<DataKeyT>(key), std::forward<DataValueT>(value));
101 return *this;
102 }
104
106
112 inline bool GetSilentPush() const { return m_silentPush; }
113 inline bool SilentPushHasBeenSet() const { return m_silentPushHasBeenSet; }
114 inline void SetSilentPush(bool value) {
115 m_silentPushHasBeenSet = true;
116 m_silentPush = value;
117 }
119 SetSilentPush(value);
120 return *this;
121 }
123
125
129 inline const Aws::Map<Aws::String, Aws::Vector<Aws::String>>& GetSubstitutions() const { return m_substitutions; }
130 inline bool SubstitutionsHasBeenSet() const { return m_substitutionsHasBeenSet; }
131 template <typename SubstitutionsT = Aws::Map<Aws::String, Aws::Vector<Aws::String>>>
132 void SetSubstitutions(SubstitutionsT&& value) {
133 m_substitutionsHasBeenSet = true;
134 m_substitutions = std::forward<SubstitutionsT>(value);
135 }
136 template <typename SubstitutionsT = Aws::Map<Aws::String, Aws::Vector<Aws::String>>>
138 SetSubstitutions(std::forward<SubstitutionsT>(value));
139 return *this;
140 }
141 template <typename SubstitutionsKeyT = Aws::String, typename SubstitutionsValueT = Aws::Vector<Aws::String>>
142 DefaultPushNotificationMessage& AddSubstitutions(SubstitutionsKeyT&& key, SubstitutionsValueT&& value) {
143 m_substitutionsHasBeenSet = true;
144 m_substitutions.emplace(std::forward<SubstitutionsKeyT>(key), std::forward<SubstitutionsValueT>(value));
145 return *this;
146 }
148
150
154 inline const Aws::String& GetTitle() const { return m_title; }
155 inline bool TitleHasBeenSet() const { return m_titleHasBeenSet; }
156 template <typename TitleT = Aws::String>
157 void SetTitle(TitleT&& value) {
158 m_titleHasBeenSet = true;
159 m_title = std::forward<TitleT>(value);
160 }
161 template <typename TitleT = Aws::String>
163 SetTitle(std::forward<TitleT>(value));
164 return *this;
165 }
167
169
174 inline const Aws::String& GetUrl() const { return m_url; }
175 inline bool UrlHasBeenSet() const { return m_urlHasBeenSet; }
176 template <typename UrlT = Aws::String>
177 void SetUrl(UrlT&& value) {
178 m_urlHasBeenSet = true;
179 m_url = std::forward<UrlT>(value);
180 }
181 template <typename UrlT = Aws::String>
183 SetUrl(std::forward<UrlT>(value));
184 return *this;
185 }
187 private:
188 Action m_action{Action::NOT_SET};
189
190 Aws::String m_body;
191
193
194 bool m_silentPush{false};
195
197
198 Aws::String m_title;
199
200 Aws::String m_url;
201 bool m_actionHasBeenSet = false;
202 bool m_bodyHasBeenSet = false;
203 bool m_dataHasBeenSet = false;
204 bool m_silentPushHasBeenSet = false;
205 bool m_substitutionsHasBeenSet = false;
206 bool m_titleHasBeenSet = false;
207 bool m_urlHasBeenSet = false;
208};
209
210} // namespace Model
211} // namespace Pinpoint
212} // namespace Aws
DefaultPushNotificationMessage & WithData(DataT &&value)
AWS_PINPOINT_API DefaultPushNotificationMessage & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const
DefaultPushNotificationMessage & AddSubstitutions(SubstitutionsKeyT &&key, SubstitutionsValueT &&value)
DefaultPushNotificationMessage & WithSubstitutions(SubstitutionsT &&value)
DefaultPushNotificationMessage & WithUrl(UrlT &&value)
const Aws::Map< Aws::String, Aws::String > & GetData() const
AWS_PINPOINT_API DefaultPushNotificationMessage(Aws::Utils::Json::JsonView jsonValue)
DefaultPushNotificationMessage & WithSilentPush(bool value)
DefaultPushNotificationMessage & AddData(DataKeyT &&key, DataValueT &&value)
AWS_PINPOINT_API DefaultPushNotificationMessage()=default
DefaultPushNotificationMessage & WithTitle(TitleT &&value)
const Aws::Map< Aws::String, Aws::Vector< Aws::String > > & GetSubstitutions() const
DefaultPushNotificationMessage & WithBody(BodyT &&value)
DefaultPushNotificationMessage & WithAction(Action value)
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