JavaDoc

Javadoc API

  • Use the @since tag for new classes, interfaces, enums and annotations. Use the tag also for all methods within interfaces.
  • Use the @author tag if you create a new class, enum, interface or annotation.
  • Setter and getter methods don't have to be commented.
  • Do not use package javadocs.
  • If you create a new class, interface, enum or annotation: Add a meaningful comments which describes what the component does and why it exists.
  • Do not mix javadoc and TODO comments. TODO comments should always be located outside of javadoc blocks.

Comments

  • Use // for "normal" (non-javadoc) comments
  • If you use //NOCS or //NOPMD add the reason in brackets behind the comment.