Class: AWSCDK::SAM::CfnFunction::DeploymentPreferenceProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SAM::CfnFunction::DeploymentPreferenceProperty
- Defined in:
- sam/cfn_function.rb
Overview
Instance Attribute Summary collapse
- #alarms ⇒ Array<String>? readonly
- #enabled ⇒ Boolean, ... readonly
- #hooks ⇒ AWSCDK::IResolvable, ... readonly
- #role ⇒ String? readonly
- #type ⇒ String? readonly
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(alarms: nil, enabled: nil, hooks: nil, role: nil, type: nil) ⇒ DeploymentPreferenceProperty
constructor
A new instance of DeploymentPreferenceProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(alarms: nil, enabled: nil, hooks: nil, role: nil, type: nil) ⇒ DeploymentPreferenceProperty
Returns a new instance of DeploymentPreferenceProperty.
1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 |
# File 'sam/cfn_function.rb', line 1428 def initialize(alarms: nil, enabled: nil, hooks: nil, role: nil, type: nil) @alarms = alarms Jsii::Type.check_type(@alarms, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "alarms") unless @alarms.nil? @enabled = enabled Jsii::Type.check_type(@enabled, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "enabled") unless @enabled.nil? @hooks = hooks.is_a?(Hash) ? ::AWSCDK::SAM::CfnFunction::HooksProperty.new(**hooks.transform_keys(&:to_sym)) : hooks Jsii::Type.check_type(@hooks, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19zYW0uQ2ZuRnVuY3Rpb24uSG9va3NQcm9wZXJ0eSJ9XX19")), "hooks") unless @hooks.nil? @role = role Jsii::Type.check_type(@role, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "role") unless @role.nil? @type = type Jsii::Type.check_type(@type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "type") unless @type.nil? end |
Instance Attribute Details
#alarms ⇒ Array<String>? (readonly)
1443 1444 1445 |
# File 'sam/cfn_function.rb', line 1443 def alarms @alarms end |
#enabled ⇒ Boolean, ... (readonly)
1446 1447 1448 |
# File 'sam/cfn_function.rb', line 1446 def enabled @enabled end |
#hooks ⇒ AWSCDK::IResolvable, ... (readonly)
1449 1450 1451 |
# File 'sam/cfn_function.rb', line 1449 def hooks @hooks end |
#role ⇒ String? (readonly)
1452 1453 1454 |
# File 'sam/cfn_function.rb', line 1452 def role @role end |
#type ⇒ String? (readonly)
1455 1456 1457 |
# File 'sam/cfn_function.rb', line 1455 def type @type end |
Class Method Details
.jsii_properties ⇒ Object
1457 1458 1459 1460 1461 1462 1463 1464 1465 |
# File 'sam/cfn_function.rb', line 1457 def self.jsii_properties { :alarms => "alarms", :enabled => "enabled", :hooks => "hooks", :role => "role", :type => "type", } end |
Instance Method Details
#to_jsii ⇒ Object
1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 |
# File 'sam/cfn_function.rb', line 1467 def to_jsii result = {} result.merge!({ "alarms" => @alarms, "enabled" => @enabled, "hooks" => @hooks, "role" => @role, "type" => @type, }) result.compact end |