Skip to end of metadata
Go to start of metadata

ONAP uses Google Java Style with some modifications:

  • 4.2 Block indentation: +4 spaces

  • 4.4 Column limit: 120

IDE code formatter configurations can be found in the Google Style Guide repo.

5 Comments

  1. Here are the other references:


  2. For that matter, all of Google's language style guidelines can be found under https://google.github.io/styleguide/

  3. This practice is recommended but not mandatory for Amsterdam release.

    Practice approved by TSC 2017-07-13 (topic #10). PDF Summary of materials presented.

  4. Since ONAP is recommending a modified Google style, it would be very useful if ONAP would publish the configuration files for popular IDEs like Eclipse, IntelliJ to implement that style.

    1. The hyperlinks above can be used to find such configuration files. For example, here are the settings for (an unknown version of) Eclipse: https://raw.githubusercontent.com/google/styleguide/gh-pages/eclipse-java-google-style.xml. A developer could start with these settings and manually apply the modifications. I would be happy to share my current settings with you.

      I think it is a lot simpler to refer to the Google-maintained archive of the style guide and describe how ONAP deviates from this. If configuration files are published here then they will need to be maintained/synchronized. This process would be further complicated if multiple versions of multiple IDEs are supported.