Class: AWSCDK::Lambda::CfnLayerVersionProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
lambda/cfn_layer_version_props.rb

Overview

Properties for defining a CfnLayerVersion.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(content:, compatible_architectures: nil, compatible_runtimes: nil, description: nil, layer_name: nil, license_info: nil) ⇒ CfnLayerVersionProps

Returns a new instance of CfnLayerVersionProps.

Parameters:



15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'lambda/cfn_layer_version_props.rb', line 15

def initialize(content:, compatible_architectures: nil, compatible_runtimes: nil, description: nil, layer_name: nil, license_info: nil)
  @content = content.is_a?(Hash) ? ::AWSCDK::Lambda::CfnLayerVersion::ContentProperty.new(**content.transform_keys(&:to_sym)) : content
  Jsii::Type.check_type(@content, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19sYW1iZGEuQ2ZuTGF5ZXJWZXJzaW9uLkNvbnRlbnRQcm9wZXJ0eSJ9XX19")), "content")
  @compatible_architectures = compatible_architectures
  Jsii::Type.check_type(@compatible_architectures, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "compatibleArchitectures") unless @compatible_architectures.nil?
  @compatible_runtimes = compatible_runtimes
  Jsii::Type.check_type(@compatible_runtimes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "compatibleRuntimes") unless @compatible_runtimes.nil?
  @description = description
  Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil?
  @layer_name = layer_name
  Jsii::Type.check_type(@layer_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "layerName") unless @layer_name.nil?
  @license_info = license_info
  Jsii::Type.check_type(@license_info, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "licenseInfo") unless @license_info.nil?
end

Instance Attribute Details

#compatible_architecturesArray<String>? (readonly)

A list of compatible instruction set architectures .



39
40
41
# File 'lambda/cfn_layer_version_props.rb', line 39

def compatible_architectures
  @compatible_architectures
end

#compatible_runtimesArray<String>? (readonly)

A list of compatible function runtimes . Used for filtering with ListLayers and ListLayerVersions .



44
45
46
# File 'lambda/cfn_layer_version_props.rb', line 44

def compatible_runtimes
  @compatible_runtimes
end

#descriptionString? (readonly)

The description of the version.



49
50
51
# File 'lambda/cfn_layer_version_props.rb', line 49

def description
  @description
end

#layer_nameString? (readonly)

The name or Amazon Resource Name (ARN) of the layer.



54
55
56
# File 'lambda/cfn_layer_version_props.rb', line 54

def layer_name
  @layer_name
end

#license_infoString? (readonly)

The layer's software license. It can be any of the following:.

  • An SPDX license identifier . For example, MIT .
  • The URL of a license hosted on the internet. For example, https://opensource.org/licenses/MIT .
  • The full text of the license.


63
64
65
# File 'lambda/cfn_layer_version_props.rb', line 63

def license_info
  @license_info
end

Class Method Details

.jsii_propertiesObject



65
66
67
68
69
70
71
72
73
74
# File 'lambda/cfn_layer_version_props.rb', line 65

def self.jsii_properties
  {
    :content => "content",
    :compatible_architectures => "compatibleArchitectures",
    :compatible_runtimes => "compatibleRuntimes",
    :description => "description",
    :layer_name => "layerName",
    :license_info => "licenseInfo",
  }
end

Instance Method Details

#to_jsiiObject



76
77
78
79
80
81
82
83
84
85
86
87
# File 'lambda/cfn_layer_version_props.rb', line 76

def to_jsii
  result = {}
  result.merge!({
    "content" => @content,
    "compatibleArchitectures" => @compatible_architectures,
    "compatibleRuntimes" => @compatible_runtimes,
    "description" => @description,
    "layerName" => @layer_name,
    "licenseInfo" => @license_info,
  })
  result.compact
end