/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace Budgets { namespace Model { /** *

A budget action resource.

See Also:

AWS API * Reference

*/ class Action { public: AWS_BUDGETS_API Action(); AWS_BUDGETS_API Action(Aws::Utils::Json::JsonView jsonValue); AWS_BUDGETS_API Action& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_BUDGETS_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline const Aws::String& GetActionId() const{ return m_actionId; } /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline bool ActionIdHasBeenSet() const { return m_actionIdHasBeenSet; } /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline void SetActionId(const Aws::String& value) { m_actionIdHasBeenSet = true; m_actionId = value; } /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline void SetActionId(Aws::String&& value) { m_actionIdHasBeenSet = true; m_actionId = std::move(value); } /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline void SetActionId(const char* value) { m_actionIdHasBeenSet = true; m_actionId.assign(value); } /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline Action& WithActionId(const Aws::String& value) { SetActionId(value); return *this;} /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline Action& WithActionId(Aws::String&& value) { SetActionId(std::move(value)); return *this;} /** *

A system-generated universally unique identifier (UUID) for the action.

*/ inline Action& WithActionId(const char* value) { SetActionId(value); return *this;} inline const Aws::String& GetBudgetName() const{ return m_budgetName; } inline bool BudgetNameHasBeenSet() const { return m_budgetNameHasBeenSet; } inline void SetBudgetName(const Aws::String& value) { m_budgetNameHasBeenSet = true; m_budgetName = value; } inline void SetBudgetName(Aws::String&& value) { m_budgetNameHasBeenSet = true; m_budgetName = std::move(value); } inline void SetBudgetName(const char* value) { m_budgetNameHasBeenSet = true; m_budgetName.assign(value); } inline Action& WithBudgetName(const Aws::String& value) { SetBudgetName(value); return *this;} inline Action& WithBudgetName(Aws::String&& value) { SetBudgetName(std::move(value)); return *this;} inline Action& WithBudgetName(const char* value) { SetBudgetName(value); return *this;} inline const NotificationType& GetNotificationType() const{ return m_notificationType; } inline bool NotificationTypeHasBeenSet() const { return m_notificationTypeHasBeenSet; } inline void SetNotificationType(const NotificationType& value) { m_notificationTypeHasBeenSet = true; m_notificationType = value; } inline void SetNotificationType(NotificationType&& value) { m_notificationTypeHasBeenSet = true; m_notificationType = std::move(value); } inline Action& WithNotificationType(const NotificationType& value) { SetNotificationType(value); return *this;} inline Action& WithNotificationType(NotificationType&& value) { SetNotificationType(std::move(value)); return *this;} /** *

The type of action. This defines the type of tasks that can be carried out by * this action. This field also determines the format for definition.

*/ inline const ActionType& GetActionType() const{ return m_actionType; } /** *

The type of action. This defines the type of tasks that can be carried out by * this action. This field also determines the format for definition.

*/ inline bool ActionTypeHasBeenSet() const { return m_actionTypeHasBeenSet; } /** *

The type of action. This defines the type of tasks that can be carried out by * this action. This field also determines the format for definition.

*/ inline void SetActionType(const ActionType& value) { m_actionTypeHasBeenSet = true; m_actionType = value; } /** *

The type of action. This defines the type of tasks that can be carried out by * this action. This field also determines the format for definition.

*/ inline void SetActionType(ActionType&& value) { m_actionTypeHasBeenSet = true; m_actionType = std::move(value); } /** *

The type of action. This defines the type of tasks that can be carried out by * this action. This field also determines the format for definition.

*/ inline Action& WithActionType(const ActionType& value) { SetActionType(value); return *this;} /** *

The type of action. This defines the type of tasks that can be carried out by * this action. This field also determines the format for definition.

*/ inline Action& WithActionType(ActionType&& value) { SetActionType(std::move(value)); return *this;} /** *

The trigger threshold of the action.

*/ inline const ActionThreshold& GetActionThreshold() const{ return m_actionThreshold; } /** *

The trigger threshold of the action.

*/ inline bool ActionThresholdHasBeenSet() const { return m_actionThresholdHasBeenSet; } /** *

The trigger threshold of the action.

*/ inline void SetActionThreshold(const ActionThreshold& value) { m_actionThresholdHasBeenSet = true; m_actionThreshold = value; } /** *

The trigger threshold of the action.

*/ inline void SetActionThreshold(ActionThreshold&& value) { m_actionThresholdHasBeenSet = true; m_actionThreshold = std::move(value); } /** *

The trigger threshold of the action.

*/ inline Action& WithActionThreshold(const ActionThreshold& value) { SetActionThreshold(value); return *this;} /** *

The trigger threshold of the action.

*/ inline Action& WithActionThreshold(ActionThreshold&& value) { SetActionThreshold(std::move(value)); return *this;} /** *

Where you specify all of the type-specific parameters.

*/ inline const Definition& GetDefinition() const{ return m_definition; } /** *

Where you specify all of the type-specific parameters.

*/ inline bool DefinitionHasBeenSet() const { return m_definitionHasBeenSet; } /** *

Where you specify all of the type-specific parameters.

*/ inline void SetDefinition(const Definition& value) { m_definitionHasBeenSet = true; m_definition = value; } /** *

Where you specify all of the type-specific parameters.

*/ inline void SetDefinition(Definition&& value) { m_definitionHasBeenSet = true; m_definition = std::move(value); } /** *

Where you specify all of the type-specific parameters.

*/ inline Action& WithDefinition(const Definition& value) { SetDefinition(value); return *this;} /** *

Where you specify all of the type-specific parameters.

*/ inline Action& WithDefinition(Definition&& value) { SetDefinition(std::move(value)); return *this;} /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline const Aws::String& GetExecutionRoleArn() const{ return m_executionRoleArn; } /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline bool ExecutionRoleArnHasBeenSet() const { return m_executionRoleArnHasBeenSet; } /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline void SetExecutionRoleArn(const Aws::String& value) { m_executionRoleArnHasBeenSet = true; m_executionRoleArn = value; } /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline void SetExecutionRoleArn(Aws::String&& value) { m_executionRoleArnHasBeenSet = true; m_executionRoleArn = std::move(value); } /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline void SetExecutionRoleArn(const char* value) { m_executionRoleArnHasBeenSet = true; m_executionRoleArn.assign(value); } /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline Action& WithExecutionRoleArn(const Aws::String& value) { SetExecutionRoleArn(value); return *this;} /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline Action& WithExecutionRoleArn(Aws::String&& value) { SetExecutionRoleArn(std::move(value)); return *this;} /** *

The role passed for action execution and reversion. Roles and actions must be * in the same account.

*/ inline Action& WithExecutionRoleArn(const char* value) { SetExecutionRoleArn(value); return *this;} /** *

This specifies if the action needs manual or automatic approval.

*/ inline const ApprovalModel& GetApprovalModel() const{ return m_approvalModel; } /** *

This specifies if the action needs manual or automatic approval.

*/ inline bool ApprovalModelHasBeenSet() const { return m_approvalModelHasBeenSet; } /** *

This specifies if the action needs manual or automatic approval.

*/ inline void SetApprovalModel(const ApprovalModel& value) { m_approvalModelHasBeenSet = true; m_approvalModel = value; } /** *

This specifies if the action needs manual or automatic approval.

*/ inline void SetApprovalModel(ApprovalModel&& value) { m_approvalModelHasBeenSet = true; m_approvalModel = std::move(value); } /** *

This specifies if the action needs manual or automatic approval.

*/ inline Action& WithApprovalModel(const ApprovalModel& value) { SetApprovalModel(value); return *this;} /** *

This specifies if the action needs manual or automatic approval.

*/ inline Action& WithApprovalModel(ApprovalModel&& value) { SetApprovalModel(std::move(value)); return *this;} /** *

The status of the action.

*/ inline const ActionStatus& GetStatus() const{ return m_status; } /** *

The status of the action.

*/ inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } /** *

The status of the action.

*/ inline void SetStatus(const ActionStatus& value) { m_statusHasBeenSet = true; m_status = value; } /** *

The status of the action.

*/ inline void SetStatus(ActionStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } /** *

The status of the action.

*/ inline Action& WithStatus(const ActionStatus& value) { SetStatus(value); return *this;} /** *

The status of the action.

*/ inline Action& WithStatus(ActionStatus&& value) { SetStatus(std::move(value)); return *this;} inline const Aws::Vector& GetSubscribers() const{ return m_subscribers; } inline bool SubscribersHasBeenSet() const { return m_subscribersHasBeenSet; } inline void SetSubscribers(const Aws::Vector& value) { m_subscribersHasBeenSet = true; m_subscribers = value; } inline void SetSubscribers(Aws::Vector&& value) { m_subscribersHasBeenSet = true; m_subscribers = std::move(value); } inline Action& WithSubscribers(const Aws::Vector& value) { SetSubscribers(value); return *this;} inline Action& WithSubscribers(Aws::Vector&& value) { SetSubscribers(std::move(value)); return *this;} inline Action& AddSubscribers(const Subscriber& value) { m_subscribersHasBeenSet = true; m_subscribers.push_back(value); return *this; } inline Action& AddSubscribers(Subscriber&& value) { m_subscribersHasBeenSet = true; m_subscribers.push_back(std::move(value)); return *this; } private: Aws::String m_actionId; bool m_actionIdHasBeenSet = false; Aws::String m_budgetName; bool m_budgetNameHasBeenSet = false; NotificationType m_notificationType; bool m_notificationTypeHasBeenSet = false; ActionType m_actionType; bool m_actionTypeHasBeenSet = false; ActionThreshold m_actionThreshold; bool m_actionThresholdHasBeenSet = false; Definition m_definition; bool m_definitionHasBeenSet = false; Aws::String m_executionRoleArn; bool m_executionRoleArnHasBeenSet = false; ApprovalModel m_approvalModel; bool m_approvalModelHasBeenSet = false; ActionStatus m_status; bool m_statusHasBeenSet = false; Aws::Vector m_subscribers; bool m_subscribersHasBeenSet = false; }; } // namespace Model } // namespace Budgets } // namespace Aws