AWS SDK for C++

AWS SDK for C++ Version 1.11.741

Loading...
Searching...
No Matches
CampaignInAppMessage.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/InAppMessageContent.h>
12#include <aws/pinpoint/model/Layout.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
32 public:
33 AWS_PINPOINT_API CampaignInAppMessage() = default;
36 AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
42 inline const Aws::String& GetBody() const { return m_body; }
43 inline bool BodyHasBeenSet() const { return m_bodyHasBeenSet; }
44 template <typename BodyT = Aws::String>
45 void SetBody(BodyT&& value) {
46 m_bodyHasBeenSet = true;
47 m_body = std::forward<BodyT>(value);
48 }
49 template <typename BodyT = Aws::String>
51 SetBody(std::forward<BodyT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::Vector<InAppMessageContent>& GetContent() const { return m_content; }
61 inline bool ContentHasBeenSet() const { return m_contentHasBeenSet; }
62 template <typename ContentT = Aws::Vector<InAppMessageContent>>
63 void SetContent(ContentT&& value) {
64 m_contentHasBeenSet = true;
65 m_content = std::forward<ContentT>(value);
66 }
67 template <typename ContentT = Aws::Vector<InAppMessageContent>>
68 CampaignInAppMessage& WithContent(ContentT&& value) {
69 SetContent(std::forward<ContentT>(value));
70 return *this;
71 }
72 template <typename ContentT = InAppMessageContent>
73 CampaignInAppMessage& AddContent(ContentT&& value) {
74 m_contentHasBeenSet = true;
75 m_content.emplace_back(std::forward<ContentT>(value));
76 return *this;
77 }
79
81
84 inline const Aws::Map<Aws::String, Aws::String>& GetCustomConfig() const { return m_customConfig; }
85 inline bool CustomConfigHasBeenSet() const { return m_customConfigHasBeenSet; }
86 template <typename CustomConfigT = Aws::Map<Aws::String, Aws::String>>
87 void SetCustomConfig(CustomConfigT&& value) {
88 m_customConfigHasBeenSet = true;
89 m_customConfig = std::forward<CustomConfigT>(value);
90 }
91 template <typename CustomConfigT = Aws::Map<Aws::String, Aws::String>>
92 CampaignInAppMessage& WithCustomConfig(CustomConfigT&& value) {
93 SetCustomConfig(std::forward<CustomConfigT>(value));
94 return *this;
95 }
96 template <typename CustomConfigKeyT = Aws::String, typename CustomConfigValueT = Aws::String>
97 CampaignInAppMessage& AddCustomConfig(CustomConfigKeyT&& key, CustomConfigValueT&& value) {
98 m_customConfigHasBeenSet = true;
99 m_customConfig.emplace(std::forward<CustomConfigKeyT>(key), std::forward<CustomConfigValueT>(value));
100 return *this;
101 }
103
105
108 inline Layout GetLayout() const { return m_layout; }
109 inline bool LayoutHasBeenSet() const { return m_layoutHasBeenSet; }
110 inline void SetLayout(Layout value) {
111 m_layoutHasBeenSet = true;
112 m_layout = value;
113 }
115 SetLayout(value);
116 return *this;
117 }
119 private:
120 Aws::String m_body;
121
123
125
126 Layout m_layout{Layout::NOT_SET};
127 bool m_bodyHasBeenSet = false;
128 bool m_contentHasBeenSet = false;
129 bool m_customConfigHasBeenSet = false;
130 bool m_layoutHasBeenSet = false;
131};
132
133} // namespace Model
134} // namespace Pinpoint
135} // namespace Aws
CampaignInAppMessage & WithLayout(Layout value)
AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const
CampaignInAppMessage & WithCustomConfig(CustomConfigT &&value)
AWS_PINPOINT_API CampaignInAppMessage & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::Map< Aws::String, Aws::String > & GetCustomConfig() const
const Aws::Vector< InAppMessageContent > & GetContent() const
AWS_PINPOINT_API CampaignInAppMessage(Aws::Utils::Json::JsonView jsonValue)
CampaignInAppMessage & AddCustomConfig(CustomConfigKeyT &&key, CustomConfigValueT &&value)
CampaignInAppMessage & AddContent(ContentT &&value)
CampaignInAppMessage & WithBody(BodyT &&value)
AWS_PINPOINT_API CampaignInAppMessage()=default
CampaignInAppMessage & WithContent(ContentT &&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
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue