In Eclipse, when you press Ctrl button and click on any  Class names, the IDE will take you to the source file for that class.  This is the normal behavior for the classes you have in your project.

But, in case you want the same behavior for Java’s core classes too,  you can have it by attaching the Java source with the Eclipse IDE. Once  you attach the source, thereafter when you Ctrl+Click any Java class names (String for example), Eclipse will open the source code of that class.

To attach the Java source code with Eclipse,

  1. When you install the JDK, you must have selected the option to install the Java source files too. This will copy the src.zip file in the installation directory.
  2. In Eclipse, go to Window -> Preferences -> Java -> Installed JREs -> Add and choose the JDK you have in your system.
  3. Eclipse will now list the JARs found in the dialog box. There, select the rt.jar and choose Source Attachment. By default, this will be pointing to the correct src.zip. If not, choose the src.zip file which you have in your java installation directory.
  4. Similarly, if you have the javadoc downloaded in your machine, you can configure that too in this dialog box实际上就是将src.jar 这个包附加

最新文章

  1. article和section
  2. 【poj2699】 The Maximum Number of Strong Kings
  3. a little about hashtable vs dictionary
  4. 记一次hadoop datanode进程问题分析
  5. CentOS下安装setuptools、pip和virtualenv
  6. java生成带html样式的word文件
  7. SQLserver行转列与列转行
  8. .net程序员必须知道的知识
  9. sql like 通配符 模糊查询技巧及特殊字符
  10. centos7 设备 mariadb-10
  11. 双链表---LinkedList的重写
  12. Discuz 楼主帖子采集
  13. 字体类形:font-family, font-style
  14. extremecomponents
  15. zabbix回顾
  16. 从URL输入到页面展现到底发生什么
  17. 自建yum源解决Ceph搭建过程中从官网取包慢的问题
  18. 关于OSG+QT+VS版本的问题
  19. Edraw安装图解
  20. ARM ® and Thumb ®-2 指令系统

热门文章

  1. Docker - 记录在window 上的一些“坑”
  2. PyQt 5布局管理
  3. 简单租房子实例详解---(session、ajax、json前后台数据处理、分页)
  4. 查看Unix/Linux的CPU个数和内存大小,系统位数(转载)
  5. 02——微信小程序官方demo讲解——app部分
  6. spring aop实现拦截接口请求打印日志
  7. svn ignore 的用法(忽略文件及目录)
  8. ie6绝对定位的块会被select元素遮挡的解决方案
  9. leetcode840
  10. e8000051