@Generated(value="jsii-pacmak/1.74.0 (build 6d08790)", date="2023-03-22T19:35:43.487Z") public class Map extends State implements INextable
A Map
state can be used to run a set of steps for each element of an input array.
A Map state will execute the same steps for multiple entries of an array in the state input.
While the Parallel state executes multiple branches of steps using the same input, a Map state will execute the same steps for multiple entries of an array in the state input.
Example:
Map map = Map.Builder.create(this, "Map State") .maxConcurrency(1) .itemsPath(JsonPath.stringAt("$.inputForMap")) .build(); map.iterator(new Pass(this, "Pass State"));
Modifier and Type | Class and Description |
---|---|
static class |
Map.Builder
A fluent builder for
Map . |
INextable.Jsii$Default, INextable.Jsii$Proxy
IChainable.Jsii$Default
IConstruct.Jsii$Default
Modifier | Constructor and Description |
---|---|
protected |
Map(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Map(software.amazon.jsii.JsiiObjectRef objRef) |
|
Map(software.constructs.Construct scope,
java.lang.String id) |
|
Map(software.constructs.Construct scope,
java.lang.String id,
MapProps props) |
Modifier and Type | Method and Description |
---|---|
Map |
addCatch(IChainable handler)
Add a recovery handler for this state.
|
Map |
addCatch(IChainable handler,
CatchProps props)
Add a recovery handler for this state.
|
Map |
addRetry()
Add retry configuration for this state.
|
Map |
addRetry(RetryProps props)
Add retry configuration for this state.
|
java.util.List<INextable> |
getEndStates()
Continuable states of this Chainable.
|
Map |
iterator(IChainable iterator)
Define iterator state machine in Map.
|
Chain |
next(IChainable next)
Continue normal execution with the given state.
|
com.fasterxml.jackson.databind.node.ObjectNode |
toStateJson()
Return the Amazon States Language object for this state.
|
protected java.util.List<java.lang.String> |
validate()
Validate this state.
|
addBranch, addChoice, addIterator, addPrefix, bindToGraph, filterNextables, findReachableEndStates, findReachableEndStates, findReachableStates, findReachableStates, getBranches, getComment, getDefaultChoice, getId, getInputPath, getIteration, getOutputPath, getParameters, getResultPath, getResultSelector, getStartState, getStateId, makeDefault, makeNext, prefixStates, renderBranches, renderChoices, renderInputOutput, renderIterator, renderNextEnd, renderResultSelector, renderRetryCatch, setDefaultChoice, setIteration, whenBoundToGraph
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize
protected Map(software.amazon.jsii.JsiiObjectRef objRef)
protected Map(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
public Map(software.constructs.Construct scope, java.lang.String id, MapProps props)
scope
- This parameter is required.id
- This parameter is required.props
- public Map(software.constructs.Construct scope, java.lang.String id)
scope
- This parameter is required.id
- This parameter is required.public Map addCatch(IChainable handler, CatchProps props)
When a particular error occurs, execution will continue at the error handler instead of failing the state machine execution.
handler
- This parameter is required.props
- public Map addCatch(IChainable handler)
When a particular error occurs, execution will continue at the error handler instead of failing the state machine execution.
handler
- This parameter is required.public Map addRetry(RetryProps props)
This controls if and how the execution will be retried if a particular error occurs.
props
- public Map addRetry()
This controls if and how the execution will be retried if a particular error occurs.
public Map iterator(IChainable iterator)
iterator
- This parameter is required.public Chain next(IChainable next)
public com.fasterxml.jackson.databind.node.ObjectNode toStateJson()
toStateJson
in class State
protected java.util.List<java.lang.String> validate()
public java.util.List<INextable> getEndStates()
getEndStates
in interface IChainable
getEndStates
in class State