简体   繁体   中英

doxygen python raise exception

I'm new to using Doxygen to document my Python code. I like to document what exceptions my methods/functions raise. I've done this in the past using @raise, but Doxygen doesn't seem to recognize this. I have now also tried @exception (the javadoc/Doxygen idiom), but this too does not seem to be parsed by Doxygen (the @exception or @raise line is passed through to the resulting HTML as if it were in a code/encode block).

Is there any way to convince Doxygen (I'm using 1.8.3) to parse @exception tags for Python code?

Thanks,

Brian

Trying with Doxygen 1.8.8 I'm getting a nice Doxygen output using the @exception tag. However Doxygen dictates the you specify which exception is thrown before the actual documentation.

 ##
 # @brief This is my function
 #
 # @exceptions MyException My function can throw a MyException
 #

I hope this helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM