简体   繁体   English

如何在Eclipse中为jar附加javadoc?

[英]How to attach javadoc for jar in eclipse?

有没有办法在Eclipse中为struts.jar附加javadoc,就像我们为核心Java附加Javadoc一样,核心Java是在JDK下分发的一个zip文件?

For to add the Document to the Library, do the following things. 要将文档添加到库中,请执行以下操作。

Project(Right Click)->Properties->Build Path -> libraries ->JRE System Library then expand each api and Added the location of API. 项目(右键单击)->属性->构建路径->库-> JRE系统库,然后展开每个api并添加API的位置。

Now select the Library for which you want to add the Documents. 现在,选择要为其添加文档的库。

Click on Edit, then Navigate browser to select the Directory of the Documentation directory. 单击编辑,然后单击浏览器以选择文档目录的目录。 Please try with only Directory, not the index.html file. 请仅尝试使用目录,而不尝试使用index.html文件。

右键单击罐子,单击“属性”,然后填充javadoc位置。

First we need to download the source files for any jar file which we are using. 首先,我们需要下载我们正在使用的任何jar文件的源文件。 After that we can attach that zip or jar file to eclipse by using to double click the used java class name and then click on link attach java source and then select respective jar and zip of source file. 之后,我们可以通过双击使用的Java类名称,然后单击链接附加Java源代码,然后选择源文件的相应jar和zip文件,将该zip文件或jar文件附加到eclipse。 It may be that sometimes after attaching the java source zip or jar source file is not opening in that case, you can create jar by using the jar command from command prompt by taking the package which you want to include.And after creating this jar we can attach it through the previous step. 在这种情况下,有时可能无法打开附加的Java源zip或jar源文件后,可以通过从命令提示符处使用jar命令来创建jar,并获取要包含的包。可以通过上一步进行附加。 The source file would definitely be open. 源文件肯定是打开的。

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

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