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


Java MethodVisitor.visitMaxs方法代码示例

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


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

示例1: _initJIT

import org.mvel2.asm.MethodVisitor; //导入方法依赖的package包/类
/**
 * Does all the boilerplate for initiating the JIT.
 */
private void _initJIT() {
    if (isAdvancedDebugging()) {
        buildLog = new StringAppender();
    }

    cw = new ClassWriter(ClassWriter.COMPUTE_MAXS + ClassWriter.COMPUTE_FRAMES);

    synchronized (Runtime.getRuntime()) {
        cw.visit(OPCODES_VERSION, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER, className = "ASMAccessorImpl_"
                + valueOf(cw.hashCode()).replaceAll("\\-", "_") + (System.currentTimeMillis() / 10) +
                ((int) Math.random() * 100),
                null, "java/lang/Object", new String[]{NAMESPACE + "compiler/Accessor"});
    }

    MethodVisitor m = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, null);

    m.visitCode();
    m.visitVarInsn(Opcodes.ALOAD, 0);
    m.visitMethodInsn(INVOKESPECIAL, "java/lang/Object",
            "<init>", "()V");
    m.visitInsn(RETURN);

    m.visitMaxs(1, 1);
    m.visitEnd();

    (mv = cw.visitMethod(ACC_PUBLIC, "getValue",
            "(Ljava/lang/Object;Ljava/lang/Object;L" + NAMESPACE
                    + "integration/VariableResolverFactory;)Ljava/lang/Object;", null, null)).visitCode();
}
 
开发者ID:codehaus,项目名称:mvel,代码行数:33,代码来源:ASMAccessorOptimizer.java

示例2: _initJIT2

import org.mvel2.asm.MethodVisitor; //导入方法依赖的package包/类
private void _initJIT2() {
    if (isAdvancedDebugging()) {
        buildLog = new StringAppender();
    }

    cw = new ClassWriter(ClassWriter.COMPUTE_MAXS + ClassWriter.COMPUTE_FRAMES);

    synchronized (Runtime.getRuntime()) {
        cw.visit(OPCODES_VERSION, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER, className = "ASMAccessorImpl_"
                + valueOf(cw.hashCode()).replaceAll("\\-", "_") + (System.currentTimeMillis() / 10) +
                ((int) Math.random() * 100),
                null, "java/lang/Object", new String[]{NAMESPACE + "compiler/Accessor"});
    }

    MethodVisitor m = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, null);

    m.visitCode();
    m.visitVarInsn(Opcodes.ALOAD, 0);
    m.visitMethodInsn(INVOKESPECIAL, "java/lang/Object",
            "<init>", "()V");
    m.visitInsn(RETURN);

    m.visitMaxs(1, 1);
    m.visitEnd();

    (mv = cw.visitMethod(ACC_PUBLIC, "setValue",
            "(Ljava/lang/Object;Ljava/lang/Object;L" + NAMESPACE
                    + "integration/VariableResolverFactory;Ljava/lang/Object;)Ljava/lang/Object;", null, null)).visitCode();
}
 
开发者ID:codehaus,项目名称:mvel,代码行数:30,代码来源:ASMAccessorOptimizer.java

示例3: _initJIT

import org.mvel2.asm.MethodVisitor; //导入方法依赖的package包/类
/**
 * Does all the boilerplate for initiating the JIT.
 */
private void _initJIT() {
  if (isAdvancedDebugging()) {
    buildLog = new StringAppender();
  }

  cw = new ClassWriter(ClassWriter.COMPUTE_MAXS + ClassWriter.COMPUTE_FRAMES);

  synchronized (Runtime.getRuntime()) {
    cw.visit(OPCODES_VERSION, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER, className = "ASMAccessorImpl_"
        + valueOf(cw.hashCode()).replaceAll("\\-", "_") + (System.currentTimeMillis() / 10) +
        ((int) Math.random() * 100),
        null, "java/lang/Object", new String[]{NAMESPACE + "compiler/Accessor"});
  }

  MethodVisitor m = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, null);

  m.visitCode();
  m.visitVarInsn(Opcodes.ALOAD, 0);
  m.visitMethodInsn(INVOKESPECIAL, "java/lang/Object",
      "<init>", "()V");
  m.visitInsn(RETURN);

  m.visitMaxs(1, 1);
  m.visitEnd();

  (mv = cw.visitMethod(ACC_PUBLIC, "getValue",
      "(Ljava/lang/Object;Ljava/lang/Object;L" + NAMESPACE
          + "integration/VariableResolverFactory;)Ljava/lang/Object;", null, null)).visitCode();
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:33,代码来源:ASMAccessorOptimizer.java

示例4: _initJIT2

import org.mvel2.asm.MethodVisitor; //导入方法依赖的package包/类
private void _initJIT2() {
  if (isAdvancedDebugging()) {
    buildLog = new StringAppender();
  }

  cw = new ClassWriter(ClassWriter.COMPUTE_MAXS + ClassWriter.COMPUTE_FRAMES);

  synchronized (Runtime.getRuntime()) {
    cw.visit(OPCODES_VERSION, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER, className = "ASMAccessorImpl_"
        + valueOf(cw.hashCode()).replaceAll("\\-", "_") + (System.currentTimeMillis() / 10) +
        ((int) Math.random() * 100),
        null, "java/lang/Object", new String[]{NAMESPACE + "compiler/Accessor"});
  }

  MethodVisitor m = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, null);

  m.visitCode();
  m.visitVarInsn(Opcodes.ALOAD, 0);
  m.visitMethodInsn(INVOKESPECIAL, "java/lang/Object",
      "<init>", "()V");
  m.visitInsn(RETURN);

  m.visitMaxs(1, 1);
  m.visitEnd();

  (mv = cw.visitMethod(ACC_PUBLIC, "setValue",
      "(Ljava/lang/Object;Ljava/lang/Object;L" + NAMESPACE
          + "integration/VariableResolverFactory;Ljava/lang/Object;)Ljava/lang/Object;", null, null)).visitCode();
}
 
开发者ID:osswangxining,项目名称:mvel-jsr223,代码行数:30,代码来源:ASMAccessorOptimizer.java


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