Class: AWSCDK::SSM::CommonStringParameterAttributes

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
ssm/common_string_parameter_attributes.rb

Overview

Common attributes for string parameters.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(parameter_name:, simple_name: nil) ⇒ CommonStringParameterAttributes

Returns a new instance of CommonStringParameterAttributes.

Parameters:

  • parameter_name (String)

    The name of the parameter store value.

  • simple_name (Boolean, nil) (defaults to: nil)

    Indicates whether the parameter name is a simple name.



9
10
11
12
13
14
# File 'ssm/common_string_parameter_attributes.rb', line 9

def initialize(parameter_name:, simple_name: nil)
  @parameter_name = parameter_name
  Jsii::Type.check_type(@parameter_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "parameterName")
  @simple_name = simple_name
  Jsii::Type.check_type(@simple_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "simpleName") unless @simple_name.nil?
end

Instance Attribute Details

#parameter_nameString (readonly)

The name of the parameter store value.

This value can be a token or a concrete string. If it is a concrete string and includes "/" it must also be prefixed with a "/" (fully-qualified).

Returns:

  • (String)


22
23
24
# File 'ssm/common_string_parameter_attributes.rb', line 22

def parameter_name
  @parameter_name
end

#simple_nameBoolean? (readonly)

Note:

Default: - auto-detect based on parameterName

Indicates whether the parameter name is a simple name.

A parameter name without any "/" is considered a simple name. If the parameter name includes "/", setting simpleName to true might cause unintended issues such as duplicate "/" in the resulting ARN.

This is required only if parameter_name is a token, which means we are unable to detect if the name is simple or "path-like" for the purpose of rendering SSM parameter ARNs.

If parameter_name is not specified, simple_name must be true (or undefined) since the name generated by AWS CloudFormation is always a simple name.

Returns:

  • (Boolean, nil)


40
41
42
# File 'ssm/common_string_parameter_attributes.rb', line 40

def simple_name
  @simple_name
end

Class Method Details

.jsii_propertiesObject



42
43
44
45
46
47
# File 'ssm/common_string_parameter_attributes.rb', line 42

def self.jsii_properties
  {
    :parameter_name => "parameterName",
    :simple_name => "simpleName",
  }
end

Instance Method Details

#to_jsiiObject



49
50
51
52
53
54
55
56
# File 'ssm/common_string_parameter_attributes.rb', line 49

def to_jsii
  result = {}
  result.merge!({
    "parameterName" => @parameter_name,
    "simpleName" => @simple_name,
  })
  result.compact
end