Class: AWSCDK::CloudWatch::CfnMetricStream::MetricStreamStatisticsMetricProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
cloud_watch/cfn_metric_stream.rb

Overview

A structure that specifies the metric name and namespace for one metric that is going to have additional statistics included in the stream.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(metric_name:, namespace:) ⇒ MetricStreamStatisticsMetricProperty

Returns a new instance of MetricStreamStatisticsMetricProperty.

Parameters:

  • metric_name (String)

    The name of the metric.

  • namespace (String)

    The namespace of the metric.



782
783
784
785
786
787
# File 'cloud_watch/cfn_metric_stream.rb', line 782

def initialize(metric_name:, namespace:)
  @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")
end

Instance Attribute Details

#metric_nameString (readonly)

The name of the metric.



793
794
795
# File 'cloud_watch/cfn_metric_stream.rb', line 793

def metric_name
  @metric_name
end

#namespaceString (readonly)

The namespace of the metric.



798
799
800
# File 'cloud_watch/cfn_metric_stream.rb', line 798

def namespace
  @namespace
end

Class Method Details

.jsii_propertiesObject



800
801
802
803
804
805
# File 'cloud_watch/cfn_metric_stream.rb', line 800

def self.jsii_properties
  {
    :metric_name => "metricName",
    :namespace => "namespace",
  }
end

Instance Method Details

#to_jsiiObject



807
808
809
810
811
812
813
814
# File 'cloud_watch/cfn_metric_stream.rb', line 807

def to_jsii
  result = {}
  result.merge!({
    "metricName" => @metric_name,
    "namespace" => @namespace,
  })
  result.compact
end