Doxygen和package.html [英] Doxygen and package.html

查看:81
本文介绍了Doxygen和package.html的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

根据javadoc规范,我在相关软件包的根目录中放置了一个名为package-info.html的文档文件.但是,当我在该文件夹上运行Doxygen时,此文件中的文档没有被提取.我如何告诉Doxygen使用此文件作为软件包文档?我也尝试了旧的规范package.html,但这还是行不通的.

As per javadoc specifications, I placed a documentation file called package-info.html in the root directory of the relevant package. When I run Doxygen on that folder, however, the documentation in this file is not picked up. How do I tell Doxygen to use this file as the package documentation? I also tried package.html, the old specification, but that doesn't work., either

推荐答案

为Java包提供文档的另一种新方法是使用名为package-info.java的文件而不是package.html. (文件名是故意选择的,不是有效的类名.)

The new alternative way to provide documentation for a Java package is to use a file named package-info.java instead of package.html. (The file name is intentionally chosen not to be a valid class name.)

它具有不同的语法:

/**
 * any javadoc comments (including tags)
 */
package name;

这也是提供程序包注释的唯一方法(如果有的话,在此处在package关键字之前进行注释).

This is also the only way to provide package annotations (which are noted before the package keyword here, if any).

从您的评论到问题,看来Doxygen的最新版本仅了解此package-info.java,而不了解旧的package.html文件.

From your comments to the question, it looks like recent versions of Doxygen only understand this package-info.java, not the old package.html file.

我记得有一个提议的模块系统,然后将添加一个类似的module-info.java文件,但是经过短暂的搜索,我现在找不到它. (也许是JSR 294吗?)

I recall there being a module system proposed, which then would add a similar module-info.java file, but I don't find it now after a short googleing. (Maybe JSR 294?)

这篇关于Doxygen和package.html的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