Class: AWSCDK::CloudWatch::SpacerProps

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

Overview

Props of the spacer.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(height: nil, width: nil) ⇒ SpacerProps

Returns a new instance of SpacerProps.

Parameters:

  • height (Numeric, nil) (defaults to: nil)

    Height of the spacer.

  • width (Numeric, nil) (defaults to: nil)

    Width of the spacer.



9
10
11
12
13
14
# File 'cloud_watch/spacer_props.rb', line 9

def initialize(height: nil, width: nil)
  @height = height
  Jsii::Type.check_type(@height, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "height") unless @height.nil?
  @width = width
  Jsii::Type.check_type(@width, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "width") unless @width.nil?
end

Instance Attribute Details

#heightNumeric? (readonly)

Note:

Default: : 1

Height of the spacer.

Returns:

  • (Numeric, nil)


20
21
22
# File 'cloud_watch/spacer_props.rb', line 20

def height
  @height
end

#widthNumeric? (readonly)

Note:

Default: 1

Width of the spacer.

Returns:

  • (Numeric, nil)


25
26
27
# File 'cloud_watch/spacer_props.rb', line 25

def width
  @width
end

Class Method Details

.jsii_propertiesObject



27
28
29
30
31
32
# File 'cloud_watch/spacer_props.rb', line 27

def self.jsii_properties
  {
    :height => "height",
    :width => "width",
  }
end

Instance Method Details

#to_jsiiObject



34
35
36
37
38
39
40
41
# File 'cloud_watch/spacer_props.rb', line 34

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