Module: AWSCDK::IPropertyInjector
- Defined in:
- i_property_injector.rb
Overview
This interface define an inject function that operates on a Construct's Property.
The Construct must have a constructUniqueId to uniquely identify itself.
Class Method Summary collapse
Instance Method Summary collapse
-
#construct_unique_id ⇒ String
The unique Id of the Construct class.
-
#inject(original_props, context) ⇒ Object
The injector to be applied to the constructor properties of the Construct.
Class Method Details
.jsii_overridable_methods ⇒ Object
28 29 30 31 32 33 |
# File 'i_property_injector.rb', line 28 def self.jsii_overridable_methods { :construct_unique_id => { kind: :property, name: "constructUniqueId", is_optional: false }, :inject => { kind: :method, name: "inject", is_optional: false }, } end |
Instance Method Details
#construct_unique_id ⇒ String
The unique Id of the Construct class.
12 13 14 |
# File 'i_property_injector.rb', line 12 def construct_unique_id() jsii_get_property("constructUniqueId") end |
#inject(original_props, context) ⇒ Object
The injector to be applied to the constructor properties of the Construct.
21 22 23 24 25 26 |
# File 'i_property_injector.rb', line 21 def inject(original_props, context) Jsii::Type.check_type(original_props, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "originalProps") context = context.is_a?(Hash) ? ::AWSCDK::InjectionContext.new(**context.transform_keys(&:to_sym)) : context Jsii::Type.check_type(context, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5JbmplY3Rpb25Db250ZXh0In0=")), "context") jsii_call_method("inject", [original_props, context]) end |