O'Reilly logo

Sonar Code Quality Testing Essentials by Charalampos Arapidis

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Anatomy of the dashboard

The Sonar dashboard is the entry point for every project. The default two-column layout hosts numerous widgets that describe quality and give you insight on different metrics. The top two widgets provide statistics on code size and violation totals by severity.

As shown in the following screenshot, the commons-lang project takes up 19,499 lines of code across 99 files. There are 147 classes in total featuring 2.173 methods via 52 accessors.

Tip

Accessors methods

Accessors are all getter methods that follow the standard JavaBean pattern. Such methods expose private objects' properties. For example, the public String getMessage(); method is an accessor to the the private string message property.

The higher the accessor count, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required