public class SplitState extends AbstractState implements FlowHolder
Constructor and Description |
---|
SplitState(Collection<Flow> flows,
String name) |
Modifier and Type | Method and Description |
---|---|
Collection<Flow> |
getFlows() |
FlowExecutionStatus |
handle(FlowExecutor executor)
Execute the flows in parallel by passing them to the
TaskExecutor
and wait for all of them to finish before proceeding. |
boolean |
isEndState()
Inquire as to whether a
State is an end state. |
void |
setTaskExecutor(org.springframework.core.task.TaskExecutor taskExecutor)
Public setter for the taskExecutor.
|
getName, toString
public SplitState(Collection<Flow> flows, String name)
name
- public void setTaskExecutor(org.springframework.core.task.TaskExecutor taskExecutor)
taskExecutor
- the taskExecutor to setpublic Collection<Flow> getFlows()
getFlows
in interface FlowHolder
public FlowExecutionStatus handle(FlowExecutor executor) throws Exception
TaskExecutor
and wait for all of them to finish before proceeding.handle
in interface State
handle
in class AbstractState
executor
- the context passed in by the callerException
- if anything goes wrongState.handle(FlowExecutor)
public boolean isEndState()
State
State
is an end state. Implementations
should return false if processing can continue, even if that would
require a restart.isEndState
in interface State
State
is the end of processingCopyright © 2014 Pivotal. All rights reserved.