Package org.springframework.cloud.task.batch.listener

# Class EventEmittingStepExecutionListener

java.lang.Object
org.springframework.cloud.task.batch.listener.EventEmittingStepExecutionListener

All Implemented Interfaces:
  `org.springframework.batch.core.StepExecutionListener`, `org.springframework.batch.core.StepListener`, `org.springframework.core.Ordered`

public class EventEmittingStepExecutionListener extends Object implements org.springframework.batch.core.StepExecutionListener, org.springframework.core.Ordered
Provides a `StepExecutionEvent` at the start and end of each step indicating the step's status. The `StepExecutionListener.afterStep(StepExecution)` returns the `ExitStatus` of the inputted `StepExecution`.

Author:
  Michael Minella, Glenn Renfro, Ali Shahbour

- ## Field Summary

  ### Fields inherited from interface org.springframework.core.Ordered

  `HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `EventEmittingStepExecutionListener(MessagePublisher messagePublisher, int order, TaskEventProperties properties)`
  `EventEmittingStepExecutionListener(MessagePublisher messagePublisher, TaskEventProperties properties)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `org.springframework.batch.core.ExitStatus`
  `afterStep(org.springframework.batch.core.StepExecution stepExecution)`
  `void`
  `beforeStep(org.springframework.batch.core.StepExecution stepExecution)`
  `int`
  `getOrder()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### EventEmittingStepExecutionListener

    public EventEmittingStepExecutionListener(MessagePublisher messagePublisher, TaskEventProperties properties)

  - ### EventEmittingStepExecutionListener

    public EventEmittingStepExecutionListener(MessagePublisher messagePublisher, int order, TaskEventProperties properties)

- ## Method Details

  - ### beforeStep

    public void beforeStep(org.springframework.batch.core.StepExecution stepExecution)
    Specified by:
      `beforeStep` in interface `org.springframework.batch.core.StepExecutionListener`

  - ### afterStep

    public org.springframework.batch.core.ExitStatus afterStep(org.springframework.batch.core.StepExecution stepExecution)
    Specified by:
      `afterStep` in interface `org.springframework.batch.core.StepExecutionListener`

  - ### getOrder

    public int getOrder()
    Specified by:
      `getOrder` in interface `org.springframework.core.Ordered`