Package org.jeasy.batch.core.listener
Interface RecordReaderListener<P>
-
- Type Parameters:
P- type of the record's payload
- All Known Implementing Classes:
CompositeRecordReaderListener
public interface RecordReaderListener<P>Enables the implementing class to get notified before/after reading a record.- Author:
- Mario Mueller (mario@xenji.com)
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default voidafterRecordReading(Record<P> record)Called after each record read operation.default voidbeforeRecordReading()Called before each record read operation.default voidonRecordReadingException(java.lang.Throwable throwable)Called when an exception occurs during record reading.
-
-
-
Method Detail
-
beforeRecordReading
default void beforeRecordReading()
Called before each record read operation.
-
afterRecordReading
default void afterRecordReading(Record<P> record)
Called after each record read operation.- Parameters:
record- The record that has been read. May benullif the reader reached the end of data source
-
onRecordReadingException
default void onRecordReadingException(java.lang.Throwable throwable)
Called when an exception occurs during record reading.- Parameters:
throwable- the throwable that was thrown during record reading
-
-