Doxygen:记录具有多个实现的单个 API
Doxygen: Documenting single API that has multiple implementations
假设我有一个 header 文件,其中包含几个函数和多个实现 header 提供的函数的源文件。
我想记录使用 Doxygen 的功能,但只是关于所有实现的一般评论,而不是具体的实现。
仅查看 header 条评论的最佳方式是什么?我无法将配置设置为忽略所有源文件,因为项目中的一些其他源文件根本没有 headers。
例如:
api.h
/**
* @details
* This is general comment for header
*
*********************************************************************/
implemenation1.c
/**
* @details
* This is implementation specific comment for file 1
*
*********************************************************************/
int foo(int a, int b)
{
...
}
implemenation2.c
/**
* @details
* This is implementation specific comment for file 2
*
*********************************************************************/
int foo(int a, int b)
{
...
}
我只想看到关于 Doxygen 的评论:
This is general comment for header
提前致谢!
到目前为止我找到的最好的解决方案是:
api.h
/**
* @details
* This is general comment for header
*
*********************************************************************/
implemenation1.c
/**
* @details
* This is implementation specific comment for file 1
*
* @cond
*********************************************************************/
int foo(int a, int b)
{
...
}
/** @endcond */
implemenation2.c
/**
* @details
* This is implementation specific comment for file 2
*
* @cond
*********************************************************************/
int foo(int a, int b)
{
...
}
/** @endcond */
假设我有一个 header 文件,其中包含几个函数和多个实现 header 提供的函数的源文件。 我想记录使用 Doxygen 的功能,但只是关于所有实现的一般评论,而不是具体的实现。
仅查看 header 条评论的最佳方式是什么?我无法将配置设置为忽略所有源文件,因为项目中的一些其他源文件根本没有 headers。
例如:
api.h
/**
* @details
* This is general comment for header
*
*********************************************************************/
implemenation1.c
/**
* @details
* This is implementation specific comment for file 1
*
*********************************************************************/
int foo(int a, int b)
{
...
}
implemenation2.c
/**
* @details
* This is implementation specific comment for file 2
*
*********************************************************************/
int foo(int a, int b)
{
...
}
我只想看到关于 Doxygen 的评论:
This is general comment for header
提前致谢!
到目前为止我找到的最好的解决方案是:
api.h
/**
* @details
* This is general comment for header
*
*********************************************************************/
implemenation1.c
/**
* @details
* This is implementation specific comment for file 1
*
* @cond
*********************************************************************/
int foo(int a, int b)
{
...
}
/** @endcond */
implemenation2.c
/**
* @details
* This is implementation specific comment for file 2
*
* @cond
*********************************************************************/
int foo(int a, int b)
{
...
}
/** @endcond */