These are based on the Google Java Style guidelines, with the following changes:
- Indents are 4 spaces instead of 2
uk.gov
imports are listed first instead ofcom.google
java
andjavax
imports are listed before 3rd party imports
It is not possible to entirely rely on IDE auto-formatting to enforce these rules. However, The following IDE settings can be used to minimise the effort.
- Download the Intellij CJS Common Platform Style file.
- In Intellij, go to Settings > Code Style > Manage... and import the downloaded file.
- Download the Eclipse CJS Common Platform Style file.
- ???