We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
What should I do? When I try to call a generic method, an exception is thrown directly in MethodCall#getMethod().
private void analyzeMethodCalls(String className, CtMethod method) throws NotFoundException, CannotCompileException { method.instrument(new ExprEditor() { @Override public void edit(MethodCall m) throws CannotCompileException { String runMethodName = method.getName(); String runClassName = method.getDeclaringClass().getName(); String callClassName = m.getClassName(); String callMethodName = m.getMethodName(); String fileName = m.getFileName(); Integer lineNumber = m.getLineNumber(); try { // TODO: Let's compare here. The generic function calls m.getMethod() and directly throws an exception. CtMethod calledMethod = m.getMethod(); CtClass callCtClass = calledMethod.getDeclaringClass(); if (!scanPackagePrefix.stream().allMatch(runClassName::startsWith)) { return; } if (callCtClass.isInterface()) { // 打印每个接口的执行结果 if (interfaceImplMap.containsKey(callCtClass)) { for (CtClass callImplClass : interfaceImplMap.get(callCtClass)) { CtMethod overrideMethod = callImplClass.getDeclaredMethod(calledMethod.getName(), calledMethod.getParameterTypes()); analyzeMethodCalls(callImplClass.getName(), seekImplInterfaceMethod(overrideMethod)); } } }
The text was updated successfully, but these errors were encountered:
For example, the save method in mybatis-plus
Sorry, something went wrong.
No branches or pull requests
What should I do? When I try to call a generic method, an exception is thrown directly in MethodCall#getMethod().
The text was updated successfully, but these errors were encountered: