问答详情
源自:2-2 使用AOP处理请求(中)

使用aop,配置Pointcut有问题

版本跟老师的一致,步骤也一样 老师的

@Pointcut("execution(public * com.springboot.controller.*(..))")

会报错

http://img.mukewang.com/58c7fcad00019dc904560450.jpg

http://img.mukewang.com/58c7fcae00017b5120560068.jpg

后来在简书看到篇文章按照上面的来写就正常了

http://img.mukewang.com/58c7fcef0001b7b010620732.jpg@Pointcut("execution(public * com.springboot.controller..*.*(..))")

提问者:繁华乱浮华 2017-03-14 22:24

个回答

  • 慕粉3489210
    2017-03-14 22:39:42
    已采纳

    要写到controller包下的具体的一个类

    http://img.mukewang.com/58c800970001ea0202790126.jpg

    http://img.mukewang.com/58c800980001089a05610050.jpg