How to Write C++ Source Code Documentation for Autodoc Last updated: January 14 2005
Contact:
Nikolai Pretzell
Content
Basic Rules ScopeThis is a description of how to write documentation within C++ code such it can be automatically parsed by the source code documentation tool Autodoc. Basic Rules
What can be DocumentedDocumentable code entities in C++ are:
All documentation belongs to the next following documentable code
entity. If there are more than one documentation paragraph following
each other, the last one wins. LayoutIf there is no @-tag at the beginning of a documentation paragraph, the first part
of it is interpreted like @short
, if it is not more than two lines and followed
by an empty line. The following layout is required: The following layout is recommended: HTML tags can be used or not. TagsLegendAll tags with parameters can't have any more text in the same line after the parameters. Parameters not enclosed in square brackets [] are required and must be specified. tag required-parameter [optional-parameter] Common Tags
Tags for Classes
Tags for Functions
Tags for Variables
Global Tags
A Typical Documentation/** Short comment: This is for .... .
After an empty line, here comes the main description of the code
entity. Here can be a longer text, examples,
philosophical considerations and special solution descriptions.
After this text, only @-tags are allowed. Each following text belongs
to its prefacing @-tag.
@param integer1 [0 .. 255]
Describe parameter integer1.
@param str2
Describe the parameter str2.
@return true, if everything is ok. Else false.
*/
bool funct_00( int integer1, const char * str2 );
|

