Doxygen Comment Example Version 1.0
Functions
doxygen_example.cpp File Reference

Illustrates doxygen-style comments for documenting a C++ program file and the functions in that file. More...

#include <iostream>
#include <string>

Functions

void DoSomething (int numberOfPositions, char &firstInitial, string &stringOfInitials)
 A single statement goes here to give a high-level description of the function, which is ended by the first period.
int numberOfDigits (int n)
 Compute and return the number of digits in a positive integer.
int main ()

Detailed Description

Illustrates doxygen-style comments for documenting a C++ program file and the functions in that file.

Author:
Lastname:Firstname:A00123456:cscxxxxx
Version:
Revision 1.1

If you want to add any further detailed description of what is in the file, then place it here (after the first statement) and it will appear in the detailed description section of the HTML output description for the file.

Date:
Monday, September 19, 2011

Function Documentation

void DoSomething ( int  numberOfPositions,
char &  firstInitial,
string &  stringOfInitials 
)

A single statement goes here to give a high-level description of the function, which is ended by the first period.

Any further description of the function, such as this statement that comes after the first statement, will appear as part of the "detailed description" for this function. The brief description may also be repeated here immediately prior to the detailed description, but the configuration file for this example is currently set to disable that feature.

Returns:
void
Parameters:
numberOfPositionsThe number of positions firstInitial is to be moved forward.
firstInitialA character representing the first letter in a person's first name (for example).
stringOfInitialsA string in which all characters are the same.
Precondition:
  1. numberOfPositions contains a positive integer.
  2. firstInitial contains a printable character at least numberOfPositions positions from the end of the printable character set.
Postcondition:
  1. firstInitial contains the character numberOfPositions to the right of its original value.
  2. stringOfInitials contains a string of length numberOfPositions in which each character is the original value of firstInitial.
int numberOfDigits ( int  n)

Compute and return the number of digits in a positive integer.

The style used for the pre/post coditions of this function is purposely different from that for the void function given above, just so you can see the differnce in the HTML output.

Returns:
The number of digits in n.
Parameters:
nAn integer, the number of whose digits is desired.
Precondition:
n contains a positive integer. This is some other precondition, and note that it does not start on a new line.
Postcondition:
The number of digits in n has been returned.
This is some other post condition, and note that it does start on a new line.
int main ( )
 All Files Functions