public class CompositeStepExecutionListener extends java.lang.Object implements StepExecutionListener
Constructor and Description |
---|
CompositeStepExecutionListener() |
Modifier and Type | Method and Description |
---|---|
ExitStatus |
afterStep(StepExecution stepExecution)
Call the registered listeners in reverse order, respecting and
prioritizing those that implement
Ordered . |
void |
beforeStep(StepExecution stepExecution)
Call the registered listeners in order, respecting and prioritizing those
that implement
Ordered . |
void |
register(StepExecutionListener stepExecutionListener)
Register additional listener.
|
void |
setListeners(StepExecutionListener[] listeners)
Public setter for the listeners.
|
public void setListeners(StepExecutionListener[] listeners)
listeners
- list of StepExecutionListener
s to be called when step execution events occur.public void register(StepExecutionListener stepExecutionListener)
stepExecutionListener
- instance of StepExecutionListener
to be registered.@Nullable public ExitStatus afterStep(StepExecution stepExecution)
Ordered
.afterStep
in interface StepExecutionListener
stepExecution
- StepExecution
instance.ExitStatus
to combine with the normal value. Return
null
to leave the old value unchanged.StepExecutionListener.afterStep(StepExecution)
public void beforeStep(StepExecution stepExecution)
Ordered
.beforeStep
in interface StepExecutionListener
stepExecution
- instance of StepExecution
.StepExecutionListener.beforeStep(StepExecution)