AWS SDK for C++

AWS SDK for C++ Version 1.11.758

Loading...
Searching...
No Matches
Action.h
1
6#pragma once
7#include <aws/budgets/Budgets_EXPORTS.h>
8#include <aws/budgets/model/ActionStatus.h>
9#include <aws/budgets/model/ActionThreshold.h>
10#include <aws/budgets/model/ActionType.h>
11#include <aws/budgets/model/ApprovalModel.h>
12#include <aws/budgets/model/Definition.h>
13#include <aws/budgets/model/NotificationType.h>
14#include <aws/budgets/model/Subscriber.h>
15#include <aws/core/utils/memory/stl/AWSString.h>
16#include <aws/core/utils/memory/stl/AWSVector.h>
17
18#include <utility>
19
20namespace Aws {
21namespace Utils {
22namespace Json {
23class JsonValue;
24class JsonView;
25} // namespace Json
26} // namespace Utils
27namespace Budgets {
28namespace Model {
29
35class Action {
36 public:
37 AWS_BUDGETS_API Action() = default;
38 AWS_BUDGETS_API Action(Aws::Utils::Json::JsonView jsonValue);
39 AWS_BUDGETS_API Action& operator=(Aws::Utils::Json::JsonView jsonValue);
40 AWS_BUDGETS_API Aws::Utils::Json::JsonValue Jsonize() const;
41
43
46 inline const Aws::String& GetActionId() const { return m_actionId; }
47 inline bool ActionIdHasBeenSet() const { return m_actionIdHasBeenSet; }
48 template <typename ActionIdT = Aws::String>
49 void SetActionId(ActionIdT&& value) {
50 m_actionIdHasBeenSet = true;
51 m_actionId = std::forward<ActionIdT>(value);
52 }
53 template <typename ActionIdT = Aws::String>
54 Action& WithActionId(ActionIdT&& value) {
55 SetActionId(std::forward<ActionIdT>(value));
56 return *this;
57 }
59
61
62 inline const Aws::String& GetBudgetName() const { return m_budgetName; }
63 inline bool BudgetNameHasBeenSet() const { return m_budgetNameHasBeenSet; }
64 template <typename BudgetNameT = Aws::String>
65 void SetBudgetName(BudgetNameT&& value) {
66 m_budgetNameHasBeenSet = true;
67 m_budgetName = std::forward<BudgetNameT>(value);
68 }
69 template <typename BudgetNameT = Aws::String>
70 Action& WithBudgetName(BudgetNameT&& value) {
71 SetBudgetName(std::forward<BudgetNameT>(value));
72 return *this;
73 }
75
77
78 inline NotificationType GetNotificationType() const { return m_notificationType; }
79 inline bool NotificationTypeHasBeenSet() const { return m_notificationTypeHasBeenSet; }
81 m_notificationTypeHasBeenSet = true;
82 m_notificationType = value;
83 }
86 return *this;
87 }
89
91
95 inline ActionType GetActionType() const { return m_actionType; }
96 inline bool ActionTypeHasBeenSet() const { return m_actionTypeHasBeenSet; }
97 inline void SetActionType(ActionType value) {
98 m_actionTypeHasBeenSet = true;
99 m_actionType = value;
100 }
102 SetActionType(value);
103 return *this;
104 }
106
108
111 inline const ActionThreshold& GetActionThreshold() const { return m_actionThreshold; }
112 inline bool ActionThresholdHasBeenSet() const { return m_actionThresholdHasBeenSet; }
113 template <typename ActionThresholdT = ActionThreshold>
114 void SetActionThreshold(ActionThresholdT&& value) {
115 m_actionThresholdHasBeenSet = true;
116 m_actionThreshold = std::forward<ActionThresholdT>(value);
117 }
118 template <typename ActionThresholdT = ActionThreshold>
119 Action& WithActionThreshold(ActionThresholdT&& value) {
120 SetActionThreshold(std::forward<ActionThresholdT>(value));
121 return *this;
122 }
124
126
129 inline const Definition& GetDefinition() const { return m_definition; }
130 inline bool DefinitionHasBeenSet() const { return m_definitionHasBeenSet; }
131 template <typename DefinitionT = Definition>
132 void SetDefinition(DefinitionT&& value) {
133 m_definitionHasBeenSet = true;
134 m_definition = std::forward<DefinitionT>(value);
135 }
136 template <typename DefinitionT = Definition>
137 Action& WithDefinition(DefinitionT&& value) {
138 SetDefinition(std::forward<DefinitionT>(value));
139 return *this;
140 }
142
144
148 inline const Aws::String& GetExecutionRoleArn() const { return m_executionRoleArn; }
149 inline bool ExecutionRoleArnHasBeenSet() const { return m_executionRoleArnHasBeenSet; }
150 template <typename ExecutionRoleArnT = Aws::String>
151 void SetExecutionRoleArn(ExecutionRoleArnT&& value) {
152 m_executionRoleArnHasBeenSet = true;
153 m_executionRoleArn = std::forward<ExecutionRoleArnT>(value);
154 }
155 template <typename ExecutionRoleArnT = Aws::String>
156 Action& WithExecutionRoleArn(ExecutionRoleArnT&& value) {
157 SetExecutionRoleArn(std::forward<ExecutionRoleArnT>(value));
158 return *this;
159 }
161
163
166 inline ApprovalModel GetApprovalModel() const { return m_approvalModel; }
167 inline bool ApprovalModelHasBeenSet() const { return m_approvalModelHasBeenSet; }
168 inline void SetApprovalModel(ApprovalModel value) {
169 m_approvalModelHasBeenSet = true;
170 m_approvalModel = value;
171 }
173 SetApprovalModel(value);
174 return *this;
175 }
177
179
182 inline ActionStatus GetStatus() const { return m_status; }
183 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
184 inline void SetStatus(ActionStatus value) {
185 m_statusHasBeenSet = true;
186 m_status = value;
187 }
189 SetStatus(value);
190 return *this;
191 }
193
195
196 inline const Aws::Vector<Subscriber>& GetSubscribers() const { return m_subscribers; }
197 inline bool SubscribersHasBeenSet() const { return m_subscribersHasBeenSet; }
198 template <typename SubscribersT = Aws::Vector<Subscriber>>
199 void SetSubscribers(SubscribersT&& value) {
200 m_subscribersHasBeenSet = true;
201 m_subscribers = std::forward<SubscribersT>(value);
202 }
203 template <typename SubscribersT = Aws::Vector<Subscriber>>
204 Action& WithSubscribers(SubscribersT&& value) {
205 SetSubscribers(std::forward<SubscribersT>(value));
206 return *this;
207 }
208 template <typename SubscribersT = Subscriber>
209 Action& AddSubscribers(SubscribersT&& value) {
210 m_subscribersHasBeenSet = true;
211 m_subscribers.emplace_back(std::forward<SubscribersT>(value));
212 return *this;
213 }
215 private:
216 Aws::String m_actionId;
217
218 Aws::String m_budgetName;
219
221
222 ActionType m_actionType{ActionType::NOT_SET};
223
224 ActionThreshold m_actionThreshold;
225
226 Definition m_definition;
227
228 Aws::String m_executionRoleArn;
229
230 ApprovalModel m_approvalModel{ApprovalModel::NOT_SET};
231
233
234 Aws::Vector<Subscriber> m_subscribers;
235 bool m_actionIdHasBeenSet = false;
236 bool m_budgetNameHasBeenSet = false;
237 bool m_notificationTypeHasBeenSet = false;
238 bool m_actionTypeHasBeenSet = false;
239 bool m_actionThresholdHasBeenSet = false;
240 bool m_definitionHasBeenSet = false;
241 bool m_executionRoleArnHasBeenSet = false;
242 bool m_approvalModelHasBeenSet = false;
243 bool m_statusHasBeenSet = false;
244 bool m_subscribersHasBeenSet = false;
245};
246
247} // namespace Model
248} // namespace Budgets
249} // namespace Aws
Action & WithActionId(ActionIdT &&value)
Definition Action.h:54
bool BudgetNameHasBeenSet() const
Definition Action.h:63
bool ActionThresholdHasBeenSet() const
Definition Action.h:112
void SetActionThreshold(ActionThresholdT &&value)
Definition Action.h:114
bool StatusHasBeenSet() const
Definition Action.h:183
ActionType GetActionType() const
Definition Action.h:95
void SetSubscribers(SubscribersT &&value)
Definition Action.h:199
void SetExecutionRoleArn(ExecutionRoleArnT &&value)
Definition Action.h:151
Action & WithBudgetName(BudgetNameT &&value)
Definition Action.h:70
AWS_BUDGETS_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::Vector< Subscriber > & GetSubscribers() const
Definition Action.h:196
AWS_BUDGETS_API Action & operator=(Aws::Utils::Json::JsonView jsonValue)
Action & WithExecutionRoleArn(ExecutionRoleArnT &&value)
Definition Action.h:156
const Definition & GetDefinition() const
Definition Action.h:129
bool ActionTypeHasBeenSet() const
Definition Action.h:96
Action & WithSubscribers(SubscribersT &&value)
Definition Action.h:204
void SetDefinition(DefinitionT &&value)
Definition Action.h:132
ApprovalModel GetApprovalModel() const
Definition Action.h:166
bool DefinitionHasBeenSet() const
Definition Action.h:130
void SetNotificationType(NotificationType value)
Definition Action.h:80
const Aws::String & GetActionId() const
Definition Action.h:46
AWS_BUDGETS_API Action(Aws::Utils::Json::JsonView jsonValue)
Action & WithStatus(ActionStatus value)
Definition Action.h:188
const Aws::String & GetBudgetName() const
Definition Action.h:62
AWS_BUDGETS_API Action()=default
const Aws::String & GetExecutionRoleArn() const
Definition Action.h:148
bool ApprovalModelHasBeenSet() const
Definition Action.h:167
void SetBudgetName(BudgetNameT &&value)
Definition Action.h:65
NotificationType GetNotificationType() const
Definition Action.h:78
bool ExecutionRoleArnHasBeenSet() const
Definition Action.h:149
void SetActionId(ActionIdT &&value)
Definition Action.h:49
bool SubscribersHasBeenSet() const
Definition Action.h:197
Action & AddSubscribers(SubscribersT &&value)
Definition Action.h:209
bool ActionIdHasBeenSet() const
Definition Action.h:47
ActionStatus GetStatus() const
Definition Action.h:182
bool NotificationTypeHasBeenSet() const
Definition Action.h:79
Action & WithActionThreshold(ActionThresholdT &&value)
Definition Action.h:119
void SetApprovalModel(ApprovalModel value)
Definition Action.h:168
Action & WithNotificationType(NotificationType value)
Definition Action.h:84
Action & WithActionType(ActionType value)
Definition Action.h:101
Action & WithApprovalModel(ApprovalModel value)
Definition Action.h:172
void SetStatus(ActionStatus value)
Definition Action.h:184
const ActionThreshold & GetActionThreshold() const
Definition Action.h:111
void SetActionType(ActionType value)
Definition Action.h:97
Action & WithDefinition(DefinitionT &&value)
Definition Action.h:137
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue