跳转到指定的步骤，然后执行该步骤的方法。
跳转的目标步骤，可以是任何一个存在的步骤，这个步骤可以在当前步骤之前，也可以在当前步骤之后，
甚至就是当前步骤。

@private
@param {Object} index 当前执行的位置信息
@param {Any} context 上下文对象，每个步骤的函数都会接受到这个参数
@param {String} step 步骤名称
@param {Any} [data] 需要传递到下一个函数的数据
@returns {StepFLow}
186076
function (thisArg, index, context, step, data) {
    var steps = this.steps;
    var stepIndex = steps.indexOf(step);

    if (typeof step !== 'string' || !step) {
      throw Error('The `step` parameter must be a non-empty string');
    }

    if (stepIndex === -1) {
      throw Error('The step `' + step + '` not exists');
    }

    this.next(thisArg, {stepIndex: stepIndex, flowIndex: 0}, context, null, data);

    return this;
  }
176126
function(io) {
    var feature_hashes = [];
    var uri, feature_hash, current_step_or_hook;

    this.done = function() {
        io.write(JSON.stringify(feature_hashes, null, 2));
    };

    this.uri = function(_uri) {
        uri = _uri;
    };
    
    this.feature = function(feature) {
        feature_hash = feature;
        feature_hash['uri'] = uri;
        feature_hashes.push(feature_hash);
    };

    this.background = function(background) {
        feature_elements().push(background);
    };
    
    this.scenario = function(scenario) {
        feature_elements().push(scenario);
    };

    this.scenario_outline = function(scenario_outline) {
        feature_elements().push(scenario_outline);
    };

    this.examples = function(examples) {
        all_examples().push(examples);
    };

    this.step = function(step) {
        current_step_or_hook = step;
        steps().push(current_step_or_hook);
    }
    
    this.match = function(match) {
        current_step_or_hook['match'] = match;
    }

    this.result = function(result) {
        current_step_or_hook['result'] = result;
    }

    this.before = function(match, result) {
        add_hook(match, result, "before");
    }

    this.after = function(match, result) {
        add_hook(match, result, "after");
    }

    this.embedding = function(mime_type, data) {
        embeddings().push({'mime_type': mime_type, 'data': encode64s(data)})
    }

    this.write = function(text) {
        output().push(text);
    };

    this.eof = function() {};

    this.append_duration = function(timestamp) {
        if (current_step_or_hook['result']) {
            timestamp = timestamp * 1000000000
            rshash = current_step_or_hook['result']
            rshash['duration'] = timestamp
            current_step_or_hook['result'] = rshash
        }
    }

    // "private" methods

    function add_hook(match, result, hook) {
        if(!feature_element()[hook]) {
            feature_element()[hook] = [];
        }
        var hooks = feature_element()[hook];
        hooks.push({'match': match, 'result': result});
    }

    function feature_elements() {
        if(!feature_hash['elements']) {
            feature_hash['elements'] = [];
        }
        return feature_hash['elements'];
    }

    function feature_element() {
        return feature_elements()[feature_elements().length - 1];
    }

    function all_examples() {
        if(!feature_element()['examples']) {
            feature_element()['examples'] = [];
        }
        return feature_element()['examples'];
    }

    function steps() {
        if(!feature_element()['steps']) {
            feature_element()['steps'] = [];
        }
        return feature_element()['steps'];
    }

    function embeddings() {
        if(!current_step_or_hook['embeddings']) {
            current_step_or_hook['embeddings'] = [];
        }
        return current_step_or_hook['embeddings'];
    }

    function output() {
        if(!current_step_or_hook['output']) {
            current_step_or_hook['output'] = [];
        }
        return current_step_or_hook['output'];
    }
    
    // http://gitorious.org/javascript-base64/javascript-base64/blobs/master/base64.js
    function encode64s(input) {
        var swaps = ["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","0","1","2","3","4","5","6","7","8","9","+","/"];
        var input_binary = "";
        var output = "";
        var temp_binary;
        var index;
        for (index=0; index < input.length; index++) {
            temp_binary = input.charCodeAt(index).toString(2);
            while (temp_binary.length < 8) {
                temp_binary = "0"+temp_binary;
            }
            input_binary = input_binary + temp_binary;
            while (input_binary.length >= 6) {
                output = output + swaps[parseInt(input_binary.substring(0,6),2)];
                input_binary = input_binary.substring(6);
            }
        }
        if (input_binary.length == 4) {
            temp_binary = input_binary + "00";
            output = output + swaps[parseInt(temp_binary,2)];
            output = output + "=";
        }
        if (input_binary.length == 2) {
            temp_binary = input_binary + "0000";
            output = output + swaps[parseInt(temp_binary,2)];
            output = output + "==";
        }
        return output;
    }
}
261457
function(index) {
        var result = null,
            resultParent = null,
            traverser = new Traverser();

        traverser.traverse(this.ast, {
            enter: function(node, parent) {
                if (node.range[0] <= index && index < node.range[1]) {
                    result = node;
                    resultParent = parent;
                } else {
                    this.skip();
                }
            },
            leave: function(node) {
                if (node === result) {
                    this.break();
                }
            }
        });

        return result ? utils.mixin({parent: resultParent}, result) : null; // ORION
    }
