Fork me on GitHub

Résultats PMD

Le document suivant contient les résultats de PMD 6.13.0.

Violations By Priority

Priority 1

fr/paris/lutece/plugins/mydashboard/modules/nickname/web/MyDashboardNicknameApp.java

Rule Violation Ligne
ClassNamingConventions The utility class name 'MyDashboardNicknameApp' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' 4979

Priority 2

fr/paris/lutece/plugins/mydashboard/business/portlet/MyDashboardPortletHome.java

Rule Violation Ligne
AvoidUsingVolatile Use of modifier volatile is not recommended. 47

Priority 3

fr/paris/lutece/plugins/mydashboard/business/MyDashboardConfiguration.java

Rule Violation Ligne
ShortVariable Avoid variables with short names like o 133
ConfusingTernary Avoid if (x != y) ..; else ..; 135
ShortVariable Avoid variables with short names like o 142
SimplifiedTernary Ternary operators that can be simplified with || or && 144146
ConfusingTernary Avoid if (x != y) ..; else ..; 155

fr/paris/lutece/plugins/mydashboard/business/MyDashboardConfigurationDAO.java

Rule Violation Ligne
UseUnderscoresInNumericLiterals Number 1000000 should separate every third digit with an underscore 55

fr/paris/lutece/plugins/mydashboard/business/Panel.java

Rule Violation Ligne
CommentRequired Public method and constructor comments are required 134137
CommentRequired Public method and constructor comments are required 139142

fr/paris/lutece/plugins/mydashboard/business/PanelHome.java

Rule Violation Ligne
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 184
ConfusingTernary Avoid if (x != y) ..; else ..; 184

fr/paris/lutece/plugins/mydashboard/business/portlet/MyDashboardPortlet.java

Rule Violation Ligne
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 91
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 91
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 116

fr/paris/lutece/plugins/mydashboard/business/portlet/MyDashboardPortletHome.java

Rule Violation Ligne
ImmutableField Private field '_dao' could be made final; it is only initialized in the declaration or constructor. 48
NonThreadSafeSingleton Singleton is not thread safe 5662
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strPortletTypeId' 85

fr/paris/lutece/plugins/mydashboard/modules/nickname/service/MyDashboardComponentNickname.java

Rule Violation Ligne
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 81
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 81

fr/paris/lutece/plugins/mydashboard/modules/nickname/web/MyDashboardNicknameApp.java

Rule Violation Ligne
UseUtilityClass All methods are static. Consider using a utility class instead. Alternatively, you could add a private constructor or make the class abstract to silence this warning. 5079

fr/paris/lutece/plugins/mydashboard/service/MyDashboardComponent.java

Rule Violation Ligne
ShortVariable Avoid variables with short names like o 71
ConfusingTernary Avoid if (x != y) ..; else ..; 73

fr/paris/lutece/plugins/mydashboard/service/MyDashboardComponentMyDashboard.java

Rule Violation Ligne
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 66

fr/paris/lutece/plugins/mydashboard/service/MyDashboardService.java

Rule Violation Ligne
GodClass Possible God Class (WMC=65, ATFD=62, TCC=14.167%) 62544
ImmutableField Private field '_myDashboardComponentDAO' could be made final; it is only initialized in the declaration or constructor. 68
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 129
ConfusingTernary Avoid if (x != y) ..; else ..; 131160
NPathComplexity The method 'getUserConfig(LuteceUser)' has an NPath complexity of 1376 207331
NcssCount The method 'getUserConfig(LuteceUser)' has a NCSS line count of 66. 207331
ExcessiveMethodLength Avoid really long methods. 207331
CyclomaticComplexity The method 'getUserConfig(LuteceUser)' has a cyclomatic complexity of 17. 207331
CommentRequired Public method and constructor comments are required 333336
CyclomaticComplexity The method 'getDashboardComponentListFromUser(LuteceUser, Panel)' has a cyclomatic complexity of 10. 360425
ConfusingTernary Avoid if (x != y) ..; else ..; 401402
ConfusingTernary Avoid if (x != y) ..; else ..; 488489
ConfusingTernary Avoid if (x != y) ..; else ..; 506507

fr/paris/lutece/plugins/mydashboard/web/ManageMydashboardPanelJspBean.java

Rule Violation Ligne
SingularField Perhaps '_nDefaultItemsPerPage' could be replaced by a local variable. 131
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 143
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 152
ConfusingTernary Avoid if (x != y) ..; else ..; 183
AddEmptyString Do not add empty strings 514

fr/paris/lutece/plugins/mydashboard/web/MyDashboardApp.java

Rule Violation Ligne
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 110
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 110
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 137
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 172
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 172
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 176
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 176
CyclomaticComplexity The method 'doMoveDashboard(HttpServletRequest)' has a cyclomatic complexity of 13. 237308
ConfusingTernary Avoid if (x != y) ..; else ..; 297304

fr/paris/lutece/plugins/mydashboard/web/portlet/MyDashboardPortletJspBean.java

Rule Violation Ligne
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 9293
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 9495
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 146147

Priority 4

fr/paris/lutece/plugins/mydashboard/business/MyDashboardConfiguration.java

