开发者

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 al开发者_运维知识库so be added to my TODO list?


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

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