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

public Interface ItemReadListener

Known Direct Implementers
javax.batch.api.chunk.listener.AbstractItemReadListener

ItemReadListener intercepts item reader processing.

Method Summary

Modifier and TypeMethod and Description
public void
afterRead(Object
specifies the item read by the item reader.
item
)

The afterRead method receives control after an item reader reads an item.

public void
beforeRead()

The beforeRead method receives control before an item reader is called to read the next item.

public void
onReadError(Exception
specifies the exception that occurred in the item reader.
ex
)

The onReadError method receives control after an item reader throws an exception in the readItem method.

Method Detail

afterReadback to summary
public void afterRead(Object item) throws Exception

The afterRead method receives control after an item reader reads an item. The method receives the item read as an input.

Parameters
item:Object

specifies the item read by the item reader.

Exceptions
Exception:
is thrown if an error occurs.
beforeReadback to summary
public void beforeRead() throws Exception

The beforeRead method receives control before an item reader is called to read the next item.

Exceptions
Exception:
is thrown if an error occurs.
onReadErrorback to summary
public void onReadError(Exception ex) throws Exception

The onReadError method receives control after an item reader throws an exception in the readItem method. This method receives the exception as an input.

Parameters
ex:Exception

specifies the exception that occurred in the item reader.

Exceptions
Exception:
is thrown if an error occurs.