HELP - ExampleInclude
HelpExample CodeHowToDocumentExampleInclude
Description Source Call Graph
HowToDocument::ExampleInclude ( Public Method )
Author: N.F.S Grundtvig (The members of this class inherits the author by default.)
How to include an example.
 
Syntax / parameters
void ExampleInclude()

Description
How to include an example.

Use: \example relative_path_to_file_name. Alternatively if the file is not found relative to the current directory, then the path is considered to be relative to the example path set in DoxySFile (EXAMPLE_PATH). That is, the example is looked for here:
EXAMPLE_PATH/relative_path_to_file_name

Inline formatted code in place
Examples are always put into the "example" section, which is at the end of the generated documentation page for the entity. In case you want to inline formatted code directly in in the documentation refer to InlineFormattedCode.

This is how it looks in the source:
\example examples/myexample.cpp



Notes
  • This works different from the original Doxygen.
  • It's possible to include as many examples as possible.
  • Examples also works in page and directory documentation.
  • See also
  • ExampleInline(), InlineFormattedCode().
  • Example
    #include <iostream>
    
    #include "../HowtoDocument.h"
    
    void MyExampleFunction()
    {
      using namespace std;
      cout<<"Hello World\n";
    
      // Lets try calling some of the functions in the HowToDoc class
      HowToDocument howToDoc1;
      HowToDocument howToDoc2;
    
      howToDoc1.DocumentingParametersJavaStyle(5, howToDoc2, 3.5f);
      howToDoc1.BriefToNewline();
      howToDoc1.OriginalDoxygenDocCommentStyle();
    }
    

     
    Source
    The documentation for this Member was generated from the following files:
  • HowtoDocument.cpp
  • HowtoDocument.h