记录一次GWT编译项目的时候报错:
Loading module 'com.yz.wms.WMS'
Translatable source found in...
[WARN] No source path entries; expect subsequent failures
com.google.gwt.core.ext.typeinfo.NotFoundException: java.lang.Object
at com.google.gwt.core.ext.typeinfo.TypeOracle.refresh(TypeOracle.java:544)
at com.google.gwt.dev.javac.TypeOracleMediator.refresh(TypeOracleMediator.java:394)
at com.google.gwt.dev.javac.CompilationState.compile(CompilationState.java:137)
at com.google.gwt.dev.GWTCompiler.distill(GWTCompiler.java:327)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:564)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:554)
at com.google.gwt.dev.GWTCompiler.main(GWTCompiler.java:214)
Compiling module com.yz.wms.WMS
Computing all possible rebind results for 'com.yz.wms.client.WMS'
Rebinding com.yz.wms.client.WMS
Checking rule <generate-with class='com.google.gwt.user.rebind.ui.ImageBundleGenerator'/>
[ERROR] Unable to find type 'com.yz.wms.client.WMS'
[ERROR] Hint: Previous compiler errors may have made this type unavailable
[ERROR] Hint: Check the inheritance chain from your module; it may not be inheriting a required module or a module may not be adding its source path entries properly
[ERROR] Build failed
在对项目进行编译时报com.google.gwt.core.ext.typeinfo.NotFoundException: java.lang.Object,
原因:是由于Eclipse引用不同版本JDK工程时会发生该问题。由于你开发环境中应用了多个版本的JDK 或JRE导致的。Eclipse会按照最初的开发环境默认选择对应的Jre。如Eclipse上有jdk1.6开发的环境工程,当你在引入高版本jdk1.8开发的工程时,以上问题就出现了。”
通过把本地jdk降到1.6后重新编译,成功!