类 DoWhile

  • 所有已实现的接口:
    ILoopTask<DoWhile>

    public class DoWhile
    extends Task<DoWhile>
    implements ILoopTask<DoWhile>
    do while 可以在循环中执行一组任务,直到条件不再满足 例如:${workflow.input.loopCount} 为循环遍历条件表达式
     ----------------------------
     |           do             |
     ----------------------------
     |                          |
     task1                      |
     |                          |
     task2                      |
     |                          |
     |--------------------------|
     |    while($loopCount)     |
     |--------------------------|
     
    • 构造器详细资料

      • DoWhile

        public DoWhile​(String taskReferenceName,
                       String expression)
        Execute tasks in a loop determined by the condition set using condition parameter. The loop will continue till the condition is true
        参数:
        taskReferenceName -
        expression - ${workflow.input.loopCount} 要求数据类型为Number类型
      • DoWhile

        public DoWhile​(String taskReferenceName,
                       int loopCount)
        Similar to a for loop, run tasks for N times
        参数:
        taskReferenceName -
        loopCount -
    • 方法详细资料

      • setLoopCondition

        public DoWhile setLoopCondition​(String condition)
        设置循环条件表达式(目前仅支持javascript)
        参数:
        condition -
        返回:
      • getLoopCondition

        public String getLoopCondition()
      • getLoopTasks

        public List<? extends Task> getLoopTasks()