当前位置: 首页>>代码示例>>Java>>正文


Java Compiler.getNextStepPos方法代码示例

本文整理汇总了Java中com.sun.org.apache.xpath.internal.compiler.Compiler.getNextStepPos方法的典型用法代码示例。如果您正苦于以下问题:Java Compiler.getNextStepPos方法的具体用法?Java Compiler.getNextStepPos怎么用?Java Compiler.getNextStepPos使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.sun.org.apache.xpath.internal.compiler.Compiler的用法示例。


在下文中一共展示了Compiler.getNextStepPos方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: loadWalkers

import com.sun.org.apache.xpath.internal.compiler.Compiler; //导入方法依赖的package包/类
/**
 * This method is for building an array of possible levels
 * where the target element(s) could be found for a match.
 * @param lpi The owning location path iterator object.
 * @param compiler non-null reference to compiler object that has processed
 *                 the XPath operations into an opcode map.
 * @param stepOpCodePos The opcode position for the step.
 * @param stepIndex The top-level step index withing the iterator.
 *
 * @return non-null AxesWalker derivative.
 *
 * @throws javax.xml.transform.TransformerException
 * @xsl.usage advanced
 */
static AxesWalker loadWalkers(
        WalkingIterator lpi, Compiler compiler, int stepOpCodePos, int stepIndex)
          throws javax.xml.transform.TransformerException
{

  int stepType;
  AxesWalker firstWalker = null;
  AxesWalker walker, prevWalker = null;

  int analysis = analyze(compiler, stepOpCodePos, stepIndex);

  while (OpCodes.ENDOP != (stepType = compiler.getOp(stepOpCodePos)))
  {
    walker = createDefaultWalker(compiler, stepOpCodePos, lpi, analysis);

    walker.init(compiler, stepOpCodePos, stepType);
    walker.exprSetParent(lpi);

    // walker.setAnalysis(analysis);
    if (null == firstWalker)
    {
      firstWalker = walker;
    }
    else
    {
      prevWalker.setNextWalker(walker);
      walker.setPrevWalker(prevWalker);
    }

    prevWalker = walker;
    stepOpCodePos = compiler.getNextStepPos(stepOpCodePos);

    if (stepOpCodePos < 0)
      break;
  }

  return firstWalker;
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:53,代码来源:WalkerFactory.java


注:本文中的com.sun.org.apache.xpath.internal.compiler.Compiler.getNextStepPos方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。