...
Avoid JavaDocs which add no explanation beyond what can be easily deduced from the code.
For the most part, classes should be laid out in the following order:
...
LOG
...
fields
...
constructors
...
overridden methods (public)
...
protected/private methods
...
getters and setters with logic
...
Organize classes in a meaningful order as recommending in Java Coding Standards#ClassStructure
Avoid Importing Unwanted Classes
Sometimes it can be easy to import the wrong version of a class, often because of maven transitive dependencies. For example, we have upgraded libraries such as commons-lang and commons-collections to newer versions with new packages, but the older versions are still coming into the project as transitive dependencies. We have also removed some dependencies, such as guava and jdom from Kuali Financials, but these too are pulled in as transitive dependencies. We have added a maven plugin to fail the build at the compile phase if there are classes imported incorrectly. However, it can also be helpful to avoid these imports during development with help from your IDE.
- In Intellij, go to Preferences > Editor > General > Auto Import, Java and enter the list of packages to exclude under Exclude from Import and Completion. The list of what to exclude can be found in the checkstyle.xml file in the root of the financials project. You can also exclude classes directly from the Class picker dialog.