011_用eclipse打开hadoop1.2.1源码出现The method getSplits(JobConf, int) is undefined for the type Object错误
来源:互联网 发布:淘宝怎么申请售后退款 编辑:程序博客网 时间:2024/06/08 03:59
出现的错误截图:
此时Eclipse使用的jdk1.8,将编译环境改成jdk1.7就行了,解决。
没问题了。
下面观点是参考如下网址,未经验证。参考:http://blog.csdn.net/oneinmore/article/details/45332279
这些都是泛型相关的错误,因此我猜测是eclipse在解析代码时对于泛型都要临时生成一些类,而这些类的生成方法在不同版本的jdk中是不同的, 又因为实际使用的jre与java compiler的compliance level不同,所以导致解析代码时信息的生成的解读发生错误,从而出现上面的错误。
可能不安装两个jdk就不会碰到此类问题(我周边其他人就没碰到过类似错误,呵呵)。
设置完成之后返回"New Java Project"对话框,选择使用"Use default JRE"即可(设置之后应该显示currently 'jre7')。然后再将Location选择为我们在上面定义的HADOOP_LOCATION(好像要最后定location,因为location定好后,jre配置就不能修改了),然后点击"Finish"按钮,等待eclipse执行building workspace操作。building完了之后,显示eclipse界面,此时将”Welcome"页面关掉(如果出现的话)。然后就显示出来"package explorer",至此我们完成新建一个java项目的操作了。
0 0
- 011_用eclipse打开hadoop1.2.1源码出现The method getSplits(JobConf, int) is undefined for the type Object错误
- The method setDefaultCloseOperation(int) is undefined for the type
- The method getTextContent() is undefined for the type Node错误
- The method getTextContent() is undefined for the type Node错误
- The method swipe(int, int, int, int, int) is undefined for the type AppiumDriver
- eclipse中NodeList出现The method getTextContent() is undefined for the type Node
- 出现错误:The method getCriteriaBuilder() is undefined for the type EntityManager.
- The method setProgress(int, int, boolean) is undefined for the type NotificationCompat.Builder
- "The method findViewById(int) is undefined for ..."
- "The method width(int) is undefined for the type SmoothProgressDrawable.Builder"
- fragment 里需要activity。Android-The method findViewById(int) is undefined for the type first (Fragment)
- The method findViewById(int) is undefined for the type FragmentHome报错
- 错误:The method replace(int, Fragment) in the type FragmentTransaction is not applicable for the argum
- 错误:The method replace(int, Fragment) in the type FragmentTransaction is not applicable for the argum
- getTextContent()方法出现The method getTextContent() is undefined for the type Node提示
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory!
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
- 08_三大配置文件和五大守护进程
- 07_Warning $HADOOP_HOME is deprecated.去除办法
- 09_Hadoop启动或停止的三种方式及启动脚本
- 010_Hadoop配置测试成功后关机重启浏览器打不开dfs和MP
- springframework(五)资源国际化
- 011_用eclipse打开hadoop1.2.1源码出现The method getSplits(JobConf, int) is undefined for the type Object错误
- PE 441
- 011_Eclipse中使用HDFSFileSystemAPI事例介绍
- 012_Eclipse中使用 HDFS URL API 事例介绍
- 013_HDFS文件合并上传putmarge功能(类似于hadoop fs -getmerge)
- 014_HDFS存储架构、架构可靠性分析、副本放置策略、各组件之间的关系
- 【软件测试】APP停止运行的bug分析
- 015_[小插曲]看黄老师《炼数成金Hadoop应用开发实战案例》笔记
- 016_笼统概述MapReduce执行流程结合wordcount程序