类 LimitDecider
- java.lang.Object
- org.springframework.batch.sample.loop.LimitDecider
- 所有已实现的接口:
JobExecutionDecider
public class LimitDecider extends java.lang.Object implements JobExecutionDecider
This decider will return "CONTINUE" until the limit it reached, at which point it will return "COMPLETE".- 从以下版本开始:
- 2.0
- 作者:
- Dan Garrette
构造器概要
构造器 构造器 说明 LimitDecider()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 FlowExecutionStatus
decide(JobExecution jobExecution, StepExecution stepExecution)
Strategy for branching an execution based on the state of an ongoingJobExecution
.void
setLimit(int limit)
构造器详细资料
LimitDecider
public LimitDecider()
方法详细资料
decide
public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution)
从接口复制的说明:JobExecutionDecider
Strategy for branching an execution based on the state of an ongoingJobExecution
. The return value will be used as a status to determine the next step in the job.- 指定者:
decide
在接口中JobExecutionDecider
- 参数:
jobExecution
- a job executionstepExecution
- the latest step execution (may benull
)- 返回:
- the exit status code
setLimit
public void setLimit(int limit)
- 参数:
limit
- number of times to return "CONTINUE"