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

Information about alarms associated with a deployment or deployment * group.

See Also:

AWS * API Reference

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

Indicates whether the alarm configuration is enabled.

*/ inline bool GetEnabled() const{ return m_enabled; } /** *

Indicates whether the alarm configuration is enabled.

*/ inline bool EnabledHasBeenSet() const { return m_enabledHasBeenSet; } /** *

Indicates whether the alarm configuration is enabled.

*/ inline void SetEnabled(bool value) { m_enabledHasBeenSet = true; m_enabled = value; } /** *

Indicates whether the alarm configuration is enabled.

*/ inline AlarmConfiguration& WithEnabled(bool value) { SetEnabled(value); return *this;} /** *

Indicates whether a deployment should continue if information about the * current state of alarms cannot be retrieved from Amazon CloudWatch. The default * value is false.

  • true: The deployment proceeds * even if alarm status information can't be retrieved from Amazon CloudWatch.

    *
  • false: The deployment stops if alarm status * information can't be retrieved from Amazon CloudWatch.

*/ inline bool GetIgnorePollAlarmFailure() const{ return m_ignorePollAlarmFailure; } /** *

Indicates whether a deployment should continue if information about the * current state of alarms cannot be retrieved from Amazon CloudWatch. The default * value is false.

  • true: The deployment proceeds * even if alarm status information can't be retrieved from Amazon CloudWatch.

    *
  • false: The deployment stops if alarm status * information can't be retrieved from Amazon CloudWatch.

*/ inline bool IgnorePollAlarmFailureHasBeenSet() const { return m_ignorePollAlarmFailureHasBeenSet; } /** *

Indicates whether a deployment should continue if information about the * current state of alarms cannot be retrieved from Amazon CloudWatch. The default * value is false.

  • true: The deployment proceeds * even if alarm status information can't be retrieved from Amazon CloudWatch.

    *
  • false: The deployment stops if alarm status * information can't be retrieved from Amazon CloudWatch.

*/ inline void SetIgnorePollAlarmFailure(bool value) { m_ignorePollAlarmFailureHasBeenSet = true; m_ignorePollAlarmFailure = value; } /** *

Indicates whether a deployment should continue if information about the * current state of alarms cannot be retrieved from Amazon CloudWatch. The default * value is false.

  • true: The deployment proceeds * even if alarm status information can't be retrieved from Amazon CloudWatch.

    *
  • false: The deployment stops if alarm status * information can't be retrieved from Amazon CloudWatch.

*/ inline AlarmConfiguration& WithIgnorePollAlarmFailure(bool value) { SetIgnorePollAlarmFailure(value); return *this;} /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline const Aws::Vector& GetAlarms() const{ return m_alarms; } /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline bool AlarmsHasBeenSet() const { return m_alarmsHasBeenSet; } /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline void SetAlarms(const Aws::Vector& value) { m_alarmsHasBeenSet = true; m_alarms = value; } /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline void SetAlarms(Aws::Vector&& value) { m_alarmsHasBeenSet = true; m_alarms = std::move(value); } /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline AlarmConfiguration& WithAlarms(const Aws::Vector& value) { SetAlarms(value); return *this;} /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline AlarmConfiguration& WithAlarms(Aws::Vector&& value) { SetAlarms(std::move(value)); return *this;} /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline AlarmConfiguration& AddAlarms(const Alarm& value) { m_alarmsHasBeenSet = true; m_alarms.push_back(value); return *this; } /** *

A list of alarms configured for the deployment or deployment group. A maximum * of 10 alarms can be added.

*/ inline AlarmConfiguration& AddAlarms(Alarm&& value) { m_alarmsHasBeenSet = true; m_alarms.push_back(std::move(value)); return *this; } private: bool m_enabled; bool m_enabledHasBeenSet = false; bool m_ignorePollAlarmFailure; bool m_ignorePollAlarmFailureHasBeenSet = false; Aws::Vector m_alarms; bool m_alarmsHasBeenSet = false; }; } // namespace Model } // namespace CodeDeploy } // namespace Aws