Top Description Methods
jakarta.batch.api.chunk.listener

public Interface ItemProcessListener

Known Direct Implementers
jakarta.batch.api.chunk.listener.AbstractItemProcessListener

ItemProcessListener intercepts item processing.

Method Summary

Modifier and TypeMethod and Description
public void
afterProcess(Object
specifies the item processed by the item processor.
item
,
Object
specifies the item to pass to the item writer.
result
)

The afterProcess method receives control after an item processor processes an item.

public void
beforeProcess(Object
specifies the item about to be processed.
item
)

The beforeProcess method receives control before an item processor is called to process the next item.

public void
onProcessError(Object
specifies the item the processor attempted to process.
item
,
Exception
specifies the exception thrown by the item processor.
ex
)

The onProcessError method receives control after an item processor processItem throws an exception.

Method Detail

afterProcessback to summary
public void afterProcess(Object item, Object result) throws Exception

The afterProcess method receives control after an item processor processes an item. The method receives the item processed and the result item as an input.

Parameters
item:Object

specifies the item processed by the item processor.

result:Object

specifies the item to pass to the item writer.

Exceptions
Exception:
if an error occurs.
beforeProcessback to summary
public void beforeProcess(Object item) throws Exception

The beforeProcess method receives control before an item processor is called to process the next item. The method receives the item to be processed as an input.

Parameters
item:Object

specifies the item about to be processed.

Exceptions
Exception:
if an error occurs.
onProcessErrorback to summary
public void onProcessError(Object item, Exception ex) throws Exception

The onProcessError method receives control after an item processor processItem throws an exception. The method receives the item sent to the item processor as input.

Parameters
item:Object

specifies the item the processor attempted to process.

ex:Exception

specifies the exception thrown by the item processor.

Exceptions
Exception:
if an error occurs