Class: AWSCDK::Events::RuleTargetInput
- Inherits:
-
Jsii::Object
- Object
- Jsii::Object
- AWSCDK::Events::RuleTargetInput
- Defined in:
- events/rule_target_input.rb
Overview
The input to send to the event target.
Direct Known Subclasses
Class Method Summary collapse
-
.from_event_path(path) ⇒ AWSCDK::Events::RuleTargetInput
Take the event target input from a path in the event JSON.
-
.from_multiline_text(text) ⇒ AWSCDK::Events::RuleTargetInput
Pass text to the event target, splitting on newlines.
-
.from_object(obj) ⇒ AWSCDK::Events::RuleTargetInput
Pass a JSON object to the event target.
-
.from_text(text) ⇒ AWSCDK::Events::RuleTargetInput
Pass text to the event target.
- .jsii_overridable_methods ⇒ Object
Instance Method Summary collapse
-
#bind(rule) ⇒ AWSCDK::Events::RuleTargetInputProperties
Return the input properties for this input object.
-
#initialize ⇒ RuleTargetInput
constructor
A new instance of RuleTargetInput.
Constructor Details
#initialize ⇒ RuleTargetInput
Returns a new instance of RuleTargetInput.
8 9 10 |
# File 'events/rule_target_input.rb', line 8 def initialize Jsii::Object.instance_method(:initialize).bind(self).call end |
Class Method Details
.from_event_path(path) ⇒ AWSCDK::Events::RuleTargetInput
Take the event target input from a path in the event JSON.
22 23 24 25 |
# File 'events/rule_target_input.rb', line 22 def self.from_event_path(path) Jsii::Type.check_type(path, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "path") Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_events.RuleTargetInput", "fromEventPath", [path]) end |
.from_multiline_text(text) ⇒ AWSCDK::Events::RuleTargetInput
Pass text to the event target, splitting on newlines.
This is only useful when passing to a target that does not take a single argument.
May contain strings returned by EventField.from() to substitute in parts
of the matched event.
37 38 39 40 |
# File 'events/rule_target_input.rb', line 37 def self.from_multiline_text(text) Jsii::Type.check_type(text, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "text") Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_events.RuleTargetInput", "fromMultilineText", [text]) end |
.from_object(obj) ⇒ AWSCDK::Events::RuleTargetInput
Pass a JSON object to the event target.
May contain strings returned by EventField.from() to substitute in parts of the
matched event.
49 50 51 52 |
# File 'events/rule_target_input.rb', line 49 def self.from_object(obj) Jsii::Type.check_type(obj, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "obj") Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_events.RuleTargetInput", "fromObject", [obj]) end |
.from_text(text) ⇒ AWSCDK::Events::RuleTargetInput
Pass text to the event target.
May contain strings returned by EventField.from() to substitute in parts of the
matched event.
The Rule Target input value will be a single string: the string you pass
here. Do not use this method to pass a complex value like a JSON object to
a Rule Target. Use RuleTargetInput.fromObject() instead.
65 66 67 68 |
# File 'events/rule_target_input.rb', line 65 def self.from_text(text) Jsii::Type.check_type(text, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "text") Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_events.RuleTargetInput", "fromText", [text]) end |
.jsii_overridable_methods ⇒ Object
12 13 14 15 16 |
# File 'events/rule_target_input.rb', line 12 def self.jsii_overridable_methods { :bind => { kind: :method, name: "bind", is_optional: false }, } end |
Instance Method Details
#bind(rule) ⇒ AWSCDK::Events::RuleTargetInputProperties
Return the input properties for this input object.
74 75 76 77 |
# File 'events/rule_target_input.rb', line 74 def bind(rule) Jsii::Type.check_type(rule, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19ldmVudHMuSVJ1bGVSZWYifQ==")), "rule") jsii_call_method("bind", [rule]) end |