Method ProcessNextStep
553093
private void ProcessNextStep() {

        switch (iSelectionStep) {

            case SELECT_SOURCE_CATALOG :
            case SELECT_DEST_CATALOG :
                if (CatalogToSelect()) {
                    fMain.show();

                    return;
                }
                break;

            case SELECT_DEST_SCHEMA :
            case SELECT_SOURCE_SCHEMA :
                if (SchemaToSelect()) {
                    fMain.show();

                    return;
                }
                break;

            case SELECT_SOURCE_TABLES :
                if (iTransferMode == TRFM_TRANSFER) {
                    bStart.setLabel("Start Transfer");
                } else if (iTransferMode == TRFM_DUMP) {
                    bStart.setLabel("Start Dump");
                } else if (iTransferMode == TRFM_RESTORE) {
                    bStart.setLabel("Start Restore");
                }

                bStart.invalidate();
                bStart.setEnabled(false);
                lTable.setMultipleMode(false);
                RefreshMainDisplay();
                break;

            default :
                break;
        }
    }
694627
def step(self, viewer=None):
        ""
        if not self.is_completed(self.state):
            for agent in self.agents:
                action = agent.program(self.percept(agent, self.state))
                next_state = self.do_action(self.state, action, agent)
                if viewer:
                    viewer.event(self.state, action, next_state, agent)
                self.state = next_state
                if self.is_completed(self.state):
                    return
787875
private T safeStep(T base) {
		T next = null;
		try {
			next = steper.step(base, this.end, this.index);
		} catch (Exception e) {
			// ignore
		}
		return next;
	}
129449
def run_step(self):
        """"""
        rewriter = StreamRewriter(self.context.iter_formatted_strings)
        super().run_step(rewriter)
725870
private void processNow() {
        List<T> toProcess;
        boolean scheduleNextBatchImmediately = false;
        synchronized (mutex) {
            int count = inbox.size();
            Log.v(Log.TAG_BATCHER, "%s: processNow() called, inbox size: %d", this, count);
            if (count == 0)
                return;
            else if (count <= capacity) {
                toProcess = new ArrayList<T>(inbox);
                inbox.clear();
            } else {
                toProcess = new ArrayList<T>(inbox.subList(0, capacity));
                for (int i = 0; i < capacity; i++)
                    inbox.remove(0);
                scheduleNextBatchImmediately = true;
            }
            mutex.notifyAll();
        }

        synchronized (processMutex) {
            if (toProcess != null && toProcess.size() > 0) {
                Log.v(Log.TAG_BATCHER, "%s: invoking processor %s with %d items",
                        this, processor, toProcess.size());
                processor.process(toProcess);
            } else
                Log.v(Log.TAG_BATCHER, "%s: nothing to process", this);

            synchronized (mutex) {
                lastProcessedTime = System.currentTimeMillis();
                scheduled = false;
                scheduleBatchProcess(scheduleNextBatchImmediately);
                Log.v(Log.TAG_BATCHER, "%s: invoking processor done",
                        this, processor, toProcess.size());
            }
            processMutex.notifyAll();
        }
    }
846145
protected function doStep()
    {
        // Wait for the next signal request. The request itself doesn't contain any data.
        $this->decoder->decode(SignalRequest::class);

        try {
            // Request a new signal from the implementation
            $this->signaler->signal($this);
        } catch (Exception $ex) {
            $this->encoder->encode(SignalResponse::error($ex));
        }
    }
605411
def get_next_step(self):
        
        if self.rbHazLayerFromCanvas.isChecked():
            new_step = self.parent.step_fc_hazlayer_from_canvas
        else:
            new_step = self.parent.step_fc_hazlayer_from_browser
        return new_step
560688
function next () {
    var args = slice.call(arguments)
    if (!isYieldable) {
      // only handle callback if not yieldable
      if (iter && yielded) {
        // no need defer when yielded
        step.apply(self, args)
      } else {
        // need next tick if not defered
        process.nextTick(function () {
          step.apply(self, args)
        })
      }
    } else {
      step(new Error('Callback on yieldable is prohibited'))
    }
  }
204931
function steppingDispatch() {
        applyExternalEffect(options.stepping.effect);  // WARNING: may change `options.stepping.effect`
        var event = options.dequeue(events);
        if (!event) {
            return false;
        }
        var effect = options.stepping.effect;
        effect.event = event;
        try {
            var behavior = event.context.behavior;
            effect.behavior = behavior;
            event.context.behavior(event.message);  // execute actor behavior
            if (behavior !== event.context.behavior) {
                effect.became = event.context.behavior;
            }
        } catch (exception) {
            effect.exception = exception;
        }
        applyBehaviorEffect(effect);  // WARNING: will change `options.stepping.effect`
        return effect;
    }
1374866
private void onPushLevelProgress(int steps, Object source, boolean singlesteplevel)
    {
        if (this.currentStep.isLevelFinished()) {
            // If current step is done move to next one
            this.currentStep = this.currentStep.getParent().nextStep(null, source);
        }

        // Add level
        this.currentStep = this.currentStep.addLevel(steps, source, singlesteplevel);
    }
146781
function(step, next) {
      var currentStep;
      step.steps = copyArray(step.steps);
      currentStep = -1;
      step.next = function() {
        var args;
        currentStep++;
        args = [step].concat(copyArray(arguments));
        if (currentStep >= step.steps.length) {
          return step.callback.apply(null, args);
        } else {
          return step.steps[currentStep].apply(null, args);
        }
      };
      return next();
    }
