private void printMethod(JoinPoint joinPoint, String name) throws NoSuchMethodException { MethodSignature signature = (MethodSignature) joinPoint.getSignature(); Class<?> clazz = joinPoint.getTarget().getClass(); Method method = clazz.getMethod(signature.getName(), signature.getParameterTypes()); System.out.printf("[MethodLogAspect]切面 %s 打印 -> [className]:%s -> [methodName]:%s -> [methodArgs]:%s%n", name, clazz.getName(), method.getName(), Arrays.toString(joinPoint.getArgs())); }
https://blog.csdn.net/scm_2008/article/details/128593857
标签:被切,getName,joinPoint,切点,clazz,signature,方法 From: https://www.cnblogs.com/leiqun123/p/17965540