"Original" use Doxygen to manage project documents or annotations, Doxygen project _php Tutorials

Source: Internet
Author: User
Tags aliases doxygen

"Original" use Doxygen to manage project documents or annotations, Doxygen project


First, Doxygen application scenario:

Doxygen can be used to manage the annotations of the current mainstream programming language and form a document system. (includes C, C + +, C #, Objective-c, IDL, Java, VHDL, PHP, Python, TCL, FORTRAN, etc.). Doxygen official website address (http://www.doxygen.nl/) Most of the time recently spent on the maintenance of API interface, one of the more important part is how you write the interface to let callers understand the usage at a glance. The same is true for both the internal wireless server and the client, as well as the Open API interface. It took a couple of days to try to manage the interface document using Doxygen with SVN hooks, which is handy and practical. Doxygen official website itself is actually the use of Doxygen to do, if you want to see more specific effect, you can directly refer to http://www.doxygen.nl/.

The following first put out the part I made, the UI is very frustrated, you can really use the company UI department to beautify, because I am still mainly used in the intranet, so I do not think too much about the UI experience:

Second, installation:

Doxygen currently has a more comprehensive support for Windows, Mac Ox, Linux and other mainstream systems. and is basically used in all current mainstream programming languages. Here is a brief introduction of their own in the Ubuntu system under the source code compilation installation process. The remaining installation methods may refer to the official website.

Third, the configuration of using Doxygen configuration file:

The use of Doxygen can be said to configure the configuration file, that is, you just slightly configure the configuration file, and then execute the command: Xxxx/doxygen xxxx.conf can generate the document you want ( here Doxygen provides a variety of formats of the document, I mainly use HTML, so that we can configure a Web service to this HTML, you can use the web above the document. ), Doxygen provides more than 200 configuration items, the configuration file is already able to complete the rich functionality, the following are some common configuration instructions:

  • With command xxx/doxygen-g, a default profile doxygen.conf is generated under the current directory. Open the default profile, you will find that each of the configuration items are configured to configure the value of the Key-value format, if you have a certain English skills, configuration is basically not a problem.
  • For a detailed description of the configuration, please refer to: http://www.stack.nl/~dimitri/doxygen/manual/config.html
  • Abbreviate_brief//Short summary
  • ALIASES//aliases
  • Allexternals//All external documents
  • Alphabetical_index//Alphabetical Index
  • ALWAYS_DETAILED_SEC//Detailed Description section
  • BINARY_TOC//binary operation
  • BRIEF_MEMBER_DESC//Short description of the member
  • Call_graph//Call to the diagram
  • Case_sense_names//The name of the sample detected
  • Chm_file//chm formatted files
  • Class_diagrams//class-table
  • Class_graph//Class-figure
  • dot_path //dot path settings
  • dot_transparent //dot conversion settings
  • dotfile_dirs //dotfile list Display
  • enable_preprocessing //Allow "pre-processing" instructions
  • enum_values_per_line //Per line enumeration value
  • enabled_sections //Allow segmented display
  • Example_path //example Path
  • example_patterns //Examples of file formats (*.cpp, *.h, *.java, etc.)
  • example_recursive //Example recursion
  • collaboration_graph //Mutual Call graph
  • Cols_in_alpha_index //Alphabetical index displayed in a column form
  • Compact_latex //Compressed LATEX documentation
  • compact_rtf //Compressed RTF document
  • create_subdirs //Create a "subdirectory"
  • details_at_top //Detailed header of the document
  • directory_graph //directory Map
  • disable_index //Disable INDEX
  • distribute_group_doc //Disable document Group display
  • Dot_image_format //bitmap graphics
  • dot_multi_targets //Multiple DOT targets
  • EXCLUDE //executable file
  • exclude_patterns //executable file format (*.exe, *.dll, etc.)
  • exclude_symlinks //executable symlinks
  • expand_as_defined //defined extensions
  • expand_only_predef //pre-defined extensions
  • external_groups //external files used
  • extra_packages //used external plug-in package
  • Extract_all //Extract All
  • extract_local_classes //Extract all local classes
  • extract_local_methods //Fetch all local methods
  • extract_private //Extract All PRIVATE
  • extract_static //Extract All STATIC
  • file_patterns //file path
  • file_version_filter //File version control
  • filter_patterns //Control format (major version: 1th version: 2nd version number)
  • filter_source_files //version control of the original file
  • full_path_names //full path name
  • generate_autogen_def //Generate automatic definition file form
  • generate_buglist //Generate Bug List
  • Generate_chi //Generate "Greek alphabet"
  • generate_depreciatedlist //Generate the "evaluation" list
  • generate_html //Generate HTML
  • generate_htmlhelp //Generate HTMLHELP
  • Generate_latex //Build LATEX
  • generate_legend //Generate Legend
  • Generate_man //Generate Man file
  • generate_perlmod //Generate Perl scripts
  • generate_rtf //Generate RTF
  • generate_tagfile //Generate flag file
  • generate_testlist //Generate Testlist
  • generate_todolist //Generate ToDoList
  • Generate_treeview //Spanning tree view display
  • generate_xml //Generate XML
  • graphical_hierarchy //Inheritance Chart
  • group_graphs //group-figure
  • Have_dot //Hide DOT
  • hhc_location //hidden position
  • hide_friend_compounds //Hide "compound" type of friend
  • hide_in_body_docs //Hide the body of a document
  • hide_scope_names //Hide Scope name
  • hide_undoc_classes //Hide all class not archived
  • hide_undoc_members //Hide all members of "not archived"
  • hide_undoc_relations //Hide "not archived" relationships
  • html_align_members The alignment of members in a//html document
  • html_footer //html footnote settings
  • Html_header //html head setting
  • html_output //html output settings
  • html_stylesheet //html style settings
  • Ignore_prefix //Ignore which prefixes
  • image_path //Picture path settings
  • include_graph //include-figure
  • include_path //header file contains the path
  • Inherit_docs //Document inheritance Relationship
  • inline_info //inline letter
  • inline_inherited_memb //inline member obtained through "inheritance"
  • Source code for inline_sources //inline parts
  • Input//Inputs settings
  • Input_filter //Acceptable extension format settings for input files (important)
  • Internal_docs //Internal documentation
  • javadoc_autobrief automatic summary of the document generated by the//javadoc tool
  • Latex_batchmode //latex matching method
  • latex_cmd_name //latex command name
  • Latex_header //latex Head
  • latex_hide_indices //latex internal hidden contains
  • latex_output //latex output
  • macro_expansion //Macro expansion settings (important)
  • makeindex_cmd_name //makeindex Command Index
  • man_extension //man Extension
  • man_links //man link settings
  • man_output //man output settings
  • max_dot_graph_depth Maximum depth of//dot graph
  • max_dot_graph_height Maximum height of//dot chart
  • max_dot_graph_width Maximum width of//dot chart
  • max_initializer_lines //MAX initialization line
  • multiline_cpp_is_brief //Short description of multiple CPP files
  • multiline_cpp_is_brief //Short description of multiple CPP files
  • optimize_output_for_c //optimized settings for C
  • Optimize_output_java //optimized settings for JAVA
  • output_directory //Output Path setting (important)
  • output_language //Output Language settings (important)
  • Paper_type //paper type
  • pdf_hyperlinks //pdf format Hyperlink settings (important)
  • perl_path //perl path settings
  • Perlmod_latex //perlmod LATEX
  • perlmod_pretty //Perlmod pretty (pretty/quite)
  • perlmod_makevar_prefix //perlmod make file version PREFIX
  • predefined //pre-defined (important)
  • PROJECT_NAME //Engineering name (important)
  • Project_number //Members of the project (important)
  • QUIET //static volume setting (important)
  • RECURSIVE //recursion and looping
  • referenced_by_relation //Cross Reference (important)
  • references_relation //cross-reference relationships
  • repeat_brief //reset "short description" to open state
  • rtf_extensions_file //rtf Expand File
  • rtf_hyperlinks //rtf Hyperlinks
  • rtf_output //rtf output settings
  • rtf_stylesheet_file //rtf style file
  • What to include in search_includes //Search (IMPORTANT)
  • searchengine //Search engine settings (important)
  • short_names //Make short file names effective
  • show_directories //Display directory
  • show_include_files //display include file (general No, otherwise too large)
  • show_used_files //display of files used (general Yes)
  • Skip_function_macros //skipping macros in functions (important), rookie better not jump.
  • Sort_brief_docs //Short Summary of documents
  • Brief description of Sort_member_docs //Members
  • Source_browser //Original file browse path
  • strip_code_comments //exclude which barcode form annotations (important)
  • Strip_from_inc_path //exclude which header files contain comments (important)
  • Strip_from_path //Exclude which barcode path settings
  • subgrouping //Subgroup settings (important)
  • tab_size //tab character SIZE setting (important)
  • tagfiles //Flag file
  • template_relations //template relationship settings (important)
  • toc_expand //toc Extension
  • treeview_width //Tree Chart Display width settings (important)
  • uml_look //uml appearance settings (important)
  • use_windows_encoding //using the encoding form of the WINDOWS system (important)
  • verbatim_headers //verbatim Head (header file)
  • Warn_format //Warning format designation (important)
  • warn_if_doc_error //Displays a warning if there is a document error
  • warn_if_undocumented //If the file is not archived, a warning is displayed
  • warn_logfile //warning log file Settings
  • Warn_no_paramdoc //No parameter document warning form setting
  • WARNINGS //Warning settings (important)
  • xml_dtd //xml file type definition (important)
  • xml_output //xml output settings (important)
  • xml_programlisting //xml Program list (important)
  • Xml_schema //xml mode setting (important)

Iv. writing of notes after the completion of Doxygen configuration

When you've configured your Doxygen, you'll spend almost the rest of your time writing and maintaining notes in your code. Want to use Doxygen to manage documents. Then the code's comments are not strictly required.

/** * @brief here uses brief to illustrate the main function of the interface method * @date   the creation time of the interface method * @author the creator of the interface method * @param  : The parameters are described in the following table: * Name     | type     | Description of param  *----------|-----------|--------------------* car_id   | int      | vehicle Source number * province | int      | Clerk's Province * x        |  X       |   x * x        |  X       |   x * x        |  X       |   X * @return The    return value is described as follows: * Name     | type     | description of value *--------|----------|----------------------* C ar_id   | int      | vehicle Source number * car_info | object   | Source information in JSON object format * @warning   the interface needs to tell the caller some warning * @attention the interface requires Some caveats that are told to callers * @note      Some notes for this interface. This is typically used when the latter has significant changes to the interface. Note that some time someone changed something * @ Todo     some unfinished todo content for this interface */public function Newsale () {do    someting;}
    • After writing a comment according to the specification, the effect shown in the page document is as follows:

    • In the project can be agreed in advance written rules, the rest as long as you follow this rule to maintain. Of course people are people after all, it is impossible to ensure that all the code can be written according to the expected annotation rules. The path to the log file can therefore be specified in the Doxygen configuration file. You can take advantage of this day file, write a small piece of code in the appropriate scripting language to analyze the log file, and then personalize the point to display on the Web page. The designated management staff periodically review the comment error log to instantly correct the incorrect comment.

The more commonly used characteristics of Doxygen

Doxygen function is far more than I described above, there are many colorful features, there are people who want to use this thing, you can go to the Doxygen official online study ha. This article can be reproduced at will, but please be sure to indicate the original source.

http://www.bkjia.com/PHPjc/922301.html www.bkjia.com true http://www.bkjia.com/PHPjc/922301.html techarticle "original" use Doxygen to manage project documents or annotations, Doxygen project one, Doxygen application scenario: Doxygen can be used to manage annotations in the current mainstream programming language to form a document System ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.