java.lang.Object can not be resolved. It is indirectly referenced from required .class files

左心房为你撑大大i 提交于 2019-12-24 09:58:08

问题


i am using eclipse 3.2 version. in sametime based i am getting error on package: java.lang.Object can not be resolved. It is indirectly referenced from required .class files.

on build path JRE is JRE System Library [JavaSE-1.6] (unbound)

when i set the JRE is JRE System Library [jclDesktop Win32 x86] then it give others errors like on function name of other classes.


回答1:


There are a lot of differences between jclDesktop and Java 5. Which means, that Java code, written for Java 5 (or any other Sun/Oracle Java) will probably not compile with jclDesktop.

You can use jclDesktop as a JRE system library if you want to write applications for jclDesktop. If you have one Java application and want to convert it to jclDesktop, then you'll have to resolve all the compile time errors (and hope for the best).

Otherwise, install an Oracle Java SDK (JRE is enough although I'd recommend a JDK which comes with the src.zip file) and use that as JRE library.




回答2:


Try to delete the .class file / bin folder from the project. Make a clean build after that and the error will go away.



来源:https://stackoverflow.com/questions/5715033/java-lang-object-can-not-be-resolved-it-is-indirectly-referenced-from-required

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!