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


Java OptimizerFactory.clearThreadAccessorOptimizer方法代码示例

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


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

示例1: InlineCollectionNode

import org.mvel2.optimizers.OptimizerFactory; //导入方法依赖的package包/类
public InlineCollectionNode(char[] expr, int start, int end, int fields, Class type, ParserContext pctx) {
  super(expr, start, end, fields | INLINE_COLLECTION, pctx);

  this.egressType = type;

  if ((fields & COMPILE_IMMEDIATE) != 0) {
    try {
      parseGraph(true, type, pctx);
      AccessorOptimizer ao = OptimizerFactory.getThreadAccessorOptimizer();
      accessor = ao.optimizeCollection(pctx, collectionGraph, egressType, expr, this.trailingStart, trailingOffset, null, null, null);
      egressType = ao.getEgressType();
    }
    finally {
      OptimizerFactory.clearThreadAccessorOptimizer();
    }
  }
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:18,代码来源:InlineCollectionNode.java

示例2: getReducedValueAccelerated

import org.mvel2.optimizers.OptimizerFactory; //导入方法依赖的package包/类
public Object getReducedValueAccelerated(Object ctx, Object thisValue, VariableResolverFactory factory) {
  if (accessor != null) {
    return accessor.getValue(ctx, thisValue, factory);
  }
  else {
    try {
      AccessorOptimizer ao = OptimizerFactory.getThreadAccessorOptimizer();
      if (collectionGraph == null) parseGraph(true, null, null);

      accessor = ao.optimizeCollection(AbstractParser.getCurrentThreadParserContext(), collectionGraph,
          egressType, expr, trailingStart, trailingOffset, ctx, thisValue, factory);
      egressType = ao.getEgressType();

      return accessor.getValue(ctx, thisValue, factory);
    }
    finally {
      OptimizerFactory.clearThreadAccessorOptimizer();
    }
  }

}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:22,代码来源:InlineCollectionNode.java

示例3: getReducedValueAccelerated

import org.mvel2.optimizers.OptimizerFactory; //导入方法依赖的package包/类
public Object getReducedValueAccelerated(Object ctx, Object thisValue, VariableResolverFactory factory) {
  if (accessor != null) {
    return accessor.getValue(literal, thisValue, factory);
  }
  else {
    try {
      AccessorOptimizer aO = getThreadAccessorOptimizer();
      accessor = aO.optimizeAccessor(getCurrentThreadParserContext(), expr, start, offset,
          literal, thisValue, factory, false, null);
      return aO.getResultOptPass();
    }
    finally {
      OptimizerFactory.clearThreadAccessorOptimizer();
    }
  }
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:17,代码来源:LiteralDeepPropertyNode.java

示例4: getReducedValueAccelerated

import org.mvel2.optimizers.OptimizerFactory; //导入方法依赖的package包/类
public Object getReducedValueAccelerated(Object ctx, Object thisValue, VariableResolverFactory factory) {
  if (accessor != null) {
    return accessor.getValue(main.getReducedValueAccelerated(ctx, thisValue, factory), thisValue, factory);
  }
  else {
    try {
      AccessorOptimizer o = OptimizerFactory.getThreadAccessorOptimizer();
      accessor = o.optimizeAccessor(getCurrentThreadParserContext(), expr, start, offset,
          main.getReducedValueAccelerated(ctx, thisValue, factory), thisValue, factory, false, main.getEgressType());
      return o.getResultOptPass();
    }
    finally {
      OptimizerFactory.clearThreadAccessorOptimizer();
    }
  }
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:17,代码来源:Union.java

示例5: getValue

import org.mvel2.optimizers.OptimizerFactory; //导入方法依赖的package包/类
public Object getValue(Object ctx, Object elCtx, VariableResolverFactory variableFactory) {
  if (!optimized) {
    setupOptimizers();
    try {
      return getValue(ctx, variableFactory);
    }
    finally {
      OptimizerFactory.clearThreadAccessorOptimizer();
    }
  }
  return getValue(ctx, variableFactory);
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:13,代码来源:CompiledExpression.java

示例6: getValue

import org.mvel2.optimizers.OptimizerFactory; //导入方法依赖的package包/类
public Object getValue(Object staticContext, VariableResolverFactory factory) {
  if (accessor == null) {
    try {
      accessor = getThreadAccessorOptimizer()
          .optimizeAccessor(context, expression, 0, expression.length, staticContext, staticContext, factory, false, ingressType);
      return getValue(staticContext, factory);
    }
    finally {
      OptimizerFactory.clearThreadAccessorOptimizer();
    }
  }
  return accessor.getValue(staticContext, staticContext, factory);
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:14,代码来源:CompiledAccExpression.java


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