Class: AWSCDK::Lambda::CfnParametersCodeProps

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

Overview

Construction properties for CfnParametersCode.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(bucket_name_param: nil, object_key_param: nil, source_kms_key: nil) ⇒ CfnParametersCodeProps

Returns a new instance of CfnParametersCodeProps.

Parameters:

  • bucket_name_param (AWSCDK::CfnParameter, nil) (defaults to: nil)

    The CloudFormation parameter that represents the name of the S3 Bucket where the Lambda code will be located in.

  • object_key_param (AWSCDK::CfnParameter, nil) (defaults to: nil)

    The CloudFormation parameter that represents the path inside the S3 Bucket where the Lambda code will be located at.

  • source_kms_key (AWSCDK::Interfaces::AWSKMS::IKeyRef, nil) (defaults to: nil)

    The ARN of the KMS key used to encrypt the handler code.



10
11
12
13
14
15
16
17
# File 'lambda/cfn_parameters_code_props.rb', line 10

def initialize(bucket_name_param: nil, object_key_param: nil, source_kms_key: nil)
  @bucket_name_param = bucket_name_param
  Jsii::Type.check_type(@bucket_name_param, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5DZm5QYXJhbWV0ZXIifQ==")), "bucketNameParam") unless @bucket_name_param.nil?
  @object_key_param = object_key_param
  Jsii::Type.check_type(@object_key_param, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5DZm5QYXJhbWV0ZXIifQ==")), "objectKeyParam") unless @object_key_param.nil?
  @source_kms_key = source_kms_key
  Jsii::Type.check_type(@source_kms_key, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19rbXMuSUtleVJlZiJ9")), "sourceKMSKey") unless @source_kms_key.nil?
end

Instance Attribute Details

#bucket_name_paramAWSCDK::CfnParameter? (readonly)

Note:

Default: a new parameter will be created

The CloudFormation parameter that represents the name of the S3 Bucket where the Lambda code will be located in.

Must be of type 'String'.

Returns:



25
26
27
# File 'lambda/cfn_parameters_code_props.rb', line 25

def bucket_name_param
  @bucket_name_param
end

#object_key_paramAWSCDK::CfnParameter? (readonly)

Note:

Default: a new parameter will be created

The CloudFormation parameter that represents the path inside the S3 Bucket where the Lambda code will be located at.

Must be of type 'String'.

Returns:



32
33
34
# File 'lambda/cfn_parameters_code_props.rb', line 32

def object_key_param
  @object_key_param
end

#source_kms_keyAWSCDK::Interfaces::AWSKMS::IKeyRef? (readonly)

Note:

Default: - the default server-side encryption with Amazon S3 managed keys(SSE-S3) key will be used.

The ARN of the KMS key used to encrypt the handler code.



37
38
39
# File 'lambda/cfn_parameters_code_props.rb', line 37

def source_kms_key
  @source_kms_key
end

Class Method Details

.jsii_propertiesObject



39
40
41
42
43
44
45
# File 'lambda/cfn_parameters_code_props.rb', line 39

def self.jsii_properties
  {
    :bucket_name_param => "bucketNameParam",
    :object_key_param => "objectKeyParam",
    :source_kms_key => "sourceKMSKey",
  }
end

Instance Method Details

#to_jsiiObject



47
48
49
50
51
52
53
54
55
# File 'lambda/cfn_parameters_code_props.rb', line 47

def to_jsii
  result = {}
  result.merge!({
    "bucketNameParam" => @bucket_name_param,
    "objectKeyParam" => @object_key_param,
    "sourceKMSKey" => @source_kms_key,
  })
  result.compact
end