Class: AWSCDK::ApplicationAutoScaling::CfnScalingPolicy::MetricDimensionProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
application_auto_scaling/cfn_scaling_policy.rb

Overview

MetricDimension specifies a name/value pair that is part of the identity of a CloudWatch metric for the Dimensions property of the AWS::ApplicationAutoScaling::ScalingPolicy CustomizedMetricSpecification property type. Duplicate dimensions are not allowed.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, value:) ⇒ MetricDimensionProperty

Returns a new instance of MetricDimensionProperty.

Parameters:

  • name (String)

    The name of the dimension.

  • value (String)

    The value of the dimension.



723
724
725
726
727
728
# File 'application_auto_scaling/cfn_scaling_policy.rb', line 723

def initialize(name:, value:)
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @value = value
  Jsii::Type.check_type(@value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "value")
end

Instance Attribute Details

#nameString (readonly)

The name of the dimension.



734
735
736
# File 'application_auto_scaling/cfn_scaling_policy.rb', line 734

def name
  @name
end

#valueString (readonly)

The value of the dimension.



739
740
741
# File 'application_auto_scaling/cfn_scaling_policy.rb', line 739

def value
  @value
end

Class Method Details

.jsii_propertiesObject



741
742
743
744
745
746
# File 'application_auto_scaling/cfn_scaling_policy.rb', line 741

def self.jsii_properties
  {
    :name => "name",
    :value => "value",
  }
end

Instance Method Details

#to_jsiiObject



748
749
750
751
752
753
754
755
# File 'application_auto_scaling/cfn_scaling_policy.rb', line 748

def to_jsii
  result = {}
  result.merge!({
    "name" => @name,
    "value" => @value,
  })
  result.compact
end