Class: AWSCDK::LookoutMetrics::CfnAnomalyDetector::MetricProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::LookoutMetrics::CfnAnomalyDetector::MetricProperty
- Defined in:
- lookout_metrics/cfn_anomaly_detector.rb
Overview
A calculation made by contrasting a measure and a dimension from your source data.
Instance Attribute Summary collapse
-
#aggregation_function ⇒ String
readonly
The function with which the metric is calculated.
-
#metric_name ⇒ String
readonly
The name of the metric.
-
#namespace ⇒ String?
readonly
The namespace for the metric.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(aggregation_function:, metric_name:, namespace: nil) ⇒ MetricProperty
constructor
A new instance of MetricProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(aggregation_function:, metric_name:, namespace: nil) ⇒ MetricProperty
Returns a new instance of MetricProperty.
846 847 848 849 850 851 852 853 |
# File 'lookout_metrics/cfn_anomaly_detector.rb', line 846 def initialize(aggregation_function:, metric_name:, namespace: nil) @aggregation_function = aggregation_function Jsii::Type.check_type(@aggregation_function, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "aggregationFunction") @metric_name = metric_name Jsii::Type.check_type(@metric_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "metricName") @namespace = namespace Jsii::Type.check_type(@namespace, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "namespace") unless @namespace.nil? end |
Instance Attribute Details
#aggregation_function ⇒ String (readonly)
The function with which the metric is calculated.
859 860 861 |
# File 'lookout_metrics/cfn_anomaly_detector.rb', line 859 def aggregation_function @aggregation_function end |
#metric_name ⇒ String (readonly)
The name of the metric.
864 865 866 |
# File 'lookout_metrics/cfn_anomaly_detector.rb', line 864 def metric_name @metric_name end |
#namespace ⇒ String? (readonly)
The namespace for the metric.
869 870 871 |
# File 'lookout_metrics/cfn_anomaly_detector.rb', line 869 def namespace @namespace end |
Class Method Details
.jsii_properties ⇒ Object
871 872 873 874 875 876 877 |
# File 'lookout_metrics/cfn_anomaly_detector.rb', line 871 def self.jsii_properties { :aggregation_function => "aggregationFunction", :metric_name => "metricName", :namespace => "namespace", } end |
Instance Method Details
#to_jsii ⇒ Object
879 880 881 882 883 884 885 886 887 |
# File 'lookout_metrics/cfn_anomaly_detector.rb', line 879 def to_jsii result = {} result.merge!({ "aggregationFunction" => @aggregation_function, "metricName" => @metric_name, "namespace" => @namespace, }) result.compact end |