Interface IEvaluateExpressionProps
Properties for EvaluateExpression.
Inherited Members
Namespace: Amazon.CDK.AWS.StepFunctions.Tasks
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface IEvaluateExpressionProps : ITaskStateBaseProps
Syntax (vb)
Public Interface IEvaluateExpressionProps
Inherits ITaskStateBaseProps
Remarks
ExampleMetadata: infused
Examples
var convertToSeconds = new EvaluateExpression(this, "Convert to seconds", new EvaluateExpressionProps {
Expression = "$.waitMilliseconds / 1000",
ResultPath = "$.waitSeconds"
});
var createMessage = new EvaluateExpression(this, "Create message", new EvaluateExpressionProps {
// Note: this is a string inside a string.
Expression = "`Now waiting ${$.waitSeconds} seconds...`",
Runtime = Runtime.NODEJS_LATEST,
ResultPath = "$.message"
});
var publishMessage = new SnsPublish(this, "Publish message", new SnsPublishProps {
Topic = new Topic(this, "cool-topic"),
Message = TaskInput.FromJsonPathAt("$.message"),
ResultPath = "$.sns"
});
var wait = new Wait(this, "Wait", new WaitProps {
Time = WaitTime.SecondsPath("$.waitSeconds")
});
new StateMachine(this, "StateMachine", new StateMachineProps {
Definition = convertToSeconds.Next(createMessage).Next(publishMessage).Next(wait)
});
Synopsis
Properties
Expression | The expression to evaluate. The expression may contain state paths. |
Runtime | The runtime language to use to evaluate the expression. |
Properties
Expression
The expression to evaluate. The expression may contain state paths.
string Expression { get; }
Property Value
System.String
Remarks
Example value: '$.a + $.b'
Runtime
The runtime language to use to evaluate the expression.
virtual Runtime Runtime { get; }
Property Value
Remarks
Default: lambda.Runtime.NODEJS_18_X