annotation:@Override出现The method of type must override asuperclass解决方案
原因追踪及解决办法:
1. 查阅资料发现说在jdk1.5下要使用@Override这个annotation必须保证被标注的方法来源于class而不是interface.
2. 即使自己的jdk是1.6,还需要修改myeclipse里面的编译jdk版本,从1.5(5.0)改成1.6(6.0),否则还会出现上述错误。
解放办法:在myeclipse下:Windows-Preferences-Java Compiler,在右边的Compiler Compliance Level 修改成1.6(6.0)版本。
此时如果发现还是上述错误
原因是项目还没有吧jre变成1.6(6.0)
解决办法:项目右键->build path->configure build path->java Complier(在左边那一排)->右边的Complier compliance level修改为1.6(6.0)版本。
参考:http://www.douban.com/note/228294911/annotation:@Override出现The method of type must override asuperclass解决方案的更多相关文章
- The method of type must override a superclass method解决方式
工程导入myeclipse时,出现问题提示:The method of type must override asuperclass? annotation:@Override的原因 查阅了一下资料, ...
- (转)轻松解决 MyEclipse、Eclipse 编译时提示 @Override The method of type must override a superclass method 即 @Override 标注问题
刚才在把工程从其他地方导入到自己机子的 MyEclipse 下时,出现了 The method of type must override a superclass method ,提示的是实现类必须 ...
- The method of type must override a superclass method
导入android项目时,报The method of type must override asuperclass method 一堆错误, 解决方法: 将编译的jdk与使用的jdk版本一致即可.
- The method of type must override a superclass method解决方式(转)
今天做struts2上传文件的时候出现了这个问题: The method execute() of type UploadAction must override or implement a sup ...
- bug2 The method of type must override a superclass method解决方式(去掉@override可以)
@Override 时出错误: 解决办法是: 一. 因为你的Co ...
- 【转】@Override must override a superclass method 问题解决
原文网址:http://www.blogjava.net/anchor110/articles/339352.html 如果在使用Eclipse开发Java项目时,在使用 @Override 出现以下 ...
- @Override must override a superclass method 有关问题解决
1.Java开发环境时 如果在使用Eclipse开发Java项目时,在使用 @Override 出现以下错误: The method *** of type *** must override a s ...
- myeclipse中出现The method xxx of type must override or implement a supertype
出现问题提示:The method xxx of type must override or implement a supertype? annotation:@Override的原因 查阅了一下资 ...
- onClick(View) of type new View.OnClickListener(){} must override a superclass method
原地址:http://blog.csdn.net/aeolus1019/article/details/8014798 Android开发过程中代码错误报错如下: - implements andro ...
随机推荐
- paip.基于urlrewrite的反向代理以及内容改写
paip.基于urlrewrite的反向代理以及内容改写 ---------反向代理 RewriteCond %{REQUEST_URI} !=/process.php RewriteRule ^( ...
- C#中使用DES和AES加密解密
C#中使用DES和AES加密解密 2008-01-12 09:37 using System;using System.Text;using System.Security.Cryptography; ...
- css之属性及剩余的选择符
今天的课程加速了,比平时快了些,但觉得很不错.nice~ 属性选择符 E[att] 选择具有att属性的E元素. input[type]{color: #red;} <input t ...
- MyEclipse8.6中提交SVN报错
上周五(11月27日)的时候,从TortoiseSVN提交项目报错,然后直接从MyEclipse中检出来,修改后提交同样报错. MyEclipse8.6中提交SVN报错,错误提示如下: commit ...
- U盘启动笔记本无法安装Win7问题和解决
用“大白菜”工具制作启动U盘,从U盘启动后进入Win PE环境安装Win7,提示“安装win7系统安装程序无法创建新的系统分区,也无法定位现有系统分区”.经以下各种努力后仍无法正常安装: 在BIOS里 ...
- android: UriMatcher的用法
ContentProvider是Android四大组件之一,网上也有不少关于它的文章,基本用法都可以查到,但关于UriMatcher在其中的作用,文章中都有例子,但我觉得还没有说清楚. 先说为什么用U ...
- aehyok.com的成长之路一——开篇
前言 不得不说最近三个月都没更新博客了,除了6月初的一篇博客外,今天的这一篇算是这三个月里发表的第二篇博客了.不过本人几乎每天都在博客园里刷来刷去,看大家发表的博文,从中汲取营养.确实博客园也可以 ...
- Bitmap和Drawable相互转换方法
很多开发者表示,不知道Android的Drawable和Bitmap之间如何相关转换.下面给大家两种比较简单高效的方法. 一.Bitmap转Drawable Bitmap bm=xxx; //xxx根 ...
- Mysql 如何设置字段自动获取当前时间
应用场景: 1.在数据表中,要记录每条数据是什么时候创建的,不需要应用程序去特意记录,而由数据数据库获取当前时间自动记录创建时间: 2.在数据库中,要记录每条数据是什么时候修改的,不需要应用程序去特意 ...
- Android 在xml中配置 float 和 integer 值
一.float的配置方法 andriod 默认不支持float型的设置,在values 下的新建floats.xml 文件,在内部添加如下代码: <resources> <item ...