AWS SDK for C++  1.8.71
AWS SDK for C++
PutRuleRequest.h
Go to the documentation of this file.
1 
6 #pragma once
13 #include <utility>
14 
15 namespace Aws
16 {
17 namespace EventBridge
18 {
19 namespace Model
20 {
21 
25  {
26  public:
28 
29  // Service request name is the Operation name which will send this request out,
30  // each operation should has unique request name, so that we can get operation's name from this request.
31  // Note: this is not true for response, multiple operations may have the same response name,
32  // so we can not get operation's name from response.
33  inline virtual const char* GetServiceRequestName() const override { return "PutRule"; }
34 
35  Aws::String SerializePayload() const override;
36 
37  Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
38 
39 
43  inline const Aws::String& GetName() const{ return m_name; }
44 
48  inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
49 
53  inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; }
54 
58  inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); }
59 
63  inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); }
64 
68  inline PutRuleRequest& WithName(const Aws::String& value) { SetName(value); return *this;}
69 
73  inline PutRuleRequest& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;}
74 
78  inline PutRuleRequest& WithName(const char* value) { SetName(value); return *this;}
79 
80 
85  inline const Aws::String& GetScheduleExpression() const{ return m_scheduleExpression; }
86 
91  inline bool ScheduleExpressionHasBeenSet() const { return m_scheduleExpressionHasBeenSet; }
92 
97  inline void SetScheduleExpression(const Aws::String& value) { m_scheduleExpressionHasBeenSet = true; m_scheduleExpression = value; }
98 
103  inline void SetScheduleExpression(Aws::String&& value) { m_scheduleExpressionHasBeenSet = true; m_scheduleExpression = std::move(value); }
104 
109  inline void SetScheduleExpression(const char* value) { m_scheduleExpressionHasBeenSet = true; m_scheduleExpression.assign(value); }
110 
115  inline PutRuleRequest& WithScheduleExpression(const Aws::String& value) { SetScheduleExpression(value); return *this;}
116 
121  inline PutRuleRequest& WithScheduleExpression(Aws::String&& value) { SetScheduleExpression(std::move(value)); return *this;}
122 
127  inline PutRuleRequest& WithScheduleExpression(const char* value) { SetScheduleExpression(value); return *this;}
128 
129 
135  inline const Aws::String& GetEventPattern() const{ return m_eventPattern; }
136 
142  inline bool EventPatternHasBeenSet() const { return m_eventPatternHasBeenSet; }
143 
149  inline void SetEventPattern(const Aws::String& value) { m_eventPatternHasBeenSet = true; m_eventPattern = value; }
150 
156  inline void SetEventPattern(Aws::String&& value) { m_eventPatternHasBeenSet = true; m_eventPattern = std::move(value); }
157 
163  inline void SetEventPattern(const char* value) { m_eventPatternHasBeenSet = true; m_eventPattern.assign(value); }
164 
170  inline PutRuleRequest& WithEventPattern(const Aws::String& value) { SetEventPattern(value); return *this;}
171 
177  inline PutRuleRequest& WithEventPattern(Aws::String&& value) { SetEventPattern(std::move(value)); return *this;}
178 
184  inline PutRuleRequest& WithEventPattern(const char* value) { SetEventPattern(value); return *this;}
185 
186 
190  inline const RuleState& GetState() const{ return m_state; }
191 
195  inline bool StateHasBeenSet() const { return m_stateHasBeenSet; }
196 
200  inline void SetState(const RuleState& value) { m_stateHasBeenSet = true; m_state = value; }
201 
205  inline void SetState(RuleState&& value) { m_stateHasBeenSet = true; m_state = std::move(value); }
206 
210  inline PutRuleRequest& WithState(const RuleState& value) { SetState(value); return *this;}
211 
215  inline PutRuleRequest& WithState(RuleState&& value) { SetState(std::move(value)); return *this;}
216 
217 
221  inline const Aws::String& GetDescription() const{ return m_description; }
222 
226  inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
227 
231  inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; }
232 
236  inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); }
237 
241  inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); }
242 
246  inline PutRuleRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;}
247 
251  inline PutRuleRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;}
252 
256  inline PutRuleRequest& WithDescription(const char* value) { SetDescription(value); return *this;}
257 
258 
262  inline const Aws::String& GetRoleArn() const{ return m_roleArn; }
263 
267  inline bool RoleArnHasBeenSet() const { return m_roleArnHasBeenSet; }
268 
272  inline void SetRoleArn(const Aws::String& value) { m_roleArnHasBeenSet = true; m_roleArn = value; }
273 
277  inline void SetRoleArn(Aws::String&& value) { m_roleArnHasBeenSet = true; m_roleArn = std::move(value); }
278 
282  inline void SetRoleArn(const char* value) { m_roleArnHasBeenSet = true; m_roleArn.assign(value); }
283 
287  inline PutRuleRequest& WithRoleArn(const Aws::String& value) { SetRoleArn(value); return *this;}
288 
292  inline PutRuleRequest& WithRoleArn(Aws::String&& value) { SetRoleArn(std::move(value)); return *this;}
293 
297  inline PutRuleRequest& WithRoleArn(const char* value) { SetRoleArn(value); return *this;}
298 
299 
303  inline const Aws::Vector<Tag>& GetTags() const{ return m_tags; }
304 
308  inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
309 
313  inline void SetTags(const Aws::Vector<Tag>& value) { m_tagsHasBeenSet = true; m_tags = value; }
314 
318  inline void SetTags(Aws::Vector<Tag>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); }
319 
323  inline PutRuleRequest& WithTags(const Aws::Vector<Tag>& value) { SetTags(value); return *this;}
324 
328  inline PutRuleRequest& WithTags(Aws::Vector<Tag>&& value) { SetTags(std::move(value)); return *this;}
329 
333  inline PutRuleRequest& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
334 
338  inline PutRuleRequest& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; }
339 
340 
345  inline const Aws::String& GetEventBusName() const{ return m_eventBusName; }
346 
351  inline bool EventBusNameHasBeenSet() const { return m_eventBusNameHasBeenSet; }
352 
357  inline void SetEventBusName(const Aws::String& value) { m_eventBusNameHasBeenSet = true; m_eventBusName = value; }
358 
363  inline void SetEventBusName(Aws::String&& value) { m_eventBusNameHasBeenSet = true; m_eventBusName = std::move(value); }
364 
369  inline void SetEventBusName(const char* value) { m_eventBusNameHasBeenSet = true; m_eventBusName.assign(value); }
370 
375  inline PutRuleRequest& WithEventBusName(const Aws::String& value) { SetEventBusName(value); return *this;}
376 
381  inline PutRuleRequest& WithEventBusName(Aws::String&& value) { SetEventBusName(std::move(value)); return *this;}
382 
387  inline PutRuleRequest& WithEventBusName(const char* value) { SetEventBusName(value); return *this;}
388 
389  private:
390 
391  Aws::String m_name;
392  bool m_nameHasBeenSet;
393 
394  Aws::String m_scheduleExpression;
395  bool m_scheduleExpressionHasBeenSet;
396 
397  Aws::String m_eventPattern;
398  bool m_eventPatternHasBeenSet;
399 
400  RuleState m_state;
401  bool m_stateHasBeenSet;
402 
403  Aws::String m_description;
404  bool m_descriptionHasBeenSet;
405 
406  Aws::String m_roleArn;
407  bool m_roleArnHasBeenSet;
408 
409  Aws::Vector<Tag> m_tags;
410  bool m_tagsHasBeenSet;
411 
412  Aws::String m_eventBusName;
413  bool m_eventBusNameHasBeenSet;
414  };
415 
416 } // namespace Model
417 } // namespace EventBridge
418 } // namespace Aws
PutRuleRequest & WithRoleArn(Aws::String &&value)
PutRuleRequest & AddTags(const Tag &value)
void SetScheduleExpression(Aws::String &&value)
PutRuleRequest & WithDescription(const char *value)
PutRuleRequest & WithEventPattern(Aws::String &&value)
const Aws::String & GetScheduleExpression() const
void SetName(Aws::String &&value)
PutRuleRequest & WithEventBusName(Aws::String &&value)
const Aws::String & GetRoleArn() const
void SetEventPattern(const char *value)
PutRuleRequest & WithRoleArn(const char *value)
#define AWS_EVENTBRIDGE_API
void SetDescription(Aws::String &&value)
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:17
PutRuleRequest & WithRoleArn(const Aws::String &value)
PutRuleRequest & WithScheduleExpression(Aws::String &&value)
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
Definition: HttpTypes.h:53
PutRuleRequest & WithState(const RuleState &value)
PutRuleRequest & WithScheduleExpression(const Aws::String &value)
const Aws::String & GetName() const
const Aws::String & GetEventPattern() const
PutRuleRequest & WithScheduleExpression(const char *value)
PutRuleRequest & WithEventBusName(const char *value)
void SetScheduleExpression(const char *value)
PutRuleRequest & WithDescription(Aws::String &&value)
const Aws::String & GetDescription() const
PutRuleRequest & WithTags(const Aws::Vector< Tag > &value)
PutRuleRequest & AddTags(Tag &&value)
void SetEventPattern(const Aws::String &value)
void SetEventBusName(Aws::String &&value)
PutRuleRequest & WithTags(Aws::Vector< Tag > &&value)
void SetRoleArn(Aws::String &&value)
void SetEventBusName(const char *value)
PutRuleRequest & WithState(RuleState &&value)
PutRuleRequest & WithName(const Aws::String &value)
void SetState(const RuleState &value)
void SetName(const Aws::String &value)
PutRuleRequest & WithEventPattern(const char *value)
PutRuleRequest & WithEventBusName(const Aws::String &value)
PutRuleRequest & WithName(Aws::String &&value)
void SetDescription(const Aws::String &value)
void SetDescription(const char *value)
const Aws::String & GetEventBusName() const
PutRuleRequest & WithDescription(const Aws::String &value)
void SetTags(Aws::Vector< Tag > &&value)
const Aws::Vector< Tag > & GetTags() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
void SetRoleArn(const Aws::String &value)
void SetScheduleExpression(const Aws::String &value)
PutRuleRequest & WithName(const char *value)
virtual const char * GetServiceRequestName() const override
void SetEventPattern(Aws::String &&value)
void SetTags(const Aws::Vector< Tag > &value)
const RuleState & GetState() const
void SetEventBusName(const Aws::String &value)
PutRuleRequest & WithEventPattern(const Aws::String &value)