Interface StateConfigurer<S,E>
- Type Parameters:
S- the type of stateE- the type of event
- All Superinterfaces:
AnnotationConfigurerBuilder<StateMachineStateConfigurer<S,E>>
- All Known Implementing Classes:
DefaultStateConfigurer
public interface StateConfigurer<S,E>
extends AnnotationConfigurerBuilder<StateMachineStateConfigurer<S,E>>
Base
StateConfigurer interface for configuring States.- Author:
- Janne Valkealahti
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumEnumeration of a possible history pseudostate type. -
Method Summary
Modifier and TypeMethodDescriptionSpecify a stateSto be choice pseudo state.Specify a stateSto be end state.Specify a stateSto be entrypoint pseudo state.Specify a stateSto be exitpoint pseudo state.Specify a stateSto be fork pseudo state.history(S history, StateConfigurer.History type) Specify a stateSto be history pseudo state.Specify a initial stateS.Specify a initial stateSwith anActionto be executed with it.Specify a stateSto be join pseudo state.Specify a stateSto be junction pseudo state.Specify a states configured by this configurer instance to be substates of stateS.Specify a region for these states configured by this configurer instance.Specify a stateS.Specify a stateSwith a deferred eventsE.Specify a stateSwith stateActions.state(S state, Collection<? extends Action<S, E>> entryActions, Collection<? extends Action<S, E>> exitActions) Specify a stateSwith entry and exitActions.Specify a stateSwith stateAction.Specify a stateSwith entry and exitAction.state(S state, StateMachineFactory<S, E> stateMachineFactory) Specify a stateSand its relation with a given machine as substate machine factory.state(S state, StateMachine<S, E> stateMachine) Specify a stateSand its relation with a given machine as substate machine.Specify a stateSwith state behaviourAction.stateDoFunction(S state, Function<StateContext<S, E>, reactor.core.publisher.Mono<Void>> action) Specify a stateSwith state behaviourFunction.stateEntry(S state, Action<S, E> action) Specify a stateSwith state entryAction.stateEntryFunction(S state, Function<StateContext<S, E>, reactor.core.publisher.Mono<Void>> action) Specify a stateSwith state entryFunction.Specify a stateSwith state exitAction.stateExitFunction(S state, Function<StateContext<S, E>, reactor.core.publisher.Mono<Void>> action) Specify a stateSwith state exitFunction.Specify a statesS.Methods inherited from interface org.springframework.statemachine.config.common.annotation.AnnotationConfigurerBuilder
and
-
Method Details
-
initial
Specify a initial stateS.- Parameters:
initial- the initial state- Returns:
- configurer for chaining
-
initial
Specify a initial stateSwith anActionto be executed with it. Action can be i.e. used to init extended variables.- Parameters:
initial- the initial stateaction- the action- Returns:
- configurer for chaining
-
parent
Specify a states configured by this configurer instance to be substates of stateS.- Parameters:
state- the parent state- Returns:
- configurer for chaining
-
region
Specify a region for these states configured by this configurer instance.- Parameters:
id- the region id- Returns:
- configurer for chaining
-
state
Specify a stateS.- Parameters:
state- the state- Returns:
- configurer for chaining
-
state
Specify a stateSand its relation with a given machine as substate machine.- Parameters:
state- the statestateMachine- the submachine- Returns:
- configurer for chaining
-
state
Specify a stateSand its relation with a given machine as substate machine factory.- Parameters:
state- the statestateMachineFactory- the submachine factory- Returns:
- configurer for chaining
-
state
Specify a stateSwith stateActions.- Parameters:
state- the statestateActions- the state actions- Returns:
- configurer for chaining
-
state
Specify a stateSwith stateAction.- Parameters:
state- the statestateAction- the state action- Returns:
- configurer for chaining
-
stateDo
- Parameters:
state- the stateaction- the state action- Returns:
- configurer for chaining
- See Also:
-
stateDo
- Parameters:
state- the stateaction- the state actionerror- action that will be called if any unexpected exception is thrown by the action.- Returns:
- configurer for chaining
-
stateDoFunction
StateConfigurer<S,E> stateDoFunction(S state, Function<StateContext<S, E>, reactor.core.publisher.Mono<Void>> action) Specify a stateSwith state behaviourFunction.- Parameters:
state- the stateaction- the state action- Returns:
- configurer for chaining
-
stateEntryFunction
StateConfigurer<S,E> stateEntryFunction(S state, Function<StateContext<S, E>, reactor.core.publisher.Mono<Void>> action) Specify a stateSwith state entryFunction.- Parameters:
state- the stateaction- the state action- Returns:
- configurer for chaining
-
stateExitFunction
StateConfigurer<S,E> stateExitFunction(S state, Function<StateContext<S, E>, reactor.core.publisher.Mono<Void>> action) Specify a stateSwith state exitFunction.- Parameters:
state- the stateaction- the state action- Returns:
- configurer for chaining
-
state
StateConfigurer<S,E> state(S state, Collection<? extends Action<S, E>> entryActions, Collection<? extends Action<S, E>> exitActions) Specify a stateSwith entry and exitActions.- Parameters:
state- the stateentryActions- the state entry actionsexitActions- the state exit actions- Returns:
- configurer for chaining
-
state
Specify a stateSwith entry and exitAction.- Parameters:
state- the stateentryAction- the state entry actionexitAction- the state exit action- Returns:
- configurer for chaining
-
stateEntry
Specify a stateSwith state entryAction. Currently synonym forstate(Object, Action, Action)with no exit action.- Parameters:
state- the stateaction- the state entry action- Returns:
- configurer for chaining
- See Also:
-
stateEntry
Specify a stateSwith state entryActionand errorActioncallback. Currently synonym forstate(Object, Action, Action)with no exit action.- Parameters:
state- the stateaction- the state entry actionerror- action that will be called if any unexpected exception is thrown by the action.- Returns:
- configurer for chaining
- See Also:
-
stateExit
Specify a stateSwith state exitAction. Currently synonym forstate(Object, Action, Action)with no entry action.- Parameters:
state- the stateaction- the state exit action- Returns:
- configurer for chaining
- See Also:
-
stateExit
Specify a stateSwith state exitActionand errorActioncallback. Currently synonym forstate(Object, Action, Action)with no entry action.- Parameters:
state- the stateaction- the state entry actionerror- action that will be called if any unexpected exception is thrown by the action.- Returns:
- configurer for chaining
- See Also:
-
state
Specify a stateSwith a deferred eventsE.- Parameters:
state- the statedeferred- the deferred events- Returns:
- configurer for chaining
-
states
Specify a statesS.- Parameters:
states- the states- Returns:
- configurer for chaining
-
end
Specify a stateSto be end state. This method can be called for each state to be marked as end state.- Parameters:
end- the end state- Returns:
- configurer for chaining
-
choice
Specify a stateSto be choice pseudo state.- Parameters:
choice- the choice pseudo state- Returns:
- configurer for chaining
-
junction
Specify a stateSto be junction pseudo state.- Parameters:
junction- the junction pseudo state- Returns:
- configurer for chaining
-
fork
Specify a stateSto be fork pseudo state.- Parameters:
fork- the fork pseudo state- Returns:
- configurer for chaining
-
join
Specify a stateSto be join pseudo state.- Parameters:
join- the join pseudo state- Returns:
- configurer for chaining
-
history
Specify a stateSto be history pseudo state.- Parameters:
history- the history pseudo statetype- the history pseudo state type- Returns:
- configurer for chaining
-
entry
Specify a stateSto be entrypoint pseudo state.- Parameters:
entry- the entrypoint pseudo state- Returns:
- configurer for chaining
-
exit
Specify a stateSto be exitpoint pseudo state.- Parameters:
exit- the exitpoint pseudo state- Returns:
- configurer for chaining
-