InterceptorRef cannot be resolved to a type 错误解决办法

来源:互联网 发布:好看的仙侠言情文 知乎 编辑:程序博客网 时间:2024/06/06 07:16

        今天在通过注解写Interceptor时,在使用@InterceptorRef时,一直出现InterceptorRef cannot be resolved to a type。按经验,这一般是没导包的提示吧,然后把鼠标放在这个上面,也没有导包的选项,那么问题来了,是没导包么?

       好吧,有时在做项目时确实会出现不会出现导包选项的情况,那么我们就手动写一条吧,import org.apache.struts2.convention.annotation.InterceptorRef;导进去就没问题了。

0 0
原创粉丝点击