实现类里面使用了 @Override
在1.5下要使用@Override 这个annotation 必须保证 被标注方法来源于class 而不是interface
解决方法:将项目的jdk从1.5改为1.6
操作步骤:window ->preferences... -> Java -> Compiler ->Compiler compliance level : 1.6
本文介绍了解决在Java 1.5中使用@Override注解时遇到的问题,即该注解只能用于实现类的方法而非接口的方法。通过将项目的JDK版本升级到1.6,可以消除这一限制。
实现类里面使用了 @Override
在1.5下要使用@Override 这个annotation 必须保证 被标注方法来源于class 而不是interface
解决方法:将项目的jdk从1.5改为1.6
操作步骤:window ->preferences... -> Java -> Compiler ->Compiler compliance level : 1.6
3465
1755
1022
1775
1451

被折叠的 条评论
为什么被折叠?