PMD Results

The following document contains the results of PMD.

Summary

Files Errors
46 112

Files

Files Violations
ca/spaz/cron/CRONConfiguration.java 4
ca/spaz/cron/CRONOMETER.java 1
ca/spaz/cron/config/DatasourceValidator.java 2
ca/spaz/cron/database/AbstractFoodGroup.java 1
ca/spaz/cron/database/NutrientInfo.java 2
ca/spaz/cron/database/Serving.java 2
ca/spaz/cron/datasource/AbstractFoodDataSource.java 1
ca/spaz/cron/datasource/Datasources.java 1
ca/spaz/cron/datasource/sql/SQLDatasource.java 2
ca/spaz/cron/datasource/sql/SQLFoodImpl.java 2
ca/spaz/cron/datasource/sql/USDAsr17/USDAImporter.java 3
ca/spaz/cron/datasource/www/NutritionDataDatasource.java 3
ca/spaz/cron/summary/AbstractNutrientSummaryPanel.java 2
ca/spaz/cron/summary/MacroNutrientSummaryPanel.java 3
ca/spaz/cron/summary/NutritionSummaryPanel.java 2
ca/spaz/cron/summary/SimpleSummaryContent.java 2
ca/spaz/cron/summary/SwitchableSummaryPanel.java 1
ca/spaz/cron/summary/TargetSummaryChart.java 2
ca/spaz/cron/targets/TargetEditor.java 1
ca/spaz/cron/targets/TargetEditorTable.java 1
ca/spaz/cron/targets/TargetEditorTableModel.java 1
ca/spaz/cron/ui/BiomarkerPanel.java 1
ca/spaz/cron/ui/DailySummary.java 5
ca/spaz/cron/ui/FoodDBToolBar.java 1
ca/spaz/cron/ui/FoodEditor.java 4
ca/spaz/cron/ui/MeasureEditor.java 4
ca/spaz/cron/ui/NutrientEditorTable.java 1
ca/spaz/cron/ui/NutrientTableModel.java 1
ca/spaz/cron/ui/SearchPanel.java 4
ca/spaz/cron/ui/ServingEditor.java 1
ca/spaz/cron/ui/USDAImportDialog.java 3
ca/spaz/cron/user/USDAImportWizardPanel.java 2
ca/spaz/cron/user/impl/CRONUser.java 1
ca/spaz/gui/DoubleField.java 1
ca/spaz/gui/SpazLayout.java 2
ca/spaz/gui/SpazMenuBar.java 2
ca/spaz/sql/DBRow.java 1
ca/spaz/sql/SQLColumnSet.java 1
ca/spaz/sql/SQLSelect.java 1
ca/spaz/task/TaskBar.java 1
ca/spaz/util/CountableInputStream.java 1
ca/spaz/util/Loader.java 2
ca/spaz/util/ToolBox.java 2
ca/spaz/wizard/WizardPanel.java 1
com/nexes/wizard/Wizard.java 3
ca/spaz/cron/datasource/SQLDatasourceTest.java 27

ca/spaz/cron/CRONConfiguration.java

Violation Line
Unnecessary final modifier in final class 41
Unnecessary final modifier in final class 45
Avoid empty 'if' statements 184
Avoid empty 'if' statements 194

ca/spaz/cron/CRONOMETER.java

Violation Line
Avoid unused private fields such as 'tl' 49

ca/spaz/cron/config/DatasourceValidator.java

Violation Line
Ensure you override both equals() and hashCode() 29
Unnecessary final modifier in final class 33

ca/spaz/cron/database/AbstractFoodGroup.java

Violation Line
Ensure you override both equals() and hashCode() 24

ca/spaz/cron/database/NutrientInfo.java

Violation Line
Avoid unused private fields such as 'RDA_MIN' 20
Avoid unused private fields such as 'RDA_MAX' 22

ca/spaz/cron/database/Serving.java

Violation Line
Avoid unused private fields such as 'logger' 21
These nested if statements could be combined 162

ca/spaz/cron/datasource/AbstractFoodDataSource.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 15

ca/spaz/cron/datasource/Datasources.java

Violation Line
Avoid unused private fields such as 'dbIDList' 41

ca/spaz/cron/datasource/sql/SQLDatasource.java

Violation Line
Avoid duplicate imports such as 'java.util.Date' 16
These nested if statements could be combined 913

ca/spaz/cron/datasource/sql/SQLFoodImpl.java

Violation Line
Avoid unused private fields such as 'logger' 26
Ensure you override both equals() and hashCode() 307

ca/spaz/cron/datasource/sql/USDAsr17/USDAImporter.java

Violation Line
Avoid unused private fields such as 'HASH_MAX' 65
Avoid unnecessary return statements 199
Avoid empty 'if' statements 379

ca/spaz/cron/datasource/www/NutritionDataDatasource.java

Violation Line
Avoid empty 'if' statements 136
Avoid empty 'if' statements 139
Avoid unused local variables such as 'foods' 250

ca/spaz/cron/summary/AbstractNutrientSummaryPanel.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 8
Avoid unused local variables such as 'consumed' 41

ca/spaz/cron/summary/MacroNutrientSummaryPanel.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 8
Avoid unused private methods such as 'getAmount' 25
Avoid unused private methods such as 'getNutrientTable' 35

ca/spaz/cron/summary/NutritionSummaryPanel.java

Violation Line
Avoid unused private fields such as 'logger' 26
Avoid unused local variables such as 'consumed' 53

ca/spaz/cron/summary/SimpleSummaryContent.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 16
Avoid unused local variables such as 'nrows' 56

