PMD Results

The following document contains the results of PMD 6.8.0.

Files

nl/geodienstencentrum/maven/plugin/sass/AbstractSassMojo.java

Violation Priority Line
The class 'AbstractSassMojo' has a Standard Cyclomatic Complexity of 5 (Highest = 13). 3 60497
The class 'AbstractSassMojo' has a Modified Cyclomatic Complexity of 5 (Highest = 13). 3 60497
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 71
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 79
The String literal "true" appears 4 times in this file; the first occurrence is on line 86 3 86
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 87
Private field 'sassOptions' could be made final; it is only initialized in the declaration or constructor. 3 108
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 108
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 108
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 139
Private field 'resources' could be made final; it is only initialized in the declaration or constructor. 3 139
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 150
Private field 'gemPaths' could be made final; it is only initialized in the declaration or constructor. 3 150
Private field 'gems' could be made final; it is only initialized in the declaration or constructor. 3 160
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 160
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 168
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 177
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 187
Private field 'includes' could be made final; it is only initialized in the declaration or constructor. 3 187
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 196
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 208
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 216
There is log block not surrounded by if 2 235
There is log block not surrounded by if 2 235
Local variable 'o' could be declared final 3 242
Found 'DU'-anomaly for variable 'o' (lines '242'-'250'). 5 242250
Avoid unused local variables such as 'o'. 3 242
Avoid declaring a variable if it is unreferenced before a possible exit point. 3 242
Found 'UR'-anomaly for variable 'gem' (lines '260'-'288'). 5 260288
Avoid really long methods. 3 260369
The method 'buildBasicSassScript' has a Modified Cyclomatic Complexity of 13. 3 260369
The method 'buildBasicSassScript(StringBuilder)' has an NPath complexity of 1344 3 260369
Found 'UR'-anomaly for variable 'p' (lines '260'-'274'). 5 260274
The method 'buildBasicSassScript' has a Standard Cyclomatic Complexity of 13. 3 260369
Found 'UR'-anomaly for variable 'gemPath' (lines '260'-'268'). 5 260268
The method 'buildBasicSassScript(StringBuilder)' has a cyclomatic complexity of 13. 3 260369
StringBuffer constructor is initialized with size 16, but has at least 701 characters appended. 3 278
StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 283
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 291
StringBuffer (or StringBuilder).append is called 3 consecutive times with literals. Use a single append with a single combined String. 3 291
Avoid appending characters as strings in StringBuffer.append. 3 327
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 353354
StringBuffer (or StringBuilder).append is called 5 consecutive times with literals. Use a single append with a single combined String. 3 354
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 355356
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 357358
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 359360
StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 366
Found 'UR'-anomaly for variable 'source' (lines '376'-'412'). 5 376412
Found 'UR'-anomaly for variable 'entry' (lines '376'-'414'). 5 376414
Found 'DU'-anomaly for variable 'log' (lines '377'-'420'). 5 377420
Avoid if (x != y) ..; else ..; 3 387396
There is log block not surrounded by if 2 388389
There is log block not surrounded by if 2 388389
There is log block not surrounded by if 2 393394
There is log block not surrounded by if 2 393394
There is log block not surrounded by if 2 398
There is log block not surrounded by if 2 398
There is log block not surrounded by if 2 402
There is log block not surrounded by if 2 402
There is log block not surrounded by if 2 414415
There is log block not surrounded by if 2 414415
Use block level rather than method level synchronization 3 426472
Parameter 'destinationDir' is not assigned and could be declared final 3 426
Local variable 'destDir' could be declared final 3 429
There is log block not surrounded by if 2 435
There is log block not surrounded by if 2 435
In J2EE, getClassLoader() might not work as expected. Use Thread.currentThread().getContextClassLoader() instead. 3 438
Local variable 'urlJar' could be declared final 3 438
Local variable 'resourceFilePath' could be declared final 3 439
String.indexOf(char) is faster than String.indexOf(String). 3 440
Local variable 'jarFileURI' could be declared final 3 441
Local variable 'jarFile' could be declared final 3 442
Local variable 'jar' could be declared final 3 443
Local variable 'enums' could be declared final 3 446
Local variable 'entry' could be declared final 3 447
Local variable 'fileName' could be declared final 3 452
Avoid instantiating new objects inside loops 3 454
Local variable 'f' could be declared final 3 454
There is log block not surrounded by if 2 456
There is log block not surrounded by if 2 456
Avoid instantiating new objects inside loops 3 459
Local variable 'fos' could be declared final 3 459

nl/geodienstencentrum/maven/plugin/sass/Resource.java

