/** * 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 Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace CloudWatch { namespace Model { /** *

The configuration specifies details about how the anomaly detection model is * to be trained, including time ranges to exclude from use for training the model * and the time zone to use for the metric.

See Also:

AWS * API Reference

*/ class AnomalyDetectorConfiguration { public: AWS_CLOUDWATCH_API AnomalyDetectorConfiguration(); AWS_CLOUDWATCH_API AnomalyDetectorConfiguration(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_CLOUDWATCH_API AnomalyDetectorConfiguration& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_CLOUDWATCH_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline const Aws::Vector& GetExcludedTimeRanges() const{ return m_excludedTimeRanges; } /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline bool ExcludedTimeRangesHasBeenSet() const { return m_excludedTimeRangesHasBeenSet; } /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline void SetExcludedTimeRanges(const Aws::Vector& value) { m_excludedTimeRangesHasBeenSet = true; m_excludedTimeRanges = value; } /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline void SetExcludedTimeRanges(Aws::Vector&& value) { m_excludedTimeRangesHasBeenSet = true; m_excludedTimeRanges = std::move(value); } /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline AnomalyDetectorConfiguration& WithExcludedTimeRanges(const Aws::Vector& value) { SetExcludedTimeRanges(value); return *this;} /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline AnomalyDetectorConfiguration& WithExcludedTimeRanges(Aws::Vector&& value) { SetExcludedTimeRanges(std::move(value)); return *this;} /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline AnomalyDetectorConfiguration& AddExcludedTimeRanges(const Range& value) { m_excludedTimeRangesHasBeenSet = true; m_excludedTimeRanges.push_back(value); return *this; } /** *

An array of time ranges to exclude from use when the anomaly detection model * is trained. Use this to make sure that events that could cause unusual values * for the metric, such as deployments, aren't used when CloudWatch creates the * model.

*/ inline AnomalyDetectorConfiguration& AddExcludedTimeRanges(Range&& value) { m_excludedTimeRangesHasBeenSet = true; m_excludedTimeRanges.push_back(std::move(value)); return *this; } /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline const Aws::String& GetMetricTimezone() const{ return m_metricTimezone; } /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline bool MetricTimezoneHasBeenSet() const { return m_metricTimezoneHasBeenSet; } /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline void SetMetricTimezone(const Aws::String& value) { m_metricTimezoneHasBeenSet = true; m_metricTimezone = value; } /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline void SetMetricTimezone(Aws::String&& value) { m_metricTimezoneHasBeenSet = true; m_metricTimezone = std::move(value); } /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline void SetMetricTimezone(const char* value) { m_metricTimezoneHasBeenSet = true; m_metricTimezone.assign(value); } /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline AnomalyDetectorConfiguration& WithMetricTimezone(const Aws::String& value) { SetMetricTimezone(value); return *this;} /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline AnomalyDetectorConfiguration& WithMetricTimezone(Aws::String&& value) { SetMetricTimezone(std::move(value)); return *this;} /** *

The time zone to use for the metric. This is useful to enable the model to * automatically account for daylight savings time changes if the metric is * sensitive to such time changes.

To specify a time zone, use the name of * the time zone as specified in the standard tz database. For more information, * see tz database.

*/ inline AnomalyDetectorConfiguration& WithMetricTimezone(const char* value) { SetMetricTimezone(value); return *this;} private: Aws::Vector m_excludedTimeRanges; bool m_excludedTimeRangesHasBeenSet = false; Aws::String m_metricTimezone; bool m_metricTimezoneHasBeenSet = false; }; } // namespace Model } // namespace CloudWatch } // namespace Aws