@Generated(value="jsii-pacmak/1.24.0 (build b722f66)", date="2021-03-11T13:46:42.594Z") @Stability(value=Stable) public class StateGraph extends software.amazon.jsii.JsiiObject
A StateGraph is used to keep track of all states that are connected (have transitions between them). It does not include the substatemachines in a Parallel's branches: those are their own StateGraphs, but the graphs themselves have a hierarchical relationship as well.
By assigning states to a definitive StateGraph, we verify that no state machines are constructed. In particular:
All policy statements in all states in all substatemachines are bubbled so that the top-level StateMachine instantiation can read them all and add them to the IAM Role.
You do not need to instantiate this class; it is used internally.
| Modifier | Constructor and Description |
|---|---|
protected |
StateGraph(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
StateGraph(software.amazon.jsii.JsiiObjectRef objRef) |
|
StateGraph(State startState,
String graphDescription) |
| Modifier and Type | Method and Description |
|---|---|
List<PolicyStatement> |
getPolicyStatements()
The accumulated policy statements.
|
State |
getStartState()
state that gets executed when the state machine is launched.
|
Duration |
getTimeout()
Set a timeout to render into the graph JSON.
|
void |
registerPolicyStatement(PolicyStatement statement)
Register a Policy Statement used by states in this graph.
|
void |
registerState(State state)
Register a state as part of this graph.
|
void |
registerSuperGraph(StateGraph graph)
Register this graph as a child of the given graph.
|
void |
setTimeout(Duration value)
Set a timeout to render into the graph JSON.
|
com.fasterxml.jackson.databind.node.ObjectNode |
toGraphJson()
Return the Amazon States Language JSON for this graph.
|
String |
toString()
Return a string description of this graph.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected StateGraph(software.amazon.jsii.JsiiObjectRef objRef)
protected StateGraph(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public StateGraph(@NotNull
State startState,
@NotNull
String graphDescription)
startState - state that gets executed when the state machine is launched. This parameter is required.graphDescription - description of the state machine. This parameter is required.@Stability(value=Stable)
public void registerPolicyStatement(@NotNull
PolicyStatement statement)
statement - This parameter is required.@Stability(value=Stable)
public void registerState(@NotNull
State state)
Called by State.bindToGraph().
state - This parameter is required.@Stability(value=Stable)
public void registerSuperGraph(@NotNull
StateGraph graph)
Resource changes will be bubbled up to the given graph.
graph - This parameter is required.@Stability(value=Stable) @NotNull public com.fasterxml.jackson.databind.node.ObjectNode toGraphJson()
@Stability(value=Stable) @NotNull public String toString()
@Stability(value=Stable) @NotNull public List<PolicyStatement> getPolicyStatements()
@Stability(value=Stable) @NotNull public State getStartState()
@Stability(value=Stable) @Nullable public Duration getTimeout()
Read/write. Only makes sense on the top-level graph, subgraphs do not support this feature.
Default: No timeout
@Stability(value=Stable)
public void setTimeout(@Nullable
Duration value)
Read/write. Only makes sense on the top-level graph, subgraphs do not support this feature.
Default: No timeout
Copyright © 2021. All rights reserved.