Class: AWSCDK::ECS::CfnTaskDefinition::KeyValuePairProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
ecs/cfn_task_definition.rb

Overview

A key-value pair object.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name: nil, value: nil) ⇒ KeyValuePairProperty

Returns a new instance of KeyValuePairProperty.

Parameters:

  • name (String, nil) (defaults to: nil)

    The name of the key-value pair.

  • value (String, nil) (defaults to: nil)

    The value of the key-value pair.



2297
2298
2299
2300
2301
2302
# File 'ecs/cfn_task_definition.rb', line 2297

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

Instance Attribute Details

#nameString? (readonly)

The name of the key-value pair.

For environment variables, this is the name of the environment variable.



2310
2311
2312
# File 'ecs/cfn_task_definition.rb', line 2310

def name
  @name
end

#valueString? (readonly)

The value of the key-value pair.

For environment variables, this is the value of the environment variable.



2317
2318
2319
# File 'ecs/cfn_task_definition.rb', line 2317

def value
  @value
end

Class Method Details

.jsii_propertiesObject



2319
2320
2321
2322
2323
2324
# File 'ecs/cfn_task_definition.rb', line 2319

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

Instance Method Details

#to_jsiiObject



2326
2327
2328
2329
2330
2331
2332
2333
# File 'ecs/cfn_task_definition.rb', line 2326

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