Violation Priority Line
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 38
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 47
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 50
Found 'UR'-anomaly for variable 'included' (lines '60'-'85'). 5 6085
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 62
There is log block not surrounded by if 2 6566
There is log block not surrounded by if 2 6566
A method should have only one exit point, and that should be the last statement in the method 3 67
Avoid instantiating new objects inside loops 3 89
Avoid instantiating new objects inside loops 3 91
Found 'DD'-anomaly for variable 'destDir' (lines '91'-'94'). 5 9194
Avoid instantiating new objects inside loops 3 94

nl/geodienstencentrum/maven/plugin/sass/compiler/CompilerCallback.java

Violation Priority Line
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 30
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 32

nl/geodienstencentrum/maven/plugin/sass/compiler/UpdateStylesheetsMojo.java

Violation Priority Line
A method should have only one exit point, and that should be the last statement in the method 3 54
Found 'DD'-anomaly for variable 'buildRequired' (lines '56'-'58'). 5 5658
Found 'DU'-anomaly for variable 'buildRequired' (lines '58'-'77'). 5 5877
StringBuffer constructor is initialized with size 16, but has at least 31 characters appended. 3 70
A method should have only one exit point, and that should be the last statement in the method 3 88
A method should have only one exit point, and that should be the last statement in the method 3 96
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 112
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 114
Parameter 'startDirectory' is not assigned and could be declared final 3 116
It is a good practice to call super() in a constructor 3 120125
Parameter 'startDirectory' is not assigned and could be declared final 3 120
Parameter 'filter' is not assigned and could be declared final 3 120
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 148
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 152
Avoid using redundant field initializer for 'count' 3 156
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 156
Document empty constructor 3 158
It is a good practice to call super() in a constructor 3 158
It is a good practice to call super() in a constructor 3 164167
Local variable 'lastMod' could be declared final 3 175
Useless parentheses. 4 177
Useless parentheses. 4 178

nl/geodienstencentrum/maven/plugin/sass/compiler/WatchMojo.java

Violation Priority Line
When doing a String.toLowerCase()/toUpperCase() call, use a Locale 3 36
StringBuffer constructor is initialized with size 16, but has at least 85 characters appended. 3 54

nl/geodienstencentrum/maven/plugin/sass/report/SCSSLintMojo.java

Violation Priority Line
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 58
Avoid using implementation types like 'HashMap'; use the interface instead 3 80
The method 'execute()' has a cyclomatic complexity of 15. 3 129199
A method should have only one exit point, and that should be the last statement in the method 3 131
Avoid declaring a variable if it is unreferenced before a possible exit point. 3 133
Found 'DU'-anomaly for variable 'log' (lines '133'-'199'). 5 133199
Local variable 'sourceDirs' could be declared final 3 135
There is log block not surrounded by if 2 142
There is log block not surrounded by if 2 142
There is log block not surrounded by if 2 147
There is log block not surrounded by if 2 147
Local variable 'context' could be declared final 3 152
Local variable 'argv' could be declared final 3 154
This call to Collection.toArray() may be optimizable 3 160
There is log block not surrounded by if 2 163
There is log block not surrounded by if 2 163
Local variable 'result' could be declared final 3 164166
There is log block not surrounded by if 2 167
There is log block not surrounded by if 2 167
StringBuffer (or StringBuilder).append is called 3 consecutive times with literals. Use a single append with a single combined String. 3 209
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 209
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 210
StringBuffer (or StringBuilder).append is called 3 consecutive times with literals. Use a single append with a single combined String. 3 215
StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 219
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 219
Found 'UR'-anomaly for variable 'source' (lines '227'-'234'). 5 227234
Local variable 'dirs' could be declared final 3 228

nl/geodienstencentrum/maven/plugin/sass/report/SCSSLintReportGenerator.java

Violation Priority Line
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 41
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 42
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 43
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 44
Found 'DD'-anomaly for variable 'translated' (lines '83'-'95'). 5 8395
In J2EE, getClassLoader() might not work as expected. Use Thread.currentThread().getContextClassLoader() instead. 3 88
There is log block not surrounded by if 2 90
There is log block not surrounded by if 2 90
There is log block not surrounded by if 2 98
There is log block not surrounded by if 2 98
There is log block not surrounded by if 2 104105
There is log block not surrounded by if 2 104105
There is log block not surrounded by if 2 108
There is log block not surrounded by if 2 108

nl/geodienstencentrum/maven/plugin/sass/report/SCSSLintReportMojo.java

Violation Priority Line
Avoid unused private fields such as 'sassOptions'. 3 56
Avoid unused private fields such as 'sassSourceDirectory'. 3 65
Avoid unused private fields such as 'resources'. 3 96
Private field 'resources' could be made final; it is only initialized in the declaration or constructor. 3 96
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 102
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 110
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 118
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 121
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 124
Found non-transient, non-static member. Please mark as transient or provide accessors. 3 132
Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 154
Avoid unused private methods such as 'getBundle(Locale)'. 3 202
In J2EE, getClassLoader() might not work as expected. Use Thread.currentThread().getContextClassLoader() instead. 3 204