All methods and attributes (including protected and private) must have a comment. In a method comment the parameters, the exceptions thrown and the method return should have a comment. For example:
/** * This is an example that is used in the EasyBeans Code Convention. */ private int intValue; /** * This is an example method to show how is a class comment. * @param a an example of parameter. * @param b other example of parameter. * @return the method result. * @throws Exception the exception thrown by the method. */ public int add(final int a, final int b) throws Exception { return a + b; }