How do I import JDK source code into eclipse or Intellij idea?

Source: Internet
Author: User

The main is to the JDK involved in the multi-threaded source into IntelliJ idea;

Facilitate the source code annotation, tracking, and drawing UML diagram;


The main steps are as follows:

1. Download JDK Source code

Mode one: Download directly from the address below (I am using this method)

Https://github.com/fanhongtao/JDK

Method Two: Obtained from the JDK's Rt.jar package, e.g. Jdk1.8.0_112\jre\lib\rt.jar

Decompression Rt.jar

650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M00/08/4E/wKiom1nfNNzynGv4AAD3mpVXigI984.png "title=" 001. PNG "alt=" Wkiom1nfnnzyngv4aad3mpvxigi984.png "/>


2. Using IntelliJ idea to create a common Java project

3, copy the source code about multithreading,

Note that copying is not recommended to copy only java\util\concurrent this package//otherwise, the package path in the class is not correct,

The entire Java package needs to be copied to the newly created Java project,

In this way, the JDK source code can be annotated, updated, parallel to the source tracking


650) this.width=650; "src=" Https://s2.51cto.com/wyfs02/M00/08/4E/wKiom1nfNTSh3poXAABQeL0eHV8540.png "title=" 002. PNG "alt=" Wkiom1nfntsh3poxaabqel0ehv8540.png "/>


The effect is as follows:


650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M01/A7/05/wKioL1nfMyTSkG4cAAGV7igxYlY586.png "title=" 003. PNG "alt=" Wkiol1nfmytskg4caagv7igxyly586.png "/>

The code has been uploaded to Git.

Https://github.com/xej520/xingej-analysis-jdk-concurrent




This article is from the "Xej Distributed Studio" blog, so be sure to keep this source http://xingej.blog.51cto.com/7912529/1971805

How do I import JDK source code into eclipse or Intellij idea?

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.