1147679
function step(err, res) {
  if (!err && res && res.error) {
    console.log('ERR', res);
    err = res.error;
  }
  var nextStep = steps.shift();
  if (err && curStep !== 'delIndex') {
    console.log('failing on', curStep, err);
    console.trace();
    callback(err);
    return;
  }
  if (nextStep) {
    curStep = nextStep;
    var data = stepDefs[curStep].data;
    utils.doPostJson(stepDefs[curStep], data, step);
  } else {
    callback(err, res);
  }
}
1370054
function invokeLambda(bucket, key, nextFileNum, lastFileNum, arn, retries) {
    // figure out if there's a next file to process
    if (nextFileNum && arn) {
      const stepfunctions = new AWS.StepFunctions()
      const params = {
        stateMachineArn: arn,
        input: JSON.stringify({ bucket, key, currentFileNum: nextFileNum, lastFileNum, arn, retries}),
        name: `ingest_${nextFileNum}_${Date.now()}`
      }
      stepfunctions.startExecution(params, function(err, data) {
        if (err) {
          console.log(err, err.stack)
        } else {
          console.log(`launched ${JSON.stringify(params)}`)
        }
      }) 
    }
}
651597
public void step(Context ctxt, ILexLocation location)
	{
		if (Settings.dialect == Dialect.VDM_RT)
		{
			if (!virtual)
			{
				duration(getObject().getCPU().getDuration(Properties.rt_cycle_default), ctxt, location);
			}
		} else
		{
			SystemClock.advance(Properties.rt_duration_default);
		}

		// Note that we don't reschedule if we are in an outer cycles/duration

		if (++steps >= timeslice && !inOuterTimeStep)
		{
			reschedule(ctxt, location);
			steps = 0;
		}
	}
1291479
private void esIndex(String index, String id, String json, String pipeline) {
        logger.debug("Indexing {}/{}?pipeline={}", index, id, pipeline);
        logger.trace("JSon indexed : {}", json);

        if (!closed) {
            esClient.index(index, id, json, pipeline);
        } else {
            logger.warn("trying to add new file while closing crawler. Document [{}]/[{}] has been ignored", index, id);
        }
    }
100476
def pathFromIndex(self, index):
        
        out  = []
        while index and index.isValid():
            out.append(nativestring(unwrapVariant(index.data())))
            index = self._model.parent(index)
        
        return self.joiner().join(reversed(out))
950710
function (indexMap, loadOrder) {
                // In older versions indexMap was an object instead of a sparse array
                if (!('length' in indexMap)) {
                    var indexArray = [],
                        index;
                    
                    for (index in indexMap) {
                        if (!isNaN(+index)) {
                            indexArray[+index] = indexMap[index];
                        }
                    }
                    
                    indexMap = indexArray;
                }
                
                return Request.prototype.getPathsFromIndexes(indexMap, loadOrder);
            }
1031370
function(index) {
    var calls = this.all();
    var call = calls[index];

    return call ? call.object : null;
  }
