We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 10 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(8)
直接链接是这个。
如果您想知道如何获得此链接,请关注 此链接,不同之处在于,对于 jdk 7 源,选择“jdk7/jdk7-gate/jdk”而不是“jdk6/jdk6-gate/jdk”。
The direct link is this.
If you wonder how this link is got, follow this link, except that select "jdk7/jdk7-gate/jdk" instead of "jdk6/jdk6-gate/jdk" for jdk 7 sources.
对于JRE中的Java源代码,这个网站比OpenJDK7的hgweb更有用。
For Java source codes in JRE, this website is more useful than hgweb for OpenJDK7.
这是 OpenJDK 的存储库,
对于 Oracle 的 JDK7,有二进制文件和文档,但没有可供浏览的源代码。
This is the repository for OpenJDK
As for Oracle's JDK7, there are binaries and docs, but no source to browse.
我发现 http://www.codatlas.com 是阅读 java 代码的一个非常方便的地方。例如,您可以在这里找到开放的 JDK7 源代码:
http://codatlas .com/github.com/lambdalab-mirror/jdk7u-jdk/master/
它最大的优点是除了@Jakub在他的回答中提到的语法高亮之外,它还支持交叉引用,这将使得代码浏览体验更好轻松 10 倍。
它还有许多其他基于 JVM 的项目(Apache Hadoop、ElasticSearch 等)。它还支持 ruby 和 python 等脚本语言,但目前性能不是很好。
I find http://www.codatlas.com to be a very handy place to read java code. For example you will find open JDK7 source code here:
http://codatlas.com/github.com/lambdalab-mirror/jdk7u-jdk/master/
It's biggest advantage is that besides syntax highlighting as @Jakub mentioned in his answer, it also supports cross reference, which will makes the code browsing experience 10x easier.
It has bunch of other JVM based projects too (Apache Hadoop, ElasticSearch etc.). It also supports scripting language like ruby and python but the performance is not great at this moment.
您可以在这里找到源文件 jdk7source
当我发现这个问题时我正在寻找它,这就是为什么我决定添加这个答案,因为其他答案都没有它,但没有可供浏览的网络界面。
You can find the source files here jdk7source
I was looking for it when I found this question and that is why I decided to add this answer, as none of the other answers have it, but there is no web interface for browsing.
GitHub上有JDK7源码镜像。更易于浏览,并具有语法突出显示。
There is JDK7 source code mirror on GitHub. Easier to browse, and with syntax highlighting.
我不认为 Sun JDK 的源代码是公开的。为什么不尝试 OpenJDK Mercurial repos
希望有所帮助。
I don't think that the source of the Sun JDK is openly available. Why not try the OpenJDK Mercurial repos
Hope that helps.
如果您想在本地浏览源。
然后就可以在src.zip文件的jvm目录下找到源码了。
对于 Linux 环境,该文件位于 /usr/lib/jvm/java-7-oracle
If you want to browse the source locally.
Then you can find the source in the jvm directory in the src.zip file.
for linux environments the file is located in /usr/lib/jvm/java-7-oracle