Rule Violation Ligne
BooleanGetMethodName A getX() method which returns a boolean should be named isX() 114117

Fichiers

fr/paris/lutece/plugins/mydashboard/business/MyDashboardConfiguration.java

Rule Violation Priority Ligne
BooleanGetMethodName A getX() method which returns a boolean should be named isX() 4 114117
ShortVariable Avoid variables with short names like o 3 133
ConfusingTernary Avoid if (x != y) ..; else ..; 3 135
ShortVariable Avoid variables with short names like o 3 142
SimplifiedTernary Ternary operators that can be simplified with || or && 3 144146
ConfusingTernary Avoid if (x != y) ..; else ..; 3 155

fr/paris/lutece/plugins/mydashboard/business/MyDashboardConfigurationDAO.java

Rule Violation Priority Ligne
UseUnderscoresInNumericLiterals Number 1000000 should separate every third digit with an underscore 3 55

fr/paris/lutece/plugins/mydashboard/business/Panel.java

Rule Violation Priority Ligne
CommentRequired Public method and constructor comments are required 3 134137
CommentRequired Public method and constructor comments are required 3 139142

fr/paris/lutece/plugins/mydashboard/business/PanelHome.java

Rule Violation Priority Ligne
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 184
ConfusingTernary Avoid if (x != y) ..; else ..; 3 184

fr/paris/lutece/plugins/mydashboard/business/portlet/MyDashboardPortlet.java

Rule Violation Priority Ligne
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 91
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 91
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 116

fr/paris/lutece/plugins/mydashboard/business/portlet/MyDashboardPortletHome.java

Rule Violation Priority Ligne
AvoidUsingVolatile Use of modifier volatile is not recommended. 2 47
ImmutableField Private field '_dao' could be made final; it is only initialized in the declaration or constructor. 3 48
NonThreadSafeSingleton Singleton is not thread safe 3 5662
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strPortletTypeId' 3 85

fr/paris/lutece/plugins/mydashboard/modules/nickname/service/MyDashboardComponentNickname.java

Rule Violation Priority Ligne
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 81
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 81

fr/paris/lutece/plugins/mydashboard/modules/nickname/web/MyDashboardNicknameApp.java

Rule Violation Priority Ligne
ClassNamingConventions The utility class name 'MyDashboardNicknameApp' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' 1 4979
UseUtilityClass All methods are static. Consider using a utility class instead. Alternatively, you could add a private constructor or make the class abstract to silence this warning. 3 5079

fr/paris/lutece/plugins/mydashboard/service/MyDashboardComponent.java

Rule Violation Priority Ligne
ShortVariable Avoid variables with short names like o 3 71
ConfusingTernary Avoid if (x != y) ..; else ..; 3 73

fr/paris/lutece/plugins/mydashboard/service/MyDashboardComponentMyDashboard.java

Rule Violation Priority Ligne
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 66

fr/paris/lutece/plugins/mydashboard/service/MyDashboardService.java

Rule Violation Priority Ligne
GodClass Possible God Class (WMC=65, ATFD=62, TCC=14.167%) 3 62544
ImmutableField Private field '_myDashboardComponentDAO' could be made final; it is only initialized in the declaration or constructor. 3 68
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 129
ConfusingTernary Avoid if (x != y) ..; else ..; 3 131160
NPathComplexity The method 'getUserConfig(LuteceUser)' has an NPath complexity of 1376 3 207331
NcssCount The method 'getUserConfig(LuteceUser)' has a NCSS line count of 66. 3 207331
ExcessiveMethodLength Avoid really long methods. 3 207331
CyclomaticComplexity The method 'getUserConfig(LuteceUser)' has a cyclomatic complexity of 17. 3 207331
CommentRequired Public method and constructor comments are required 3 333336
CyclomaticComplexity The method 'getDashboardComponentListFromUser(LuteceUser, Panel)' has a cyclomatic complexity of 10. 3 360425
ConfusingTernary Avoid if (x != y) ..; else ..; 3 401402
ConfusingTernary Avoid if (x != y) ..; else ..; 3 488489
ConfusingTernary Avoid if (x != y) ..; else ..; 3 506507

fr/paris/lutece/plugins/mydashboard/web/ManageMydashboardPanelJspBean.java

Rule Violation Priority Ligne
SingularField Perhaps '_nDefaultItemsPerPage' could be replaced by a local variable. 3 131
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 143
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 152
ConfusingTernary Avoid if (x != y) ..; else ..; 3 183
AddEmptyString Do not add empty strings 3 514

fr/paris/lutece/plugins/mydashboard/web/MyDashboardApp.java

Rule Violation Priority Ligne
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 110
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 110
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 137
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 172
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 172
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 176
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 176
CyclomaticComplexity The method 'doMoveDashboard(HttpServletRequest)' has a cyclomatic complexity of 13. 3 237308
ConfusingTernary Avoid if (x != y) ..; else ..; 3 297304

fr/paris/lutece/plugins/mydashboard/web/portlet/MyDashboardPortletJspBean.java

Rule Violation Priority Ligne
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 9293
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 9495
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 146147