Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个基本问题......无法找出它为什么不起作用......当我使用 @Override 注释时,下面的代码不起作用。请帮忙
public class QuartzJob implements ApplicationListener<ContextRefreshedEvent> { @Override public void onApplicationEvent(ContextRefreshedEvent event) { } }
我的猜测是,您正在为 Java 1.5 进行编译,并且只有从 Java 1.6 实现接口方法才有可能(并且风格很好)添加@Override.
@Override