org.springframework.batch.sample.common

## Class StagingItemListener

- java.lang.Object
- - org.springframework.batch.core.listener.StepListenerSupport<java.lang.Long,java.lang.Long>
  - - org.springframework.batch.sample.common.StagingItemListener

- All Implemented Interfaces:
    ChunkListener, ItemProcessListener<java.lang.Long,java.lang.Long>, ItemReadListener<java.lang.Long>, ItemWriteListener<java.lang.Long>, SkipListener<java.lang.Long,java.lang.Long>, StepExecutionListener, StepListener, org.springframework.beans.factory.InitializingBean

      public class StagingItemListener
      extends StepListenerSupport<java.lang.Long,java.lang.Long>
      implements org.springframework.beans.factory.InitializingBean

  Thread-safe database `ItemReader` implementing the process indicator pattern.

- - ### Field Summary

    - ### Fields inherited from interface org.springframework.batch.core.ChunkListener

      `ROLLBACK_EXCEPTION_KEY`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StagingItemListener()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `afterPropertiesSet()`
    `void` | `afterRead(java.lang.Long id)` Called after `ItemReader.read()`
    `void` | `setDataSource(javax.sql.DataSource dataSource)`

    - ### Methods inherited from class org.springframework.batch.core.listener.StepListenerSupport

      `afterChunk, afterChunkError, afterProcess, afterStep, afterWrite, beforeChunk, beforeProcess, beforeRead, beforeStep, beforeWrite, onProcessError, onReadError, onSkipInProcess, onSkipInRead, onSkipInWrite, onWriteError`

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

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

- - ### Constructor Detail

    - #### StagingItemListener

          public StagingItemListener()

  - ### Method Detail

    - #### setDataSource

          public void setDataSource(javax.sql.DataSource dataSource)

    - #### afterPropertiesSet

          public final void afterPropertiesSet()
                                        throws java.lang.Exception

      Specified by:
        `afterPropertiesSet` in interface `org.springframework.beans.factory.InitializingBean`
      Throws:
        `java.lang.Exception`

    - #### afterRead

          public void afterRead(java.lang.Long id)

      Description copied from interface: `ItemReadListener`
      Called after `ItemReader.read()`
      Specified by:
        `afterRead` in interface `ItemReadListener<java.lang.Long>`
      Overrides:
        `afterRead` in class `StepListenerSupport<java.lang.Long,java.lang.Long>`
      Parameters:
        `id` - returned from read()