AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
Rule.h
1
6#pragma once
7#include <aws/connect/Connect_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/connect/model/RuleTriggerEventSource.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/connect/model/RulePublishStatus.h>
12#include <aws/core/utils/DateTime.h>
13#include <aws/core/utils/memory/stl/AWSMap.h>
14#include <aws/connect/model/RuleAction.h>
15#include <utility>
16
17namespace Aws
18{
19namespace Utils
20{
21namespace Json
22{
23 class JsonValue;
24 class JsonView;
25} // namespace Json
26} // namespace Utils
27namespace Connect
28{
29namespace Model
30{
31
37 class Rule
38 {
39 public:
40 AWS_CONNECT_API Rule() = default;
41 AWS_CONNECT_API Rule(Aws::Utils::Json::JsonView jsonValue);
42 AWS_CONNECT_API Rule& operator=(Aws::Utils::Json::JsonView jsonValue);
43 AWS_CONNECT_API Aws::Utils::Json::JsonValue Jsonize() const;
44
45
47
50 inline const Aws::String& GetName() const { return m_name; }
51 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
52 template<typename NameT = Aws::String>
53 void SetName(NameT&& value) { m_nameHasBeenSet = true; m_name = std::forward<NameT>(value); }
54 template<typename NameT = Aws::String>
55 Rule& WithName(NameT&& value) { SetName(std::forward<NameT>(value)); return *this;}
57
59
62 inline const Aws::String& GetRuleId() const { return m_ruleId; }
63 inline bool RuleIdHasBeenSet() const { return m_ruleIdHasBeenSet; }
64 template<typename RuleIdT = Aws::String>
65 void SetRuleId(RuleIdT&& value) { m_ruleIdHasBeenSet = true; m_ruleId = std::forward<RuleIdT>(value); }
66 template<typename RuleIdT = Aws::String>
67 Rule& WithRuleId(RuleIdT&& value) { SetRuleId(std::forward<RuleIdT>(value)); return *this;}
69
71
74 inline const Aws::String& GetRuleArn() const { return m_ruleArn; }
75 inline bool RuleArnHasBeenSet() const { return m_ruleArnHasBeenSet; }
76 template<typename RuleArnT = Aws::String>
77 void SetRuleArn(RuleArnT&& value) { m_ruleArnHasBeenSet = true; m_ruleArn = std::forward<RuleArnT>(value); }
78 template<typename RuleArnT = Aws::String>
79 Rule& WithRuleArn(RuleArnT&& value) { SetRuleArn(std::forward<RuleArnT>(value)); return *this;}
81
83
86 inline const RuleTriggerEventSource& GetTriggerEventSource() const { return m_triggerEventSource; }
87 inline bool TriggerEventSourceHasBeenSet() const { return m_triggerEventSourceHasBeenSet; }
88 template<typename TriggerEventSourceT = RuleTriggerEventSource>
89 void SetTriggerEventSource(TriggerEventSourceT&& value) { m_triggerEventSourceHasBeenSet = true; m_triggerEventSource = std::forward<TriggerEventSourceT>(value); }
90 template<typename TriggerEventSourceT = RuleTriggerEventSource>
91 Rule& WithTriggerEventSource(TriggerEventSourceT&& value) { SetTriggerEventSource(std::forward<TriggerEventSourceT>(value)); return *this;}
93
95
98 inline const Aws::String& GetFunction() const { return m_function; }
99 inline bool FunctionHasBeenSet() const { return m_functionHasBeenSet; }
100 template<typename FunctionT = Aws::String>
101 void SetFunction(FunctionT&& value) { m_functionHasBeenSet = true; m_function = std::forward<FunctionT>(value); }
102 template<typename FunctionT = Aws::String>
103 Rule& WithFunction(FunctionT&& value) { SetFunction(std::forward<FunctionT>(value)); return *this;}
105
107
110 inline const Aws::Vector<RuleAction>& GetActions() const { return m_actions; }
111 inline bool ActionsHasBeenSet() const { return m_actionsHasBeenSet; }
112 template<typename ActionsT = Aws::Vector<RuleAction>>
113 void SetActions(ActionsT&& value) { m_actionsHasBeenSet = true; m_actions = std::forward<ActionsT>(value); }
114 template<typename ActionsT = Aws::Vector<RuleAction>>
115 Rule& WithActions(ActionsT&& value) { SetActions(std::forward<ActionsT>(value)); return *this;}
116 template<typename ActionsT = RuleAction>
117 Rule& AddActions(ActionsT&& value) { m_actionsHasBeenSet = true; m_actions.emplace_back(std::forward<ActionsT>(value)); return *this; }
119
121
124 inline RulePublishStatus GetPublishStatus() const { return m_publishStatus; }
125 inline bool PublishStatusHasBeenSet() const { return m_publishStatusHasBeenSet; }
126 inline void SetPublishStatus(RulePublishStatus value) { m_publishStatusHasBeenSet = true; m_publishStatus = value; }
127 inline Rule& WithPublishStatus(RulePublishStatus value) { SetPublishStatus(value); return *this;}
129
131
134 inline const Aws::Utils::DateTime& GetCreatedTime() const { return m_createdTime; }
135 inline bool CreatedTimeHasBeenSet() const { return m_createdTimeHasBeenSet; }
136 template<typename CreatedTimeT = Aws::Utils::DateTime>
137 void SetCreatedTime(CreatedTimeT&& value) { m_createdTimeHasBeenSet = true; m_createdTime = std::forward<CreatedTimeT>(value); }
138 template<typename CreatedTimeT = Aws::Utils::DateTime>
139 Rule& WithCreatedTime(CreatedTimeT&& value) { SetCreatedTime(std::forward<CreatedTimeT>(value)); return *this;}
141
143
146 inline const Aws::Utils::DateTime& GetLastUpdatedTime() const { return m_lastUpdatedTime; }
147 inline bool LastUpdatedTimeHasBeenSet() const { return m_lastUpdatedTimeHasBeenSet; }
148 template<typename LastUpdatedTimeT = Aws::Utils::DateTime>
149 void SetLastUpdatedTime(LastUpdatedTimeT&& value) { m_lastUpdatedTimeHasBeenSet = true; m_lastUpdatedTime = std::forward<LastUpdatedTimeT>(value); }
150 template<typename LastUpdatedTimeT = Aws::Utils::DateTime>
151 Rule& WithLastUpdatedTime(LastUpdatedTimeT&& value) { SetLastUpdatedTime(std::forward<LastUpdatedTimeT>(value)); return *this;}
153
155
158 inline const Aws::String& GetLastUpdatedBy() const { return m_lastUpdatedBy; }
159 inline bool LastUpdatedByHasBeenSet() const { return m_lastUpdatedByHasBeenSet; }
160 template<typename LastUpdatedByT = Aws::String>
161 void SetLastUpdatedBy(LastUpdatedByT&& value) { m_lastUpdatedByHasBeenSet = true; m_lastUpdatedBy = std::forward<LastUpdatedByT>(value); }
162 template<typename LastUpdatedByT = Aws::String>
163 Rule& WithLastUpdatedBy(LastUpdatedByT&& value) { SetLastUpdatedBy(std::forward<LastUpdatedByT>(value)); return *this;}
165
167
171 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
172 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
173 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
174 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
175 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
176 Rule& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
177 template<typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
178 Rule& AddTags(TagsKeyT&& key, TagsValueT&& value) {
179 m_tagsHasBeenSet = true; m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value)); return *this;
180 }
182 private:
183
184 Aws::String m_name;
185 bool m_nameHasBeenSet = false;
186
187 Aws::String m_ruleId;
188 bool m_ruleIdHasBeenSet = false;
189
190 Aws::String m_ruleArn;
191 bool m_ruleArnHasBeenSet = false;
192
193 RuleTriggerEventSource m_triggerEventSource;
194 bool m_triggerEventSourceHasBeenSet = false;
195
196 Aws::String m_function;
197 bool m_functionHasBeenSet = false;
198
199 Aws::Vector<RuleAction> m_actions;
200 bool m_actionsHasBeenSet = false;
201
203 bool m_publishStatusHasBeenSet = false;
204
205 Aws::Utils::DateTime m_createdTime{};
206 bool m_createdTimeHasBeenSet = false;
207
208 Aws::Utils::DateTime m_lastUpdatedTime{};
209 bool m_lastUpdatedTimeHasBeenSet = false;
210
211 Aws::String m_lastUpdatedBy;
212 bool m_lastUpdatedByHasBeenSet = false;
213
215 bool m_tagsHasBeenSet = false;
216 };
217
218} // namespace Model
219} // namespace Connect
220} // namespace Aws
Rule & WithLastUpdatedTime(LastUpdatedTimeT &&value)
Definition Rule.h:151
Rule & WithName(NameT &&value)
Definition Rule.h:55
Rule & WithRuleId(RuleIdT &&value)
Definition Rule.h:67
RulePublishStatus GetPublishStatus() const
Definition Rule.h:124
void SetFunction(FunctionT &&value)
Definition Rule.h:101
const Aws::Vector< RuleAction > & GetActions() const
Definition Rule.h:110
bool PublishStatusHasBeenSet() const
Definition Rule.h:125
Rule & WithRuleArn(RuleArnT &&value)
Definition Rule.h:79
bool TriggerEventSourceHasBeenSet() const
Definition Rule.h:87
bool CreatedTimeHasBeenSet() const
Definition Rule.h:135
const Aws::String & GetFunction() const
Definition Rule.h:98
bool FunctionHasBeenSet() const
Definition Rule.h:99
Rule & WithLastUpdatedBy(LastUpdatedByT &&value)
Definition Rule.h:163
Rule & WithFunction(FunctionT &&value)
Definition Rule.h:103
void SetTags(TagsT &&value)
Definition Rule.h:174
const RuleTriggerEventSource & GetTriggerEventSource() const
Definition Rule.h:86
const Aws::Utils::DateTime & GetCreatedTime() const
Definition Rule.h:134
bool NameHasBeenSet() const
Definition Rule.h:51
bool TagsHasBeenSet() const
Definition Rule.h:172
void SetLastUpdatedBy(LastUpdatedByT &&value)
Definition Rule.h:161
Rule & WithActions(ActionsT &&value)
Definition Rule.h:115
AWS_CONNECT_API Rule(Aws::Utils::Json::JsonView jsonValue)
void SetCreatedTime(CreatedTimeT &&value)
Definition Rule.h:137
void SetTriggerEventSource(TriggerEventSourceT &&value)
Definition Rule.h:89
void SetLastUpdatedTime(LastUpdatedTimeT &&value)
Definition Rule.h:149
void SetActions(ActionsT &&value)
Definition Rule.h:113
Rule & AddActions(ActionsT &&value)
Definition Rule.h:117
Rule & WithCreatedTime(CreatedTimeT &&value)
Definition Rule.h:139
bool LastUpdatedTimeHasBeenSet() const
Definition Rule.h:147
bool LastUpdatedByHasBeenSet() const
Definition Rule.h:159
const Aws::String & GetLastUpdatedBy() const
Definition Rule.h:158
AWS_CONNECT_API Rule()=default
Rule & WithTags(TagsT &&value)
Definition Rule.h:176
const Aws::String & GetRuleArn() const
Definition Rule.h:74
Rule & WithTriggerEventSource(TriggerEventSourceT &&value)
Definition Rule.h:91
void SetName(NameT &&value)
Definition Rule.h:53
AWS_CONNECT_API Aws::Utils::Json::JsonValue Jsonize() const
void SetPublishStatus(RulePublishStatus value)
Definition Rule.h:126
const Aws::Utils::DateTime & GetLastUpdatedTime() const
Definition Rule.h:146
void SetRuleId(RuleIdT &&value)
Definition Rule.h:65
Rule & WithPublishStatus(RulePublishStatus value)
Definition Rule.h:127
void SetRuleArn(RuleArnT &&value)
Definition Rule.h:77
Rule & AddTags(TagsKeyT &&key, TagsValueT &&value)
Definition Rule.h:178
bool ActionsHasBeenSet() const
Definition Rule.h:111
AWS_CONNECT_API Rule & operator=(Aws::Utils::Json::JsonView jsonValue)
bool RuleIdHasBeenSet() const
Definition Rule.h:63
const Aws::String & GetRuleId() const
Definition Rule.h:62
const Aws::Map< Aws::String, Aws::String > & GetTags() const
Definition Rule.h:171
bool RuleArnHasBeenSet() const
Definition Rule.h:75
const Aws::String & GetName() const
Definition Rule.h:50
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