Rule Definition
There is no dispute that these comments contribute to a developer's understanding and help a developer write reliable applications more quickly. Without documenting fields it is dififcult for anyone else than the author to guess the purpose of the field except by looking at the code that is using it.
Remediation
You should add JavaDoc Comments for all public fields of the application.
Violation Code Sample
public class Customer { public String name; //Violation as there is no JavaDoc Comments for the field. public String city;
Fixed Code Sample
public class Customer { /** * The first and last name of this customer. */ public String name;
Reference
https://developer.atlassian.com/server/confluence/javadoc-standards/ https://www.baeldung.com/javadoc
Related Technologies
JEE
Technical Criterion
Documentation - Automated Documentation
About CAST Appmarq
CAST Appmarq is by far the biggest repository of data about real IT systems. It's built on thousands of analyzed applications, made of 35 different technologies, by over 300 business organizations across major verticals. It provides IT Leaders with factual key analytics to let them know if their applications are on track.