Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse: How can I find all (public) classes/methods without Javadoc comments?

In Eclipse, is there a way to find all (public) classes/methods which do not currently have any Javadoc comments?

Additionally, would it be possible to automatically add a basic Javadoc comment such as:

/**
 * TODO Javadoc
 * @param i
 * @return
 */

so that these methods without Javadoc would also be added to my TODO list?

like image 619
kmccoy Avatar asked Apr 15 '11 22:04

kmccoy


1 Answers

See Window -> Preferences -> Java -> Compiler -> JavaDoc

Change the missing JavaDoc tags preference to Warning.

After all projects have been rebuilt, you can switch to the Problems View and all methods with missing JavaDoc are listed.

HTH Tom

Edit: Unfortunately there is no way to add a JavaDoc-template to all missing methods in one single step. The fastest way is to insert a JavaDoc is to set the cursor on the method-declaration and then using the shortcut Shift+Alt+J

like image 175
Tom Seidel Avatar answered Jan 04 '23 04:01

Tom Seidel