如何配置 Doxygen 只为一个文件生成文档?

How do I configure Doxygen to generate docs for only one file?

我想为一个非常大的项目的单个 Java class 生成文档。我怎么做?我很确定几年前我做过。它有很多依赖关系,所以我不能只将 class 复制到另一个目录。

我可以使用命令行或 OS X Doxywizard。

当你想使用 doxygen 从一个文件生成文档时,比如 aa.java 可以使用普通的 doxygen 配置文件并在其中设置:

INPUT = aa.java

取决于文件中的所有内容 aa.java 您可能必须使用

EXCLUDE_SYMBOLS = 

还有

参见(摘自 doxygen 手册,http://doxygen.nl/manual):

  • 输入:http://doxygen.nl/manual/config.html#cfg_input

    The INPUT tag is used to specify the files and/or directories that contain documented source files. You may enter file names like myfile.cpp or directories like /usr/src/myproject.

  • EXCLUDE_SYMBOLS: http://doxygen.nl/manual/config.html#cfg_exclude_symbols

    The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names (namespaces, classes, functions, etc.) that should be excluded from the output. The symbol name can be a fully qualified name, a word, or if the wildcard * is used, a substring. Examples: ANamespace, AClass, AClass::ANamespace, ANamespace::*Test