类 BatchletAdapter
- java.lang.Object
- org.springframework.batch.core.jsr.step.batchlet.BatchletAdapter
- 所有已实现的接口:
StoppableTasklet
,Tasklet
public class BatchletAdapter extends java.lang.Object implements StoppableTasklet
- 从以下版本开始:
- 3.0
- 作者:
- Michael Minella
构造器概要
构造器 构造器 说明 BatchletAdapter(javax.batch.api.Batchlet batchlet)
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 RepeatStatus
execute(StepContribution contribution, ChunkContext chunkContext)
Given the current context in the form of a step contribution, do whatever is necessary to process this unit inside a transaction.void
stop()
Used to signal that the job thisTasklet
is executing within has been requested to stop.
构造器详细资料
BatchletAdapter
public BatchletAdapter(javax.batch.api.Batchlet batchlet)
方法详细资料
execute
public RepeatStatus execute(StepContribution contribution, ChunkContext chunkContext) throws java.lang.Exception
从接口复制的说明:Tasklet
Given the current context in the form of a step contribution, do whatever is necessary to process this unit inside a transaction. Implementations returnRepeatStatus.FINISHED
if finished. If not they returnRepeatStatus.CONTINUABLE
. On failure throws an exception.- 指定者:
execute
在接口中Tasklet
- 参数:
contribution
- mutable state to be passed back to update the current step executionchunkContext
- attributes shared between invocations but not between restarts- 返回:
- an
RepeatStatus
indicating whether processing is continuable. Returningnull
is interpreted asRepeatStatus.FINISHED
- 抛出:
java.lang.Exception
- thrown if error occurs during execution.
stop
public void stop()
从接口复制的说明:StoppableTasklet
Used to signal that the job thisTasklet
is executing within has been requested to stop.- 指定者:
stop
在接口中StoppableTasklet