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/eventbridge/EventBridge_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/eventbridge/model/RuleState.h>
10#include <utility>
11
12namespace Aws
13{
14namespace Utils
15{
16namespace Json
17{
18 class JsonValue;
19 class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace EventBridge
23{
24namespace Model
25{
26
33 class Rule
34 {
35 public:
36 AWS_EVENTBRIDGE_API Rule() = default;
37 AWS_EVENTBRIDGE_API Rule(Aws::Utils::Json::JsonView jsonValue);
38 AWS_EVENTBRIDGE_API Rule& operator=(Aws::Utils::Json::JsonView jsonValue);
39 AWS_EVENTBRIDGE_API Aws::Utils::Json::JsonValue Jsonize() const;
40
41
43
46 inline const Aws::String& GetName() const { return m_name; }
47 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
48 template<typename NameT = Aws::String>
49 void SetName(NameT&& value) { m_nameHasBeenSet = true; m_name = std::forward<NameT>(value); }
50 template<typename NameT = Aws::String>
51 Rule& WithName(NameT&& value) { SetName(std::forward<NameT>(value)); return *this;}
53
55
58 inline const Aws::String& GetArn() const { return m_arn; }
59 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
60 template<typename ArnT = Aws::String>
61 void SetArn(ArnT&& value) { m_arnHasBeenSet = true; m_arn = std::forward<ArnT>(value); }
62 template<typename ArnT = Aws::String>
63 Rule& WithArn(ArnT&& value) { SetArn(std::forward<ArnT>(value)); return *this;}
65
67
72 inline const Aws::String& GetEventPattern() const { return m_eventPattern; }
73 inline bool EventPatternHasBeenSet() const { return m_eventPatternHasBeenSet; }
74 template<typename EventPatternT = Aws::String>
75 void SetEventPattern(EventPatternT&& value) { m_eventPatternHasBeenSet = true; m_eventPattern = std::forward<EventPatternT>(value); }
76 template<typename EventPatternT = Aws::String>
77 Rule& WithEventPattern(EventPatternT&& value) { SetEventPattern(std::forward<EventPatternT>(value)); return *this;}
79
81
105 inline RuleState GetState() const { return m_state; }
106 inline bool StateHasBeenSet() const { return m_stateHasBeenSet; }
107 inline void SetState(RuleState value) { m_stateHasBeenSet = true; m_state = value; }
108 inline Rule& WithState(RuleState value) { SetState(value); return *this;}
110
112
115 inline const Aws::String& GetDescription() const { return m_description; }
116 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
117 template<typename DescriptionT = Aws::String>
118 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
119 template<typename DescriptionT = Aws::String>
120 Rule& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
122
124
130 inline const Aws::String& GetScheduleExpression() const { return m_scheduleExpression; }
131 inline bool ScheduleExpressionHasBeenSet() const { return m_scheduleExpressionHasBeenSet; }
132 template<typename ScheduleExpressionT = Aws::String>
133 void SetScheduleExpression(ScheduleExpressionT&& value) { m_scheduleExpressionHasBeenSet = true; m_scheduleExpression = std::forward<ScheduleExpressionT>(value); }
134 template<typename ScheduleExpressionT = Aws::String>
135 Rule& WithScheduleExpression(ScheduleExpressionT&& value) { SetScheduleExpression(std::forward<ScheduleExpressionT>(value)); return *this;}
137
139
147 inline const Aws::String& GetRoleArn() const { return m_roleArn; }
148 inline bool RoleArnHasBeenSet() const { return m_roleArnHasBeenSet; }
149 template<typename RoleArnT = Aws::String>
150 void SetRoleArn(RoleArnT&& value) { m_roleArnHasBeenSet = true; m_roleArn = std::forward<RoleArnT>(value); }
151 template<typename RoleArnT = Aws::String>
152 Rule& WithRoleArn(RoleArnT&& value) { SetRoleArn(std::forward<RoleArnT>(value)); return *this;}
154
156
161 inline const Aws::String& GetManagedBy() const { return m_managedBy; }
162 inline bool ManagedByHasBeenSet() const { return m_managedByHasBeenSet; }
163 template<typename ManagedByT = Aws::String>
164 void SetManagedBy(ManagedByT&& value) { m_managedByHasBeenSet = true; m_managedBy = std::forward<ManagedByT>(value); }
165 template<typename ManagedByT = Aws::String>
166 Rule& WithManagedBy(ManagedByT&& value) { SetManagedBy(std::forward<ManagedByT>(value)); return *this;}
168
170
174 inline const Aws::String& GetEventBusName() const { return m_eventBusName; }
175 inline bool EventBusNameHasBeenSet() const { return m_eventBusNameHasBeenSet; }
176 template<typename EventBusNameT = Aws::String>
177 void SetEventBusName(EventBusNameT&& value) { m_eventBusNameHasBeenSet = true; m_eventBusName = std::forward<EventBusNameT>(value); }
178 template<typename EventBusNameT = Aws::String>
179 Rule& WithEventBusName(EventBusNameT&& value) { SetEventBusName(std::forward<EventBusNameT>(value)); return *this;}
181 private:
182
183 Aws::String m_name;
184 bool m_nameHasBeenSet = false;
185
186 Aws::String m_arn;
187 bool m_arnHasBeenSet = false;
188
189 Aws::String m_eventPattern;
190 bool m_eventPatternHasBeenSet = false;
191
193 bool m_stateHasBeenSet = false;
194
195 Aws::String m_description;
196 bool m_descriptionHasBeenSet = false;
197
198 Aws::String m_scheduleExpression;
199 bool m_scheduleExpressionHasBeenSet = false;
200
201 Aws::String m_roleArn;
202 bool m_roleArnHasBeenSet = false;
203
204 Aws::String m_managedBy;
205 bool m_managedByHasBeenSet = false;
206
207 Aws::String m_eventBusName;
208 bool m_eventBusNameHasBeenSet = false;
209 };
210
211} // namespace Model
212} // namespace EventBridge
213} // namespace Aws
bool NameHasBeenSet() const
Definition Rule.h:47
bool ArnHasBeenSet() const
Definition Rule.h:59
bool EventBusNameHasBeenSet() const
Definition Rule.h:175
Rule & WithScheduleExpression(ScheduleExpressionT &&value)
Definition Rule.h:135
Rule & WithState(RuleState value)
Definition Rule.h:108
void SetManagedBy(ManagedByT &&value)
Definition Rule.h:164
Rule & WithRoleArn(RoleArnT &&value)
Definition Rule.h:152
Rule & WithDescription(DescriptionT &&value)
Definition Rule.h:120
AWS_EVENTBRIDGE_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::String & GetManagedBy() const
Definition Rule.h:161
Rule & WithArn(ArnT &&value)
Definition Rule.h:63
void SetEventPattern(EventPatternT &&value)
Definition Rule.h:75
AWS_EVENTBRIDGE_API Rule()=default
bool DescriptionHasBeenSet() const
Definition Rule.h:116
const Aws::String & GetDescription() const
Definition Rule.h:115
bool RoleArnHasBeenSet() const
Definition Rule.h:148
const Aws::String & GetScheduleExpression() const
Definition Rule.h:130
bool ManagedByHasBeenSet() const
Definition Rule.h:162
bool StateHasBeenSet() const
Definition Rule.h:106
AWS_EVENTBRIDGE_API Rule & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetArn(ArnT &&value)
Definition Rule.h:61
Rule & WithEventBusName(EventBusNameT &&value)
Definition Rule.h:179
void SetRoleArn(RoleArnT &&value)
Definition Rule.h:150
bool ScheduleExpressionHasBeenSet() const
Definition Rule.h:131
const Aws::String & GetArn() const
Definition Rule.h:58
void SetScheduleExpression(ScheduleExpressionT &&value)
Definition Rule.h:133
void SetState(RuleState value)
Definition Rule.h:107
const Aws::String & GetEventBusName() const
Definition Rule.h:174
void SetName(NameT &&value)
Definition Rule.h:49
bool EventPatternHasBeenSet() const
Definition Rule.h:73
const Aws::String & GetName() const
Definition Rule.h:46
Rule & WithEventPattern(EventPatternT &&value)
Definition Rule.h:77
RuleState GetState() const
Definition Rule.h:105
const Aws::String & GetEventPattern() const
Definition Rule.h:72
void SetEventBusName(EventBusNameT &&value)
Definition Rule.h:177
AWS_EVENTBRIDGE_API Rule(Aws::Utils::Json::JsonView jsonValue)
Rule & WithName(NameT &&value)
Definition Rule.h:51
Rule & WithManagedBy(ManagedByT &&value)
Definition Rule.h:166
void SetDescription(DescriptionT &&value)
Definition Rule.h:118
const Aws::String & GetRoleArn() const
Definition Rule.h:147
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue