use of org.apache.tapestry5.internal.plastic.asm.commons.JSRInlinerAdapter in project tapestry-5 by apache.
the class PlasticInternalUtils method convertBytecodeToClassNode.
public static ClassNode convertBytecodeToClassNode(byte[] bytecode) {
ClassReader cr = new ClassReader(bytecode);
ClassNode result = new ClassNode();
ClassVisitor adapter = new ClassVisitor(Opcodes.ASM9, result) {
@Override
public MethodVisitor visitMethod(int access, String name, String desc, String signature, String[] exceptions) {
MethodVisitor delegate = super.visitMethod(access, name, desc, signature, exceptions);
return new JSRInlinerAdapter(delegate, access, name, desc, signature, exceptions);
}
};
cr.accept(adapter, 0);
return result;
}
Aggregations