Class JobExecutionListenerSupport
- java.lang.Object
- org.springframework.batch.core.listener.JobExecutionListenerSupport
- All Implemented Interfaces:
JobExecutionListener
public class JobExecutionListenerSupport extends java.lang.Object implements JobExecutionListener
- Author:
- Dave Syer
Constructor Summary
Constructors Constructor Description JobExecutionListenerSupport()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterJob(JobExecution jobExecution)
Callback after completion of a job.void
beforeJob(JobExecution jobExecution)
Callback before a job executes.
Method Detail
afterJob
public void afterJob(JobExecution jobExecution)
Description copied from interface:JobExecutionListener
Callback after completion of a job. Called after both both successful and failed executions. To perform logic on a particular status, use "if (jobExecution.getStatus() == BatchStatus.X)".- Specified by:
afterJob
in interfaceJobExecutionListener
- Parameters:
jobExecution
- the currentJobExecution
beforeJob
public void beforeJob(JobExecution jobExecution)
Description copied from interface:JobExecutionListener
Callback before a job executes.- Specified by:
beforeJob
in interfaceJobExecutionListener
- Parameters:
jobExecution
- the currentJobExecution