334203
private void parseLocationStep(String selector,
                                 int start,
                                 int stepEnd)
    throws InvalidXPathSyntaxException
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      tc.entry(cclass,
               "parseLocationStep",
               "selector: " + selector + ", start: " + start + ", end: " + stepEnd);

    int stepStart = start;
    int posOpenBracket = selector.indexOf("[", start);
    if(posOpenBracket > stepEnd || posOpenBracket == -1)
    {
      // Set posOpenBracket to avoid further processing
      posOpenBracket = -1;
      // No brackets so process whole of the location step
      String step = selector.substring(start,stepEnd);
      // Set the full name into the identifier. The full name is used in position assignment when
      // determining uniqueness of names. Only a full name will do.
      String full = selector.substring(0,stepEnd);
      // Add an IdentifierImpl for the location step to the array list
      selOperands.add(createIdentifierForSubExpression(step, full, true, false));      
    }
    
    int posCloseBracket = selector.indexOf("]", start); 
 
    boolean wrapWholeStep = false;
    boolean foundPredicates = false;
    ArrayList tempSelOperands = new ArrayList();
    while (posOpenBracket >= 0)
    {
      foundPredicates = true;
      if(posCloseBracket < posOpenBracket)
      {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
          tc.exit(this,cclass, "parseLocationStep", "bracket error"); 
        
        InvalidXPathSyntaxException iex = new InvalidXPathSyntaxException(selector);
        FFDC.processException(cclass,
            "com.ibm.ws.sib.matchspace.selector.impl.XPath10ParserImpl",
            iex,
            "1:372:1.16"); 
        
        throw iex;
      }
      else
      {
        // The full selector path up to this point
        String full = selector.substring(0,posOpenBracket);
        
        // Factor out the location step first but be careful we may have a predicate
        if(start != posOpenBracket)
        {
          // Go ahead and deal with the location step
          String step = selector.substring(start,posOpenBracket);
          // Add an IdentifierImpl for the location step to the array list
          tempSelOperands.add(createIdentifierForSubExpression(step, full, true, false));    
        }
        
        // Now parse the predicate
        String predicate = selector.substring(posOpenBracket + 1,posCloseBracket);
        Selector parsedPredicate = parsePredicate(predicate, full);
        
        // Check whether we were able to parse
        if(parsedPredicate == null)
        {
          // Unable to parse the expression, so we need to wrap the entire step
//          tempSelOperands.add(createIdentifierForSubExpression(predicate, false));
          wrapWholeStep = true;
          break;
        }
        else
        {
          // we were able to parse the expression with the MatchParser
          // Check that the predicate has Simple tests only
          if(!Matching.isSimple(parsedPredicate))
          {
            wrapWholeStep = true;
            break;
          }
          parsedPredicate.setExtended();
          tempSelOperands.add(parsedPredicate);
        }       
      }
        
      // Move to beyond the close bracket
      start = posCloseBracket+1;
      //Are there any more brackets?
      posOpenBracket = selector.indexOf("[", start);
      posCloseBracket = selector.indexOf("]", start); 
      
      // Have we found the last bracket in this location step?
      if(posOpenBracket > stepEnd || posOpenBracket == -1)
      {
        // Set posOpenBracket to avoid further processing
        posOpenBracket = -1; 
      }
    } // eof while
    
    if(foundPredicates)
    {
      // If we determined that we cannot parse this location step, then wrap it
      if(wrapWholeStep)
        wrapLocationStep(selector, stepStart,stepEnd);
      else
      {
        // PostProcessing here
        selOperands.addAll(tempSelOperands);
      }
    }
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      tc.exit(this,cclass, "parseLocationStep");      
  }
602118
function getStep(step) {
        var template = grunt.file.read(templates.stepTemplate),
            stepTemplate;

        stepTemplate = grunt.template.process(template, {
            data: {
                status: step.result ? step.result.status : '',
                errorDetails: step.result ? toHtmlEntities(step.result.error_message) : '',
                duration: step.result.duration ? calculateDuration(step.result.duration) : 'no data',
                tableOutline: (step.arguments && step.arguments.length > 0) ? step.arguments[0].rows : step.rows,
                name: step.keyword + (step.name ? step.name : '')
            }
        });
        return stepTemplate;
    }
999831
function insert(seq, index) { var values, result
        values = slice(arguments, 2)
        result = copy(seq)
        result.splice.apply(result, [index, 0].concat(values))

        return result
    }
1327439
def skip( index, start )
      if @index == index
        Lookup.new @p.lookup( start, @stride ), @index, @stride
      else
        Lookup.new @p.skip( index, start ), @index, @stride
      end
    end
492027
function(step, next) {
      if (step.options.data != null) {
        step.data = step.options.data;
      } else {
        step.data = {};
      }
      return next();
    }
32488
function() {
        stepids = [];
        var steps = root.querySelectorAll( ".step" );
        for ( var i = 0; i < steps.length; i++ )
        {
          stepids[ i + 1 ] = steps[ i ].id;
        }
        }
303943
public void forEachIndexed(int from, int step,
                               @NotNull IndexedDoubleConsumer action) {
        int index = from;
        while (iterator.hasNext()) {
            action.accept(index, iterator.nextDouble());
            index += step;
        }
    }