-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating

Sonar Code Quality Testing Essentials
By :

Now we will pick the commons-lang
project that we imported into Sonar earlier and eliminate a few violations. Then, we'll run a new analysis and get visual feedback afterwards through the web interface. Of course, you are free to choose any project and try to eliminate similar violations. Before we start the process of editing source files, here is what the Violations widget reads:
![]() |
From the left menu, select the Violations Drilldown component. Select the Info severity, find the Unused Modifier violations on the right panel, and click them to see the exact classes at which they are encountered. Sonar will find Builder.java
inside the package org.apache.commons.lang3.builder
and ExceptionContext.java
in the package org.apache.commons.lang3.exception
. Click on the filenames to open up the source viewer and drill down to the exact line where each violation is encountered.
Open the Builder.java
file and delete the public declaration...
Change the font size
Change margin width
Change background colour