Rewriting Java native methods using ASM
问题 I'm trying to do this by re-writing the bytecode of the class using ASM 4.0 to replace all the native methods with non- native stubs. So far I have this: class ClassAdapter extends ClassVisitor { public ClassAdapter(ClassVisitor cv) { super(Opcodes.ASM4, cv); } @Override public MethodVisitor visitMethod(int access, String base, String desc, String signature, String[] exceptions) { return cv.visitMethod(access & ~Opcodes.ACC_NATIVE, base, desc, signature, exceptions); } } which is executed by