1005736
private function performStep($sessionId, Step $step, Context $context, $currentIteration)
    {
        switch (true) {
            case $step instanceof Merge:
                $newContext = $this->actionMapping->merge($sessionId, $context, $step);
                $context = $this->converse($sessionId, null, $newContext, --$currentIteration);
                break;
            case $step instanceof Message:
                $this->actionMapping->say($sessionId, $context, $step);
                $context = $this->converse($sessionId, null, $context, --$currentIteration);
                break;
            case $step instanceof Action:
                $newContext = $this->actionMapping->action($sessionId, $context, $step);
                $context = $this->converse($sessionId, null, $newContext, --$currentIteration);
                break;
            case $step instanceof Stop:
                $this->actionMapping->stop($sessionId, $context, $step);
                break;
        }

        return $context;
    }
565292
function step (context) {
  // call method again on next available frame
  context.frame = window.requestAnimationFrame(step.bind(window, context))
  const time = now()
  let elapsed = (time - context.startTime) / 468
  // avoid elapsed times higher than one
  elapsed = elapsed > 1 ? 1 : elapsed
  // apply easing to elapsed time
  const value = ease(elapsed)
  const currentPosition = context.startPosition + (context.position - context.startPosition) * value
  context.method.call(context.scrollable, context.dSuffix, currentPosition)
  // return when end points have been reached
  /**
    * NOTE: should use ~~ to parse position number into integer. Otherwise
    * this two float numbers maybe have a slicely little difference, which
    * will cause this function never to stop.
  */
  if (~~currentPosition === ~~context.position) {
    window.cancelAnimationFrame(context.frame)
    return
  }
}
522948
@Override
    public void process(Step step) {
        Status status = throwable instanceof AssertionError ? Status.FAILED : Status.BROKEN;
        step.setStatus(status);
    }
358224
void recomputeProgress() {
    if (isComplete()) {
      this.progress = 1;
      // update the counters and the state
      TaskStatus completedStatus = taskStatuses.get(getSuccessfulTaskid());
      this.counters = completedStatus.getCounters();
      this.state = completedStatus.getStateString();
    } else if (failed) {
      this.progress = 0;
      // reset the counters and the state
      this.state = "";
      this.counters = new Counters();
    } else {
      double bestProgress = 0;
      String bestState = "";
      Counters bestCounters = new Counters();
      for (Iterator<TaskAttemptID> it = taskStatuses.keySet().iterator(); it.hasNext();) {
        TaskAttemptID taskid = it.next();
        TaskStatus status = taskStatuses.get(taskid);
        if (status.getRunState() == TaskStatus.State.SUCCEEDED) {
          bestProgress = 1;
          bestState = status.getStateString();
          bestCounters = status.getCounters();
          break;
        } else if (status.getRunState() == TaskStatus.State.COMMIT_PENDING) {
          //for COMMIT_PENDING, we take the last state that we recorded
          //when the task was RUNNING
          bestProgress = this.progress;
          bestState = this.state;
          bestCounters = this.counters;
        } else if (status.getRunState() == TaskStatus.State.RUNNING) {
          if (status.getProgress() >= bestProgress) {
            bestProgress = status.getProgress();
            bestState = status.getStateString();
            if (status.getIncludeCounters()) {
              bestCounters = status.getCounters();
            } else {
              bestCounters = this.counters;
            }
          }
        }
      }
      this.progress = bestProgress;
      this.state = bestState;
      this.counters = bestCounters;
    }
  }
1335668
protected function addStepNextStates(Definition $step, $stepsNextStates, $processName)
    {
        foreach ($stepsNextStates as $stateName => $data) {
            if (NextStateInterface::TYPE_STEP === $data['type']) {
                $step->addMethodCall('addNextState', array(
                    $stateName,
                    $data['type'],
                    new Reference(sprintf('lexik_workflow.process.%s.step.%s', $processName, $data['target']))
                ));

            } elseif (NextStateInterface::TYPE_STEP_OR === $data['type']) {
                $targets = array();

                foreach ($data['target'] as $stepName => $condition) {
                    $serviceId = null;
                    $method = null;

                    if (!empty($condition)) {
                        list($serviceId, $method) = explode(':', $condition);
                    }

                    $targets[] = array(
                        'target'           => new Reference(sprintf('lexik_workflow.process.%s.step.%s', $processName, $stepName)),
                        'condition_object' => null !== $serviceId ? new Reference($serviceId) : null,
                        'condition_method' => $method,
                    );
                }

                $step->addMethodCall('addNextStateOr', array($stateName, $data['type'], $targets));

            } elseif (NextStateInterface::TYPE_PROCESS === $data['type']) {
                $step->addMethodCall('addNextState', array(
                    $stateName,
                    $data['type'],
                    new Reference(sprintf('lexik_workflow.process.%s', $data['target']))
                ));

            } else {
                throw new \InvalidArgumentException(sprintf('Unknown type "%s", please use "step" or "process"', $data['type']));
            }
        }
    }
18676
private void process(Node root, boolean hotSwap) {
    checkState(contextStack.isEmpty());
    contextStack.push(LexicalContext.newGlobalContext(root));
    if (hotSwap) {
      TranspilationPasses.hotSwapTranspile(compiler, root, transpiledFeatures, this);
    } else {
      TranspilationPasses.processTranspile(compiler, root, transpiledFeatures, this);
    }
    TranspilationPasses.maybeMarkFeaturesAsTranspiledAway(compiler, transpiledFeatures);
    checkState(contextStack.element().function == null);
    contextStack.remove();
    checkState(contextStack.isEmpty());
  }