Search code examples
javaintellij-ideajavadocintellij-14

Auto-generate Javadoc comments in intelliJ?


Is it possible to auto-generate Javadoc comments for each method in one class in IntelliJ IDEA?


Solution

  • Yes.

    Under Tools you have Generate JavaDoc. Read about it in the official site.

    In addition you may (Intellij 15):

    Position caret above a method name, type /** and press Enter to let IntelliJ IDEA automatically generate JavaDoc stubs for this method

    Edit: You can use the action Fix doc comment. It doesn't have a default shortcut, but you can assign the Alt+Shift+J shortcut to it in the Keymap, because this shortcut isn't used for anything else.