@Override is not allowed when implementing interface method详解程序员
程序员 详解 not is Allowed when method interface
2023-06-13 09:19:55 时间
使用idea导入maven项目时 会出现如下报错
@Override从jdk1.5开始出现的,是用来标注方法重写;通常方法重写发生在继承父类,重写父类方法,或者实现接口,实现接口方法;
@Override能够保证你正确重写方法,当重写方法出错时(方法名误写、漏掉参数)编译器会提示编译错误
1.问题出在idea得jdk版本低于1.5 :File → Project Structure → Modules 把JDK版本改成大于1.5就可以了
2.pom文件中配置maven-compiler-plugin
plugin groupId org.apache.maven.plugins /groupId artifactId maven-compiler-plugin /artifactId version 3.2 /version configuration source 1.7 /source target 1.7 /target /configuration /plugin
原创文章,作者:Maggie-Hunter,如若转载,请注明出处:https://blog.ytso.com/1531.html
服务器部署程序员系统优化网站设置运维相关文章
- nginx平滑重启详解程序员
- linux启动进程报$’/r’: command not found错误详解程序员
- remote staging type or host is not specified详解程序员
- IntelliJ IDEA 中创建maven项目详解程序员
- MyEclipse server窗口 Could not create the view: An unexpected exception was thrown 错误解决详解程序员
- war包部署后,提示File “/struts-tags” not found详解程序员
- Jvm虚拟机结构与机制详解程序员
- Could not publish server configuration for Apache Tomcat v6.0. Multiple Cont详解程序员
- IntelliJ Idea解决Could not autowire. No beans of ‘xxxx’ type found的错误提示详解程序员
- nginx配置C compiler cc is not found详解程序员
- 我的Base64编码,去掉等号特殊字符详解程序员
- Swoole学习(四)Swoole之简单WEB服务器的创建详解程序员
- crontab定时任务详解程序员
- centos7 yum与Python3冲突详解程序员
- Ubuntu 16.04下添加新用户详解程序员
- 简单说明CentOS源码安装程序详解程序员
- Linux命令之yum详解程序员
- Linux命令之vim(二)详解程序员
- checking for C compiler … not found详解程序员
- 利用shell监控cpu、磁盘、内存使用率详解程序员
- shell条件测试语句实例-测试apache是否开启详解程序员
- Linux下shell脚本监控Tomcat的状态并实现自动启动详解程序员
- Linux老是提示compat-libstdc++ is not installed的原因详解程序员
- Nginx 禁用IP IP段详解程序员
- Remote System Explorer Operation总是运行后台服务,卡死eclipse详解程序员
- 数据库索引详解程序员
- linux 文件套接字详解程序员