简体   繁体   English

在Eclipse调试器中查看sun。*软件包的源

[英]View sources of sun.* packages in Eclipse debugger

I want to be able to step through the code in sun.* packages when I do debug in Eclipse. 在Eclipse中进行调试时,我希望能够逐步浏览sun。*软件包中的代码。 Unfortunately the source code for these packages is not included in Oracle JDK. 不幸的是,这些软件包的源代码未包含在Oracle JDK中。

I found a decompiler plugin for Eclipse that allowed me to do it, but the lines of code Eclipse debugger was pointing to didn't match the decompiled code. 我找到了一个允许我执行的Eclipse反编译器插件,但是Eclipse调试器指向的代码行与反编译的代码不匹配。

I'm using Windows and Java 8 (earlier versions won't work for me). 我正在使用Windows和Java 8(较早的版本对我不起作用)。

  1. Download the source files from the OpenJDK repository OpenJDK存储库下载源文件
  2. In the Java installation directory, add the downloaded source files to the src.zip archive 在Java安装目录中,将下载的源文件添加到src.zip归档文件中

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM