类 MethodProcessor

java.lang.Object
com.alibaba.bytekit.asm.MethodProcessor

public class MethodProcessor extends Object
  • 字段详细资料

    • DEFAULT_INNER_VARIABLE_PREFIX

      public static final String DEFAULT_INNER_VARIABLE_PREFIX
      另请参阅:
  • 构造器详细资料

    • MethodProcessor

      public MethodProcessor(com.alibaba.deps.org.objectweb.asm.tree.ClassNode classNode, com.alibaba.deps.org.objectweb.asm.tree.MethodNode methodNode)
    • MethodProcessor

      public MethodProcessor(com.alibaba.deps.org.objectweb.asm.tree.ClassNode classNode, com.alibaba.deps.org.objectweb.asm.tree.MethodNode methodNode, LocationFilter locationFilter)
    • MethodProcessor

      public MethodProcessor(com.alibaba.deps.org.objectweb.asm.tree.ClassNode classNode, com.alibaba.deps.org.objectweb.asm.tree.MethodNode methodNode, boolean keepLocalVariableNames)
    • MethodProcessor

      public MethodProcessor(String owner, com.alibaba.deps.org.objectweb.asm.tree.MethodNode methodNode, boolean keepLocalVariableNames)
    • MethodProcessor

      public MethodProcessor(String owner, com.alibaba.deps.org.objectweb.asm.tree.MethodNode methodNode)
  • 方法详细资料

    • initMonitorVariableNode

      public com.alibaba.deps.org.objectweb.asm.tree.LocalVariableNode initMonitorVariableNode()
    • initThrowVariableNode

      public com.alibaba.deps.org.objectweb.asm.tree.LocalVariableNode initThrowVariableNode()
    • initInvokeArgsVariableNode

      public com.alibaba.deps.org.objectweb.asm.tree.LocalVariableNode initInvokeArgsVariableNode()
    • initReturnVariableNode

      public com.alibaba.deps.org.objectweb.asm.tree.LocalVariableNode initReturnVariableNode()
    • initInvokeReturnVariableNode

      public com.alibaba.deps.org.objectweb.asm.tree.LocalVariableNode initInvokeReturnVariableNode(String name, com.alibaba.deps.org.objectweb.asm.Type type)
      参数:
      name -
      type -
      返回:
    • initTryCatchBlock

      public TryCatchBlock initTryCatchBlock()
    • initTryCatchBlock

      public TryCatchBlock initTryCatchBlock(String exception)
    • getEnterInsnNode

      public com.alibaba.deps.org.objectweb.asm.tree.AbstractInsnNode getEnterInsnNode()
    • getLastInsnNode

      public com.alibaba.deps.org.objectweb.asm.tree.AbstractInsnNode getLastInsnNode()
    • getParameterTypes

      public String[] getParameterTypes()
    • getParameterNames

      public String[] getParameterNames()
    • getReturnType

      public com.alibaba.deps.org.objectweb.asm.Type getReturnType()
    • loadThis

      public void loadThis(com.alibaba.deps.org.objectweb.asm.tree.InsnList instructions)
    • returnValue

      public void returnValue(com.alibaba.deps.org.objectweb.asm.tree.InsnList instructions)
    • isStatic

      public boolean isStatic()
    • isConstructor

      public boolean isConstructor()
    • getMethodNode

      public com.alibaba.deps.org.objectweb.asm.tree.MethodNode getMethodNode()
    • setMethodNode

      public void setMethodNode(com.alibaba.deps.org.objectweb.asm.tree.MethodNode methodNode)
    • getOwner

      public String getOwner()
    • setOwner

      public void setOwner(String owner)
    • getClassNode

      public com.alibaba.deps.org.objectweb.asm.tree.ClassNode getClassNode()
    • setClassNode

      public void setClassNode(com.alibaba.deps.org.objectweb.asm.tree.ClassNode classNode)
    • getLocationFilter

      public LocationFilter getLocationFilter()
    • inline

      public void inline(String owner, com.alibaba.deps.org.objectweb.asm.tree.MethodNode toInlineMethodNode)
    • inline

      public void inline(String owner, com.alibaba.deps.org.objectweb.asm.tree.MethodNode toInlineMethodNode, boolean removeLineNumber)
      TODO 可以考虑实现修改值的功能,原理是传入的 args实际转化为一个stack上的slot,只要在inline之后,把 stack上面的对应的slot保存到想要保存的位置就可以了。
      参数:
      owner -
      tmpToInlineMethodNode -
    • sortTryCatchBlock

      public void sortTryCatchBlock()