/**
* 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 SSM
{
namespace Model
{
/**
* The details for the CloudWatch alarm you want to apply to an automation or
* command.
See Also:
AWS
* API Reference
*/
class AlarmConfiguration
{
public:
AWS_SSM_API AlarmConfiguration();
AWS_SSM_API AlarmConfiguration(Aws::Utils::Json::JsonView jsonValue);
AWS_SSM_API AlarmConfiguration& operator=(Aws::Utils::Json::JsonView jsonValue);
AWS_SSM_API Aws::Utils::Json::JsonValue Jsonize() const;
///@{
/**
* When this value is true, your automation or command continues to run
* in cases where we can’t retrieve alarm status information from CloudWatch. In
* cases where we successfully retrieve an alarm status of OK or INSUFFICIENT_DATA,
* the automation or command continues to run, regardless of this value. Default is
* false.
*/
inline bool GetIgnorePollAlarmFailure() const{ return m_ignorePollAlarmFailure; }
inline bool IgnorePollAlarmFailureHasBeenSet() const { return m_ignorePollAlarmFailureHasBeenSet; }
inline void SetIgnorePollAlarmFailure(bool value) { m_ignorePollAlarmFailureHasBeenSet = true; m_ignorePollAlarmFailure = value; }
inline AlarmConfiguration& WithIgnorePollAlarmFailure(bool value) { SetIgnorePollAlarmFailure(value); return *this;}
///@}
///@{
/**
* The name of the CloudWatch alarm specified in the configuration.
*/
inline const Aws::Vector& GetAlarms() const{ return m_alarms; }
inline bool AlarmsHasBeenSet() const { return m_alarmsHasBeenSet; }
inline void SetAlarms(const Aws::Vector& value) { m_alarmsHasBeenSet = true; m_alarms = value; }
inline void SetAlarms(Aws::Vector&& value) { m_alarmsHasBeenSet = true; m_alarms = std::move(value); }
inline AlarmConfiguration& WithAlarms(const Aws::Vector& value) { SetAlarms(value); return *this;}
inline AlarmConfiguration& WithAlarms(Aws::Vector&& value) { SetAlarms(std::move(value)); return *this;}
inline AlarmConfiguration& AddAlarms(const Alarm& value) { m_alarmsHasBeenSet = true; m_alarms.push_back(value); return *this; }
inline AlarmConfiguration& AddAlarms(Alarm&& value) { m_alarmsHasBeenSet = true; m_alarms.push_back(std::move(value)); return *this; }
///@}
private:
bool m_ignorePollAlarmFailure;
bool m_ignorePollAlarmFailureHasBeenSet = false;
Aws::Vector m_alarms;
bool m_alarmsHasBeenSet = false;
};
} // namespace Model
} // namespace SSM
} // namespace Aws