7#include <aws/monitoring/CloudWatch_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/DateTime.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <aws/monitoring/model/StateValue.h>
13#include <aws/monitoring/model/Statistic.h>
14#include <aws/monitoring/model/StandardUnit.h>
15#include <aws/monitoring/model/ComparisonOperator.h>
16#include <aws/monitoring/model/EvaluationState.h>
17#include <aws/monitoring/model/Dimension.h>
18#include <aws/monitoring/model/MetricDataQuery.h>
57 template<
typename AlarmNameT = Aws::String>
58 void SetAlarmName(AlarmNameT&& value) { m_alarmNameHasBeenSet =
true; m_alarmName = std::forward<AlarmNameT>(value); }
59 template<
typename AlarmNameT = Aws::String>
69 template<
typename AlarmArnT = Aws::String>
70 void SetAlarmArn(AlarmArnT&& value) { m_alarmArnHasBeenSet =
true; m_alarmArn = std::forward<AlarmArnT>(value); }
71 template<
typename AlarmArnT = Aws::String>
81 template<
typename AlarmDescriptionT = Aws::String>
82 void SetAlarmDescription(AlarmDescriptionT&& value) { m_alarmDescriptionHasBeenSet =
true; m_alarmDescription = std::forward<AlarmDescriptionT>(value); }
83 template<
typename AlarmDescriptionT = Aws::String>
93 template<
typename AlarmConfigurationUpdatedTimestampT = Aws::Utils::DateTime>
94 void SetAlarmConfigurationUpdatedTimestamp(AlarmConfigurationUpdatedTimestampT&& value) { m_alarmConfigurationUpdatedTimestampHasBeenSet =
true; m_alarmConfigurationUpdatedTimestamp = std::forward<AlarmConfigurationUpdatedTimestampT>(value); }
95 template<
typename AlarmConfigurationUpdatedTimestampT = Aws::Utils::DateTime>
106 inline void SetActionsEnabled(
bool value) { m_actionsEnabledHasBeenSet =
true; m_actionsEnabled = value; }
118 template<
typename OKActionsT = Aws::Vector<Aws::String>>
119 void SetOKActions(OKActionsT&& value) { m_oKActionsHasBeenSet =
true; m_oKActions = std::forward<OKActionsT>(value); }
120 template<
typename OKActionsT = Aws::Vector<Aws::String>>
122 template<
typename OKActionsT = Aws::String>
123 MetricAlarm&
AddOKActions(OKActionsT&& value) { m_oKActionsHasBeenSet =
true; m_oKActions.emplace_back(std::forward<OKActionsT>(value));
return *
this; }
134 template<
typename AlarmActionsT = Aws::Vector<Aws::String>>
135 void SetAlarmActions(AlarmActionsT&& value) { m_alarmActionsHasBeenSet =
true; m_alarmActions = std::forward<AlarmActionsT>(value); }
136 template<
typename AlarmActionsT = Aws::Vector<Aws::String>>
138 template<
typename AlarmActionsT = Aws::String>
139 MetricAlarm&
AddAlarmActions(AlarmActionsT&& value) { m_alarmActionsHasBeenSet =
true; m_alarmActions.emplace_back(std::forward<AlarmActionsT>(value));
return *
this; }
150 template<
typename InsufficientDataActionsT = Aws::Vector<Aws::String>>
151 void SetInsufficientDataActions(InsufficientDataActionsT&& value) { m_insufficientDataActionsHasBeenSet =
true; m_insufficientDataActions = std::forward<InsufficientDataActionsT>(value); }
152 template<
typename InsufficientDataActionsT = Aws::Vector<Aws::String>>
154 template<
typename InsufficientDataActionsT = Aws::String>
155 MetricAlarm&
AddInsufficientDataActions(InsufficientDataActionsT&& value) { m_insufficientDataActionsHasBeenSet =
true; m_insufficientDataActions.emplace_back(std::forward<InsufficientDataActionsT>(value));
return *
this; }
174 template<
typename StateReasonT = Aws::String>
175 void SetStateReason(StateReasonT&& value) { m_stateReasonHasBeenSet =
true; m_stateReason = std::forward<StateReasonT>(value); }
176 template<
typename StateReasonT = Aws::String>
186 template<
typename StateReasonDataT = Aws::String>
187 void SetStateReasonData(StateReasonDataT&& value) { m_stateReasonDataHasBeenSet =
true; m_stateReasonData = std::forward<StateReasonDataT>(value); }
188 template<
typename StateReasonDataT = Aws::String>
199 template<
typename StateUpdatedTimestampT = Aws::Utils::DateTime>
200 void SetStateUpdatedTimestamp(StateUpdatedTimestampT&& value) { m_stateUpdatedTimestampHasBeenSet =
true; m_stateUpdatedTimestamp = std::forward<StateUpdatedTimestampT>(value); }
201 template<
typename StateUpdatedTimestampT = Aws::Utils::DateTime>
212 template<
typename MetricNameT = Aws::String>
213 void SetMetricName(MetricNameT&& value) { m_metricNameHasBeenSet =
true; m_metricName = std::forward<MetricNameT>(value); }
214 template<
typename MetricNameT = Aws::String>
224 template<
typename NamespaceT = Aws::String>
225 void SetNamespace(NamespaceT&& value) { m_namespaceHasBeenSet =
true; m_namespace = std::forward<NamespaceT>(value); }
226 template<
typename NamespaceT = Aws::String>
248 template<
typename ExtendedStatisticT = Aws::String>
249 void SetExtendedStatistic(ExtendedStatisticT&& value) { m_extendedStatisticHasBeenSet =
true; m_extendedStatistic = std::forward<ExtendedStatisticT>(value); }
250 template<
typename ExtendedStatisticT = Aws::String>
260 template<
typename DimensionsT = Aws::Vector<Dimension>>
261 void SetDimensions(DimensionsT&& value) { m_dimensionsHasBeenSet =
true; m_dimensions = std::forward<DimensionsT>(value); }
262 template<
typename DimensionsT = Aws::Vector<Dimension>>
264 template<
typename DimensionsT = Dimension>
265 MetricAlarm&
AddDimensions(DimensionsT&& value) { m_dimensionsHasBeenSet =
true; m_dimensions.emplace_back(std::forward<DimensionsT>(value));
return *
this; }
274 inline void SetPeriod(
int value) { m_periodHasBeenSet =
true; m_period = value; }
295 inline void SetEvaluationPeriods(
int value) { m_evaluationPeriodsHasBeenSet =
true; m_evaluationPeriods = value; }
305 inline void SetDatapointsToAlarm(
int value) { m_datapointsToAlarmHasBeenSet =
true; m_datapointsToAlarm = value; }
315 inline void SetThreshold(
double value) { m_thresholdHasBeenSet =
true; m_threshold = value; }
341 template<
typename TreatMissingDataT = Aws::String>
342 void SetTreatMissingData(TreatMissingDataT&& value) { m_treatMissingDataHasBeenSet =
true; m_treatMissingData = std::forward<TreatMissingDataT>(value); }
343 template<
typename TreatMissingDataT = Aws::String>
357 template<
typename EvaluateLowSampleCountPercentileT = Aws::String>
358 void SetEvaluateLowSampleCountPercentile(EvaluateLowSampleCountPercentileT&& value) { m_evaluateLowSampleCountPercentileHasBeenSet =
true; m_evaluateLowSampleCountPercentile = std::forward<EvaluateLowSampleCountPercentileT>(value); }
359 template<
typename EvaluateLowSampleCountPercentileT = Aws::String>
373 template<
typename MetricsT = Aws::Vector<MetricDataQuery>>
374 void SetMetrics(MetricsT&& value) { m_metricsHasBeenSet =
true; m_metrics = std::forward<MetricsT>(value); }
375 template<
typename MetricsT = Aws::Vector<MetricDataQuery>>
377 template<
typename MetricsT = MetricDataQuery>
378 MetricAlarm&
AddMetrics(MetricsT&& value) { m_metricsHasBeenSet =
true; m_metrics.emplace_back(std::forward<MetricsT>(value));
return *
this; }
389 template<
typename ThresholdMetricIdT = Aws::String>
390 void SetThresholdMetricId(ThresholdMetricIdT&& value) { m_thresholdMetricIdHasBeenSet =
true; m_thresholdMetricId = std::forward<ThresholdMetricIdT>(value); }
391 template<
typename ThresholdMetricIdT = Aws::String>
416 template<
typename StateTransitionedTimestampT = Aws::Utils::DateTime>
417 void SetStateTransitionedTimestamp(StateTransitionedTimestampT&& value) { m_stateTransitionedTimestampHasBeenSet =
true; m_stateTransitionedTimestamp = std::forward<StateTransitionedTimestampT>(value); }
418 template<
typename StateTransitionedTimestampT = Aws::Utils::DateTime>
424 bool m_alarmNameHasBeenSet =
false;
427 bool m_alarmArnHasBeenSet =
false;
430 bool m_alarmDescriptionHasBeenSet =
false;
433 bool m_alarmConfigurationUpdatedTimestampHasBeenSet =
false;
435 bool m_actionsEnabled{
false};
436 bool m_actionsEnabledHasBeenSet =
false;
439 bool m_oKActionsHasBeenSet =
false;
442 bool m_alarmActionsHasBeenSet =
false;
445 bool m_insufficientDataActionsHasBeenSet =
false;
448 bool m_stateValueHasBeenSet =
false;
451 bool m_stateReasonHasBeenSet =
false;
454 bool m_stateReasonDataHasBeenSet =
false;
457 bool m_stateUpdatedTimestampHasBeenSet =
false;
460 bool m_metricNameHasBeenSet =
false;
463 bool m_namespaceHasBeenSet =
false;
466 bool m_statisticHasBeenSet =
false;
469 bool m_extendedStatisticHasBeenSet =
false;
472 bool m_dimensionsHasBeenSet =
false;
475 bool m_periodHasBeenSet =
false;
478 bool m_unitHasBeenSet =
false;
480 int m_evaluationPeriods{0};
481 bool m_evaluationPeriodsHasBeenSet =
false;
483 int m_datapointsToAlarm{0};
484 bool m_datapointsToAlarmHasBeenSet =
false;
486 double m_threshold{0.0};
487 bool m_thresholdHasBeenSet =
false;
490 bool m_comparisonOperatorHasBeenSet =
false;
493 bool m_treatMissingDataHasBeenSet =
false;
496 bool m_evaluateLowSampleCountPercentileHasBeenSet =
false;
499 bool m_metricsHasBeenSet =
false;
502 bool m_thresholdMetricIdHasBeenSet =
false;
505 bool m_evaluationStateHasBeenSet =
false;
508 bool m_stateTransitionedTimestampHasBeenSet =
false;
bool MetricNameHasBeenSet() const
AWS_CLOUDWATCH_API MetricAlarm(const Aws::Utils::Xml::XmlNode &xmlNode)
bool ThresholdMetricIdHasBeenSet() const
EvaluationState GetEvaluationState() const
bool StateReasonHasBeenSet() const
MetricAlarm & WithEvaluateLowSampleCountPercentile(EvaluateLowSampleCountPercentileT &&value)
void SetTreatMissingData(TreatMissingDataT &&value)
bool EvaluationPeriodsHasBeenSet() const
bool ActionsEnabledHasBeenSet() const
AWS_CLOUDWATCH_API MetricAlarm & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
const Aws::String & GetStateReasonData() const
void SetAlarmName(AlarmNameT &&value)
void SetEvaluateLowSampleCountPercentile(EvaluateLowSampleCountPercentileT &&value)
void SetActionsEnabled(bool value)
void SetNamespace(NamespaceT &&value)
MetricAlarm & WithStateValue(StateValue value)
void SetDatapointsToAlarm(int value)
void SetAlarmArn(AlarmArnT &&value)
const Aws::Vector< Aws::String > & GetOKActions() const
MetricAlarm & WithDimensions(DimensionsT &&value)
MetricAlarm & WithThreshold(double value)
MetricAlarm & WithOKActions(OKActionsT &&value)
bool ComparisonOperatorHasBeenSet() const
bool StateValueHasBeenSet() const
const Aws::Vector< Aws::String > & GetInsufficientDataActions() const
MetricAlarm & WithComparisonOperator(ComparisonOperator value)
MetricAlarm & WithTreatMissingData(TreatMissingDataT &&value)
const Aws::String & GetNamespace() const
double GetThreshold() const
int GetDatapointsToAlarm() const
AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
const Aws::String & GetMetricName() const
MetricAlarm & WithExtendedStatistic(ExtendedStatisticT &&value)
ComparisonOperator GetComparisonOperator() const
bool AlarmDescriptionHasBeenSet() const
bool NamespaceHasBeenSet() const
void SetPeriod(int value)
MetricAlarm & WithEvaluationState(EvaluationState value)
void SetDimensions(DimensionsT &&value)
void SetStateTransitionedTimestamp(StateTransitionedTimestampT &&value)
MetricAlarm & WithAlarmActions(AlarmActionsT &&value)
void SetExtendedStatistic(ExtendedStatisticT &&value)
MetricAlarm & AddOKActions(OKActionsT &&value)
MetricAlarm & WithStateReason(StateReasonT &&value)
MetricAlarm & WithAlarmDescription(AlarmDescriptionT &&value)
void SetInsufficientDataActions(InsufficientDataActionsT &&value)
const Aws::String & GetThresholdMetricId() const
bool StateReasonDataHasBeenSet() const
void SetMetrics(MetricsT &&value)
bool OKActionsHasBeenSet() const
const Aws::String & GetStateReason() const
AWS_CLOUDWATCH_API MetricAlarm()=default
bool AlarmNameHasBeenSet() const
bool DatapointsToAlarmHasBeenSet() const
MetricAlarm & WithEvaluationPeriods(int value)
bool AlarmArnHasBeenSet() const
void SetMetricName(MetricNameT &&value)
MetricAlarm & WithMetrics(MetricsT &&value)
const Aws::Utils::DateTime & GetStateTransitionedTimestamp() const
MetricAlarm & WithDatapointsToAlarm(int value)
const Aws::Utils::DateTime & GetAlarmConfigurationUpdatedTimestamp() const
bool EvaluationStateHasBeenSet() const
bool AlarmConfigurationUpdatedTimestampHasBeenSet() const
bool EvaluateLowSampleCountPercentileHasBeenSet() const
const Aws::String & GetTreatMissingData() const
MetricAlarm & AddMetrics(MetricsT &&value)
bool AlarmActionsHasBeenSet() const
void SetAlarmConfigurationUpdatedTimestamp(AlarmConfigurationUpdatedTimestampT &&value)
bool UnitHasBeenSet() const
bool GetActionsEnabled() const
MetricAlarm & WithAlarmConfigurationUpdatedTimestamp(AlarmConfigurationUpdatedTimestampT &&value)
MetricAlarm & WithPeriod(int value)
MetricAlarm & WithInsufficientDataActions(InsufficientDataActionsT &&value)
void SetThreshold(double value)
int GetEvaluationPeriods() const
void SetComparisonOperator(ComparisonOperator value)
StateValue GetStateValue() const
bool StatisticHasBeenSet() const
void SetAlarmDescription(AlarmDescriptionT &&value)
const Aws::Vector< Dimension > & GetDimensions() const
const Aws::String & GetAlarmArn() const
const Aws::Vector< MetricDataQuery > & GetMetrics() const
void SetStateReasonData(StateReasonDataT &&value)
void SetUnit(StandardUnit value)
MetricAlarm & AddDimensions(DimensionsT &&value)
void SetEvaluationPeriods(int value)
bool TreatMissingDataHasBeenSet() const
MetricAlarm & WithAlarmName(AlarmNameT &&value)
const Aws::String & GetExtendedStatistic() const
void SetStateReason(StateReasonT &&value)
Statistic GetStatistic() const
void SetEvaluationState(EvaluationState value)
const Aws::Vector< Aws::String > & GetAlarmActions() const
bool PeriodHasBeenSet() const
void SetStateUpdatedTimestamp(StateUpdatedTimestampT &&value)
MetricAlarm & WithThresholdMetricId(ThresholdMetricIdT &&value)
const Aws::String & GetAlarmDescription() const
MetricAlarm & WithActionsEnabled(bool value)
bool ExtendedStatisticHasBeenSet() const
MetricAlarm & WithUnit(StandardUnit value)
bool DimensionsHasBeenSet() const
bool MetricsHasBeenSet() const
MetricAlarm & WithMetricName(MetricNameT &&value)
MetricAlarm & WithStateTransitionedTimestamp(StateTransitionedTimestampT &&value)
MetricAlarm & AddAlarmActions(AlarmActionsT &&value)
bool ThresholdHasBeenSet() const
bool InsufficientDataActionsHasBeenSet() const
void SetOKActions(OKActionsT &&value)
AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream &oStream, const char *location) const
MetricAlarm & WithStatistic(Statistic value)
const Aws::Utils::DateTime & GetStateUpdatedTimestamp() const
const Aws::String & GetEvaluateLowSampleCountPercentile() const
const Aws::String & GetAlarmName() const
MetricAlarm & WithStateReasonData(StateReasonDataT &&value)
MetricAlarm & WithAlarmArn(AlarmArnT &&value)
void SetStatistic(Statistic value)
bool StateUpdatedTimestampHasBeenSet() const
void SetThresholdMetricId(ThresholdMetricIdT &&value)
void SetAlarmActions(AlarmActionsT &&value)
StandardUnit GetUnit() const
bool StateTransitionedTimestampHasBeenSet() const
MetricAlarm & WithStateUpdatedTimestamp(StateUpdatedTimestampT &&value)
MetricAlarm & AddInsufficientDataActions(InsufficientDataActionsT &&value)
void SetStateValue(StateValue value)
MetricAlarm & WithNamespace(NamespaceT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
std::basic_ostream< char, std::char_traits< char > > OStream