IBM RAD With Java 1.5 不会编译带有泛型的代码
我有一些代码中包含通用引用,但我的 IBM RAD IDE 不会编译该代码,而是将其视为错误。我已经检查了它在所有企业项目中指向的 JRE 版本,我被告知它支持泛型,它是 1.5。我还检查了 WAS 的所有库都指向正确的版本,并且编译器合规级别设置正确(它是 5.0,我将其更改为 6.0,但也没有运气)
@@EDIT - 回答以下问题下面的评论我使用的是 RAD 版本 7.0.0.10,是的,我检查了整个 IDE 的编译器属性以及存在问题的单个项目 - 尝试将这两个项目都指向本地 jre6,但仍然无法编译它。
@@编辑 - 我没有提到我还检查了 JDK 和 JRE 的版本,它们都是 1.5 - 我用于该项目的 JDK 和 IDE 如下:C:\Program Files\IBM\ SDP70\jdk\bin\java.exe 和 C:\Program Files\IBM\SDP70\jdk\jre\bin\java.exe 都是版本 1.5
有没有人对我可以尝试的其他内容有任何建议?我一直在 RAD 上遇到这样的问题,我不知道其他人的情况,但他们采取了 eclipse 并使其变得复杂且功能失调。
I have some code that has generic references in it and my IBM RAD IDE will not compile the code, instead treating it as an error. I have checked the version of the JRE its pointing to across all the Enterprise Project's and it is 1.5 which I am told does support generics. Also I checked that all the libraries for WAS were pointing to the correct version and that the Compiler Compliance Level was set correctly (which it was at 5.0 and i changed it to 6.0 with no luck either)
@@EDIT - to answer the question of the comment below I am using RAD version 7.0.0.10 and yes I checked the compiler properties of the entire IDE as well as the individual project that was having issues - tried pointing both of these to a local jre6 and still cannot get it to compile.
@@EDIT - I did not mention that I did also check the version of the JDK and the JRE and they are both 1.5 - the JDK i am using for the project and the IDE are as follows: C:\Program Files\IBM\SDP70\jdk\bin\java.exe and C:\Program Files\IBM\SDP70\jdk\jre\bin\java.exe and again both are version 1.5
Does anyone have any suggestions as to anything else I can try? I have issues like this with RAD all the time and I dont know about anyone else but they took eclipse and made it complicated and dysfunctional.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
事实证明,JRE 系统库和 Websphere Application Server 库指向了错误的位置 - 它们被标记为 Websphere Portal 6.1 而不是 Websphere Application Server 6.1 - 谁知道该包有什么 JRE/JDK 配置 - 我非常非常抱歉浪费了大家的时间,这是我直到出于好奇而向右滚动才看到的东西。
谢谢
Turns out the JRE System Library and the Websphere Application Server libraries had been pointing to the wrong place - they were marked as Websphere Portal 6.1 and not Websphere Application Server 6.1 - and who KNOWS what JRE/JDK configurations that package had - I am very very sorry for wasting everyone's time, this was something I did not even see until I scrolled to the right out of curiosity.
Thanks
检查 RAD 中的 Java 编译器设置。这与使用的 JRE 是分开的,因此即使使用 Java 6 运行时,编译器仍可能设置为 Java 1.4。
Check the Java compiler settings in RAD. This is separate from the JRE used, so even with a Java 6 runtime, the compiler may still be set to Java 1.4.