AWS SDK for C++

AWS SDK for C++ Version 1.11.748

Loading...
Searching...
No Matches
InAppMessage.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
33 public:
34 AWS_PINPOINT_API InAppMessage() = default;
35 AWS_PINPOINT_API InAppMessage(Aws::Utils::Json::JsonView jsonValue);
37 AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const;
38
40
43 inline const Aws::Vector<InAppMessageContent>& GetContent() const { return m_content; }
44 inline bool ContentHasBeenSet() const { return m_contentHasBeenSet; }
45 template <typename ContentT = Aws::Vector<InAppMessageContent>>
46 void SetContent(ContentT&& value) {
47 m_contentHasBeenSet = true;
48 m_content = std::forward<ContentT>(value);
49 }
50 template <typename ContentT = Aws::Vector<InAppMessageContent>>
51 InAppMessage& WithContent(ContentT&& value) {
52 SetContent(std::forward<ContentT>(value));
53 return *this;
54 }
55 template <typename ContentT = InAppMessageContent>
56 InAppMessage& AddContent(ContentT&& value) {
57 m_contentHasBeenSet = true;
58 m_content.emplace_back(std::forward<ContentT>(value));
59 return *this;
60 }
62
64
67 inline const Aws::Map<Aws::String, Aws::String>& GetCustomConfig() const { return m_customConfig; }
68 inline bool CustomConfigHasBeenSet() const { return m_customConfigHasBeenSet; }
69 template <typename CustomConfigT = Aws::Map<Aws::String, Aws::String>>
70 void SetCustomConfig(CustomConfigT&& value) {
71 m_customConfigHasBeenSet = true;
72 m_customConfig = std::forward<CustomConfigT>(value);
73 }
74 template <typename CustomConfigT = Aws::Map<Aws::String, Aws::String>>
75 InAppMessage& WithCustomConfig(CustomConfigT&& value) {
76 SetCustomConfig(std::forward<CustomConfigT>(value));
77 return *this;
78 }
79 template <typename CustomConfigKeyT = Aws::String, typename CustomConfigValueT = Aws::String>
80 InAppMessage& AddCustomConfig(CustomConfigKeyT&& key, CustomConfigValueT&& value) {
81 m_customConfigHasBeenSet = true;
82 m_customConfig.emplace(std::forward<CustomConfigKeyT>(key), std::forward<CustomConfigValueT>(value));
83 return *this;
84 }
86
88
91 inline Layout GetLayout() const { return m_layout; }
92 inline bool LayoutHasBeenSet() const { return m_layoutHasBeenSet; }
93 inline void SetLayout(Layout value) {
94 m_layoutHasBeenSet = true;
95 m_layout = value;
96 }
98 SetLayout(value);
99 return *this;
100 }
102 private:
104
106
107 Layout m_layout{Layout::NOT_SET};
108 bool m_contentHasBeenSet = false;
109 bool m_customConfigHasBeenSet = false;
110 bool m_layoutHasBeenSet = false;
111};
112
113} // namespace Model
114} // namespace Pinpoint
115} // namespace Aws
AWS_PINPOINT_API InAppMessage(Aws::Utils::Json::JsonView jsonValue)
const Aws::Map< Aws::String, Aws::String > & GetCustomConfig() const
AWS_PINPOINT_API InAppMessage & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_PINPOINT_API InAppMessage()=default
InAppMessage & WithLayout(Layout value)
void SetContent(ContentT &&value)
InAppMessage & AddCustomConfig(CustomConfigKeyT &&key, CustomConfigValueT &&value)
InAppMessage & AddContent(ContentT &&value)
AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const
InAppMessage & WithCustomConfig(CustomConfigT &&value)
const Aws::Vector< InAppMessageContent > & GetContent() const
InAppMessage & WithContent(ContentT &&value)
void SetCustomConfig(CustomConfigT &&value)
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue