增强的 Class 反编译器仍然安装 我无法将 .class 反编译为 .java 源代码?

Enhanced Class Decompiler is installed still I am unable to decompile .class to .java source?

增强Class反编译器仍然安装我无法将.class反编译为.java源?

我正在尝试反编译 java 核心 class - Collections.class - 谁能指导我如何解决这个问题。

我正在使用 STS 4。8.x

根本原因是SpringTools 4中嵌入的JDK不包含源。 Spring Tools 4 应用程序随附嵌入式 JDK(来自 Eclipse JustJ) is currently a new feature, but the missing sources is an issue that will probably be fixed in an upcoming release (according to this tweet by the STS4 main developer)。

作为解决方案(以及嵌入式 JDK 缺失源的解决方法),确保 JDK(不是 JRE)已安装在您的系统中(如果缺少,您可以从AdoptOpenJDK下载JDK)并配置它 Java 中的首选项 > 安装的 JRE.

使用反编译器 hack 的缺点是 Javadoc 会丢失。