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

Contains the notification settings of an alarm model. The settings apply to * all alarms that were created based on this alarm model.

See Also:

* AWS * API Reference

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

Specifies an AWS Lambda function to manage alarm notifications. You can * create one or use the AWS * Lambda function provided by AWS IoT Events.

*/ inline const NotificationTargetActions& GetAction() const{ return m_action; } /** *

Specifies an AWS Lambda function to manage alarm notifications. You can * create one or use the AWS * Lambda function provided by AWS IoT Events.

*/ inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; } /** *

Specifies an AWS Lambda function to manage alarm notifications. You can * create one or use the AWS * Lambda function provided by AWS IoT Events.

*/ inline void SetAction(const NotificationTargetActions& value) { m_actionHasBeenSet = true; m_action = value; } /** *

Specifies an AWS Lambda function to manage alarm notifications. You can * create one or use the AWS * Lambda function provided by AWS IoT Events.

*/ inline void SetAction(NotificationTargetActions&& value) { m_actionHasBeenSet = true; m_action = std::move(value); } /** *

Specifies an AWS Lambda function to manage alarm notifications. You can * create one or use the AWS * Lambda function provided by AWS IoT Events.

*/ inline NotificationAction& WithAction(const NotificationTargetActions& value) { SetAction(value); return *this;} /** *

Specifies an AWS Lambda function to manage alarm notifications. You can * create one or use the AWS * Lambda function provided by AWS IoT Events.

*/ inline NotificationAction& WithAction(NotificationTargetActions&& value) { SetAction(std::move(value)); return *this;} /** *

Contains the configuration information of SMS notifications.

*/ inline const Aws::Vector& GetSmsConfigurations() const{ return m_smsConfigurations; } /** *

Contains the configuration information of SMS notifications.

*/ inline bool SmsConfigurationsHasBeenSet() const { return m_smsConfigurationsHasBeenSet; } /** *

Contains the configuration information of SMS notifications.

*/ inline void SetSmsConfigurations(const Aws::Vector& value) { m_smsConfigurationsHasBeenSet = true; m_smsConfigurations = value; } /** *

Contains the configuration information of SMS notifications.

*/ inline void SetSmsConfigurations(Aws::Vector&& value) { m_smsConfigurationsHasBeenSet = true; m_smsConfigurations = std::move(value); } /** *

Contains the configuration information of SMS notifications.

*/ inline NotificationAction& WithSmsConfigurations(const Aws::Vector& value) { SetSmsConfigurations(value); return *this;} /** *

Contains the configuration information of SMS notifications.

*/ inline NotificationAction& WithSmsConfigurations(Aws::Vector&& value) { SetSmsConfigurations(std::move(value)); return *this;} /** *

Contains the configuration information of SMS notifications.

*/ inline NotificationAction& AddSmsConfigurations(const SMSConfiguration& value) { m_smsConfigurationsHasBeenSet = true; m_smsConfigurations.push_back(value); return *this; } /** *

Contains the configuration information of SMS notifications.

*/ inline NotificationAction& AddSmsConfigurations(SMSConfiguration&& value) { m_smsConfigurationsHasBeenSet = true; m_smsConfigurations.push_back(std::move(value)); return *this; } /** *

Contains the configuration information of email notifications.

*/ inline const Aws::Vector& GetEmailConfigurations() const{ return m_emailConfigurations; } /** *

Contains the configuration information of email notifications.

*/ inline bool EmailConfigurationsHasBeenSet() const { return m_emailConfigurationsHasBeenSet; } /** *

Contains the configuration information of email notifications.

*/ inline void SetEmailConfigurations(const Aws::Vector& value) { m_emailConfigurationsHasBeenSet = true; m_emailConfigurations = value; } /** *

Contains the configuration information of email notifications.

*/ inline void SetEmailConfigurations(Aws::Vector&& value) { m_emailConfigurationsHasBeenSet = true; m_emailConfigurations = std::move(value); } /** *

Contains the configuration information of email notifications.

*/ inline NotificationAction& WithEmailConfigurations(const Aws::Vector& value) { SetEmailConfigurations(value); return *this;} /** *

Contains the configuration information of email notifications.

*/ inline NotificationAction& WithEmailConfigurations(Aws::Vector&& value) { SetEmailConfigurations(std::move(value)); return *this;} /** *

Contains the configuration information of email notifications.

*/ inline NotificationAction& AddEmailConfigurations(const EmailConfiguration& value) { m_emailConfigurationsHasBeenSet = true; m_emailConfigurations.push_back(value); return *this; } /** *

Contains the configuration information of email notifications.

*/ inline NotificationAction& AddEmailConfigurations(EmailConfiguration&& value) { m_emailConfigurationsHasBeenSet = true; m_emailConfigurations.push_back(std::move(value)); return *this; } private: NotificationTargetActions m_action; bool m_actionHasBeenSet = false; Aws::Vector m_smsConfigurations; bool m_smsConfigurationsHasBeenSet = false; Aws::Vector m_emailConfigurations; bool m_emailConfigurationsHasBeenSet = false; }; } // namespace Model } // namespace IoTEvents } // namespace Aws