[Doxygen-users] Documenting abstract methods in C++
Brought to you by:
dimitri
|
From: Martin Knapp-C. <ma...@ma...> - 2006-02-17 22:11:08
|
Hello,
Doxygen version: 1.4.5
Platform: Linux
Output: HTML
I have a question about documenting abstract methods in C++.
Consider the following class outline:
class svFile
{
public:
virtual bool access(int) = 0;
...
private:
...
};
Consider the following two ways to document access() assuming a brief
comment only in the class definition above after the declaration.
----------------------------------------------------------------
Case 1 (With @brief)
------
virtual bool access(int) = 0; /**<@brief (ABSTRACT) Do you have
specific access? */
Output:
1. svFile class reference page
Public Member Functions
virtual bool access(int) = 0;
(ABSTRACT) Do you have specific access?
Member Function Documentation
<nothing about access>
----------------------------------------------------------------
Case 2 (No @brief)
------
virtual bool access(int) = 0; /**< (ABSTRACT) Do you have specific
access? */
Output:
1. svFile class reference page
Public Member Functions
virtual bool access(int) = 0;
<no brief comment>
Member Function Documentation
virtual bool svFile::access ( int ) [pure virtual]
(ABSTRACT) Do you have specific access?
Implemented in svCatContainer, svCatContainerFile, svStdContainer, and
svStdContainerFile.
----------------------------------------------------------------
I really want the UNION of Case 1 and Case 2, namely:
----------------------------------------------------------------
Output:
1. svFile class reference page
Public Member Functions
virtual bool access(int) = 0;
(ABSTRACT) Do you have specific access?
Member Function Documentation
virtual bool svFile::access ( int ) [pure virtual]
(ABSTRACT) Do you have specific access?
Implemented in svCatContainer, svCatContainerFile, svStdContainer, and
svStdContainerFile.
----------------------------------------------------------------
Any ideas?
Sincerely,
Martin Knapp-Cordes
---------------------------------------------------------------
| Martin Knapp-Cordes ma...@ma... |
| The MathWorks, Inc. http://www.mathworks.com |
| 3 Apple Hill Drive Natick, MA 01760 |
| Tel: (508) 647-7321 Fax: (508) 647-7015 |
---------------------------------------------------------------
|