Example usage for org.springframework.batch.core.step.job JobStep setJob

List of usage examples for org.springframework.batch.core.step.job JobStep setJob

Introduction

In this page you can find the example usage for org.springframework.batch.core.step.job JobStep setJob.

Prototype

public void setJob(Job job) 

Source Link

Document

The Job to delegate to in this step.

Usage

From source file:org.springframework.batch.core.configuration.xml.StepParserStepFactoryBean.java

@SuppressWarnings("serial")
private void configureJobStep(JobStep ts) throws Exception {
    configureAbstractStep(ts);/*from  w ww .j a v  a 2  s .c  om*/
    if (job != null) {
        ts.setJob(job);
    }
    if (jobParametersExtractor != null) {
        ts.setJobParametersExtractor(jobParametersExtractor);
    }
    if (jobLauncher == null) {
        SimpleJobLauncher jobLauncher = new SimpleJobLauncher();
        jobLauncher.setJobRepository(jobRepository);
        jobLauncher.afterPropertiesSet();
        this.jobLauncher = jobLauncher;
    }
    ts.setJobLauncher(jobLauncher);
}