ca/spaz/cron/summary/SwitchableSummaryPanel.java

Violation Line
Avoid unused private fields such as 'currentContent' 32

ca/spaz/cron/summary/TargetSummaryChart.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 8
Avoid unused local variables such as 'min' 69

ca/spaz/cron/targets/TargetEditor.java

Violation Line
Avoid unused private methods such as 'getButtonPanel' 156

ca/spaz/cron/targets/TargetEditorTable.java

Violation Line
Avoid unused local variables such as 'selectedRow' 44

ca/spaz/cron/targets/TargetEditorTableModel.java

Violation Line
These nested if statements could be combined 80

ca/spaz/cron/ui/BiomarkerPanel.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 8

ca/spaz/cron/ui/DailySummary.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 10
Avoid unused private fields such as 'TITLE_COLOR' 33
Avoid unused private fields such as 'logger' 47
Avoid unused local variables such as 'selectedRow' 327
Avoid unused private methods such as 'addTableClickListener' 378

ca/spaz/cron/ui/FoodDBToolBar.java

Violation Line
These nested if statements could be combined 96

ca/spaz/cron/ui/FoodEditor.java

Violation Line
Avoid unused private fields such as 'editWeightsButton' 60
Avoid unused private methods such as 'getEditGroupsButton' 158
Avoid unused private methods such as 'getEditSourceButton' 172
Avoid unused local variables such as 'editor' 375

ca/spaz/cron/ui/MeasureEditor.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 9
Avoid unused private fields such as 'buttonPanel' 42
Avoid unused private methods such as 'isDirty' 184
Avoid unused local variables such as 'selectedRow' 207

ca/spaz/cron/ui/NutrientEditorTable.java

Violation Line
Avoid unused local variables such as 'selectedRow' 52

ca/spaz/cron/ui/NutrientTableModel.java

Violation Line
These nested if statements could be combined 92

ca/spaz/cron/ui/SearchPanel.java

Violation Line
Avoid duplicate imports such as 'java.util.List' 9
These nested if statements could be combined 173
Avoid unused private methods such as 'sortResults' 280
Avoid unused private fields such as 'logger' 297

ca/spaz/cron/ui/ServingEditor.java

Violation Line
Avoid unused private fields such as 'titlePanel' 46

ca/spaz/cron/ui/USDAImportDialog.java

Violation Line
Avoid unused private fields such as 'logger' 39
Avoid unused private fields such as 'logger' 109
Avoid unused private fields such as 'logger' 143

ca/spaz/cron/user/USDAImportWizardPanel.java

Violation Line
Avoid unused private fields such as 'finishAction' 45
Avoid unused private methods such as 'getCancelButton' 71

ca/spaz/cron/user/impl/CRONUser.java

Violation Line
Avoid unused private fields such as 'logger' 54

ca/spaz/gui/DoubleField.java

Violation Line
Avoid unused local variables such as 'decimal' 61

ca/spaz/gui/SpazLayout.java

Violation Line
Avoid unused local variables such as 'totalW' 82
Avoid unused local variables such as 'totalH' 83

ca/spaz/gui/SpazMenuBar.java

Violation Line
These nested if statements could be combined 102
These nested if statements could be combined 116

ca/spaz/sql/DBRow.java

Violation Line
Avoid unused local variables such as 'cols' 25

ca/spaz/sql/SQLColumnSet.java

Violation Line
Avoid instantiating Boolean objects; you can usually invoke Boolean.TRUE instead. 50

ca/spaz/sql/SQLSelect.java

Violation Line
Avoid duplicate imports such as 'java.util.ArrayList' 8

ca/spaz/task/TaskBar.java

Violation Line
Avoid duplicate imports such as 'javax.swing.Timer' 11

ca/spaz/util/CountableInputStream.java

Violation Line
Avoid unused private fields such as 'DEAFULT_BUFFER_SIZE' 24

ca/spaz/util/Loader.java

Violation Line
Avoid empty catch blocks 52
Avoid empty catch blocks 96

ca/spaz/util/ToolBox.java

Violation Line
Avoid unused private methods such as 'isOlderWindows' 69
These nested if statements could be combined 162

ca/spaz/wizard/WizardPanel.java

Violation Line
Avoid unused private fields such as 'controller' 9

com/nexes/wizard/Wizard.java

Violation Line
Avoid instantiating Boolean objects; you can usually invoke Boolean.TRUE instead. 289
Avoid instantiating Boolean objects; you can usually invoke Boolean.TRUE instead. 305
Avoid instantiating Boolean objects; you can usually invoke Boolean.TRUE instead. 321

ca/spaz/cron/datasource/SQLDatasourceTest.java

Violation Line
Avoid empty catch blocks 64
Avoid empty catch blocks 68
Avoid empty catch blocks 72
Avoid empty catch blocks 76
Avoid empty catch blocks 80
Avoid empty catch blocks 84
Avoid empty catch blocks 88
Avoid empty catch blocks 92
Avoid empty catch blocks 96
Avoid empty catch blocks 100
Avoid empty catch blocks 104
Avoid empty catch blocks 108
Avoid empty catch blocks 112
Avoid empty catch blocks 120
Avoid empty catch blocks 124
Avoid empty catch blocks 128
Avoid empty catch blocks 132
Avoid empty catch blocks 136
Avoid empty catch blocks 140
Avoid empty catch blocks 144
Avoid empty catch blocks 148
Avoid empty catch blocks 152
Avoid empty catch blocks 156
Avoid empty catch blocks 160
Avoid empty catch blocks 164
Avoid empty catch blocks 168
Avoid unused local variables such as 'ds' 172