Arvutiteaduse instituut
  1. Kursused
  2. 2022/23 kevad
  3. Programmeerimine keeles C++_ENG (MTAT.03.158)
EN
Logi sisse

Programmeerimine keeles C++_ENG 2022/23 kevad

  • Home
  • Labs
    • Submission of solutions
    • Results
  • Examination times
  • Guides
  • References

How to use Doxygen?

The following steps help with using Doxygen.

1) Generate Doxyfile. Option A is 'doxygen -g Doxyfile'. Option B is doxywizard. Please name the file Doxyfile as this is the custom. doxywizard is very good because it lets you choose several useful and interesting options that make your documentation more complete and beautiful. However, you have to change the Doxyfile afterwards so that it does not contain absolute paths (C:/my/home/folder/cpp/praks1).

PS: It is also convenient to specify in the Doxyfile where the generated documentation should appear, for example the docs folder (the OUTPUT_DIRECTORY variable helps ).

2) Read the Doxygen manual. This is independent work. Examples of good links are:

  • http://www.doxygen.nl/manual/docblocks.html
  • http://www.doxygen.nl/manual/commands.html

Especially read the commands \brief, \param, \returns, \retval.

3) Document the header file (*.h) in your code according to doxygen requirements.

4) Run doxygen. If the Doxyfile is named Doxyfile, no parameters need to be passed to doxygen.

5) Look at index.html in the output HTML folder. There is a list of documented functions with their parameters and return values. Free text is not enough, the commands listed in point 2 must be used.

6) An example worth looking at (Javadoc style):

  • http://www.doxygen.nl/manual/docblocks.html#docexamples
  • Resulting [http://www.doxygen.nl/manual/examples/jdstyle/html/class_javadoc___test.html | HTML]]

FAQ:

Let's repeat, because it is often overlooked: to document global objects (functions, typedefs, enum, macros, etc), you must document the file in which they are defined. In other words, there must be at least one /*! \file */ or one /** @file */line in this file.[1]

Check that you have specified in the configuration file (Doxyfile) where the documentation should be looked for (for example, in the include folder). The variable INPUT will help. Or use RECURSIVE.

  • Arvutiteaduse instituut
  • Loodus- ja täppisteaduste valdkond
  • Tartu Ülikool
Tehniliste probleemide või küsimuste korral kirjuta:

Kursuse sisu ja korralduslike küsimustega pöörduge kursuse korraldajate poole.
Õppematerjalide varalised autoriõigused kuuluvad Tartu Ülikoolile. Õppematerjalide kasutamine on lubatud autoriõiguse seaduses ettenähtud teose vaba kasutamise eesmärkidel ja tingimustel. Õppematerjalide kasutamisel on kasutaja kohustatud viitama õppematerjalide autorile.
Õppematerjalide kasutamine muudel eesmärkidel on lubatud ainult Tartu Ülikooli eelneval kirjalikul nõusolekul.
Courses’i keskkonna kasutustingimused