@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:39.313Z") @Stability(value=Stable) public abstract class RuleTargetInput extends software.amazon.jsii.JsiiObject
Example:
import software.amazon.awscdk.services.iam.*;
import software.amazon.awscdk.services.stepfunctions.*;
Rule rule = Rule.Builder.create(this, "Rule")
.schedule(Schedule.rate(Duration.minutes(1)))
.build();
Queue dlq = new Queue(this, "DeadLetterQueue");
Role role = Role.Builder.create(this, "Role")
.assumedBy(new ServicePrincipal("events.amazonaws.com"))
.build();
StateMachine stateMachine = StateMachine.Builder.create(this, "SM")
.definition(Wait.Builder.create(this, "Hello").time(WaitTime.duration(Duration.seconds(10))).build())
.build();
rule.addTarget(SfnStateMachine.Builder.create(stateMachine)
.input(RuleTargetInput.fromObject(Map.of("SomeParam", "SomeValue")))
.deadLetterQueue(dlq)
.role(role)
.build());
| Modifier | Constructor and Description |
|---|---|
protected |
RuleTargetInput() |
protected |
RuleTargetInput(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
RuleTargetInput(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
abstract RuleTargetInputProperties |
bind(IRule rule)
Return the input properties for this input object.
|
static RuleTargetInput |
fromEventPath(String path)
Take the event target input from a path in the event JSON.
|
static RuleTargetInput |
fromMultilineText(String text)
Pass text to the event target, splitting on newlines.
|
static RuleTargetInput |
fromObject(Object obj)
Pass a JSON object to the event target.
|
static RuleTargetInput |
fromText(String text)
Pass text to the event target.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected RuleTargetInput(software.amazon.jsii.JsiiObjectRef objRef)
protected RuleTargetInput(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable) protected RuleTargetInput()
@Stability(value=Stable) @NotNull public static RuleTargetInput fromEventPath(@NotNull String path)
path - This parameter is required.@Stability(value=Stable) @NotNull public static RuleTargetInput fromMultilineText(@NotNull String text)
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.
text - This parameter is required.@Stability(value=Stable) @NotNull public static RuleTargetInput fromObject(@NotNull Object obj)
May contain strings returned by EventField.from() to substitute in parts of the
matched event.
obj - This parameter is required.@Stability(value=Stable) @NotNull public static RuleTargetInput fromText(@NotNull String text)
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.
text - This parameter is required.@Stability(value=Stable) @NotNull public abstract RuleTargetInputProperties bind(@NotNull IRule rule)
rule - This parameter is required.Copyright © 2022. All rights reserved.