Document the code with Doxygen
This is obsolete: we do not document our code anymore with Doxygen.
Documenting structs
1 /**
2 * A structure to represent 3d vectors
3 */
4 typedef struct
5 {
6 /*@{*/
7 double x ; /**< the x coordinate */
8 double y ; /**< the y coordinate */
9 double z ; /**< the z coordinate */
10 /*@}*/
11 /**
12 * @name group 2
13 */
14 /*@{*/
15 char * name ; /**< the name of the point */
16 int namelength ; /**< the size of the point name */
17 /*@}*/
18 } point3d ;
Documenting enums
Documenting functions
1 /*!
2 Copies bytes from a source memory area to a destination memory area,
3 where both areas may not overlap.
4 @param[out] dest The memory area to copy to.
5 @param[in] src The memory area to copy from.
6 @param[in] n The number of bytes to copy
7 */
8 void memcpy(void *dest, const void *src, size_t n);
1 /**
2 * The point3d structure is stupid
3 * @param[out] x the modified input
4 * @return \f\$x + 1\f\$
5 */
6 int megaFunc( int * x ) ;
7 /**
8 * The main procedure. It can do the following:
9 * - do nothing
10 * - sleep
11 *
12 * @code
13 * for ( i = 0 ; i < 5 ; i++ ) { megaFunc(i) ; }
14 * @endcode
15 * Which compute \f\$(x_1,y_1)\f\$ sometimes.
16 * @param argc the command line
17 * @param argv the number of options in the command line.
18 * @return whatever
19 * @author jb silvy
20 */
21 int main( char ** argc, int argv )
22 {
23 return megaFunc( 3 ) ;
24 }
Documenting others
Files
Files containing the examples, you may use them with Doxygen: