Remove compiler warnings related to Batch upgrade

This commit is contained in:
Dave Syer
2014-04-25 10:59:52 +01:00
parent 3173646635
commit 63f2d6ab15
3 changed files with 3 additions and 4 deletions

View File

@@ -101,7 +101,7 @@ public class BatchAutoConfiguration {
JobExplorerFactoryBean factory = new JobExplorerFactoryBean();
factory.setDataSource(dataSource);
factory.afterPropertiesSet();
return (JobExplorer) factory.getObject();
return factory.getObject();
}
@Bean

View File

@@ -253,7 +253,7 @@ public class BatchAutoConfigurationTests {
MapJobExplorerFactoryBean explorer = new MapJobExplorerFactoryBean(
this.factory);
explorer.afterPropertiesSet();
return (JobExplorer) explorer.getObject();
return explorer.getObject();
}
}

View File

@@ -179,8 +179,7 @@ public class JobLauncherCommandLineRunnerTests {
@Bean
public JobExplorer jobExplorer() throws Exception {
return (JobExplorer) new MapJobExplorerFactoryBean(this.jobRepositoryFactory)
.getObject();
return new MapJobExplorerFactoryBean(this.jobRepositoryFactory).getObject();
}
}