So I have a Java Project in Eclipse for which I can generate a Jar file. Now I can use this jar file in other projects. However when I add this jar file to other project's build path using eg Eclipse, it does not show any documentation.
It only works, if while generating Jar file, I also separately generate java docs, and on the user side, when I import this jar, I have to separately specify the java docs for this jar.
I just want to know, is there any way that I can export java docs and the project altogether as a single jar, so that when imported in other projects using Eclipse IDE it shows the documentation without having to import the java docs explicitly?
如果在导出jar文件时选择“导出源文件和资源”选项,则应该能够在其他项目中查看文档。
@manish approach and don't work for me. In my case the solution was different. You also try do it in four simple steps:
Example
/your-library-v1.0.0.jar
- your-library.jar
- your-library-doc.jar
Now you can Import the library (your-library-v1.0.0.jar) and Javadoc will be vailable in your projects.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.