Fork me on GitHub

Résultats PMD

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

Violations By Priority

Priority 2

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortlet.java

Rule Violation Ligne
IntegerInstantiation Avoid instantiating Integer objects. Call Integer.valueOf() instead. 100

fr/paris/lutece/plugins/linkpages/web/portlet/LinkPagesPortletJspBean.java

Rule Violation Ligne
IntegerInstantiation Avoid instantiating Integer objects. Call Integer.valueOf() instead. 294

Priority 3

fr/paris/lutece/plugins/linkpages/business/portlet/ILinkPagesPortletDAO.java

Rule Violation Ligne
TooManyMethods This class has too many methods, consider refactoring it. 50–140
MissingOverride The method 'delete(int)' is missing an @Override annotation. 55
AvoidUncheckedExceptionsInSignatures A method or constructor should not explicitly declare unchecked exceptions in its 'throws' clause 70
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 70
CommentRequired Public method and constructor comments are required 70
MissingOverride The method 'load(int)' is missing an @Override annotation. 85
CommentRequired Public method and constructor comments are required 123
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 123
AvoidUncheckedExceptionsInSignatures A method or constructor should not explicitly declare unchecked exceptions in its 'throws' clause 123

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortlet.java

Rule Violation Ligne
CallSuperInConstructor It is a good practice to call super() in a constructor 63–66
MissingOverride The method 'getXml(HttpServletRequest)' is missing an @Override annotation. 74–113
ShortVariable Avoid variables with short names like i 79
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 98–103
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 98
UnnecessaryConversionTemporary Avoid unnecessary temporaries when converting primitives to Strings 100
MissingOverride The method 'getXmlDocument(HttpServletRequest)' is missing an @Override annotation. 121–124
MissingOverride The method 'remove()' is missing an @Override annotation. 137–140

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortletDAO.java

Rule Violation Ligne
TooManyMethods This class has too many methods, consider refactoring it. 50–335
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 68–70
CommentRequired Public method and constructor comments are required 68–70
UncommentedEmptyMethodBody Document empty method body 69–70
MissingOverride The method 'delete(int)' is missing an @Override annotation. 77–83
MissingOverride The method 'load(int)' is missing an @Override annotation. 91–108
AvoidUncheckedExceptionsInSignatures A method or constructor should not explicitly declare unchecked exceptions in its 'throws' clause 110
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 110–112
CommentRequired Public method and constructor comments are required 110–112
UncommentedEmptyMethodBody Document empty method body 111–112
MissingOverride The method 'selectLinkPagesList()' is missing an @Override annotation. 119–134
MissingOverride The method 'selectMaxOrder(int)' is missing an @Override annotation. 142–157
MissingOverride The method 'selectLinkPagesInPortletList(int)' is missing an @Override annotation. 165–190
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 171
MissingOverride The method 'selectLinkPageOrder(int, int)' is missing an @Override annotation. 199–215
MissingOverride The method 'selectLinkPageIdByOrder(int, int)' is missing an @Override annotation. 224–241
MissingOverride The method 'storeLinkPageOrder(int, int, int)' is missing an @Override annotation. 250–258
MissingOverride The method 'deleteLinkPage(int, int)' is missing an @Override annotation. 266–276
MissingOverride The method 'deleteAllLinkPages(int)' is missing an @Override annotation. 283–289
MissingOverride The method 'testDuplicate(int, int)' is missing an @Override annotation. 298–314
MissingOverride The method 'insertLinkPage(int, int, int)' is missing an @Override annotation. 323–334

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortletHome.java

Rule Violation Ligne
AssignmentToNonFinalStatic Possible unsafe assignment to a non-final static field in a constructor. 56
RedundantFieldInitializer Avoid using redundant field initializer for '_singleton' 56
CallSuperInConstructor It is a good practice to call super() in a constructor 61–67
MissingOverride The method 'getPortletTypeId()' is missing an @Override annotation. 74–80
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strPortletTypeId' 79
NonThreadSafeSingleton Singleton is not thread safe 89–92
MissingOverride The method 'getDAO()' is missing an @Override annotation. 102–105

fr/paris/lutece/plugins/linkpages/web/portlet/LinkPagesPortletJspBean.java

Rule Violation Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 62–468
ImmutableField Private field '_pageService' could be made final; it is only initialized in the declaration or constructor. 93
MissingOverride The method 'getCreate(HttpServletRequest)' is missing an @Override annotation. 112–136
MissingOverride The method 'getModify(HttpServletRequest)' is missing an @Override annotation. 144–180
MissingOverride The method 'doCreate(HttpServletRequest)' is missing an @Override annotation. 188–220
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 192
MissingOverride The method 'doModify(HttpServletRequest)' is missing an @Override annotation. 228–248
UnusedLocalVariable Avoid unused local variables such as 'nIdPage'. 286
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 400
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 402
ShortVariable Avoid variables with short names like i 452

Fichiers

fr/paris/lutece/plugins/linkpages/business/portlet/ILinkPagesPortletDAO.java

Rule Violation Priority Ligne
TooManyMethods This class has too many methods, consider refactoring it. 3 50–140
MissingOverride The method 'delete(int)' is missing an @Override annotation. 3 55
AvoidUncheckedExceptionsInSignatures A method or constructor should not explicitly declare unchecked exceptions in its 'throws' clause 3 70
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 3 70
CommentRequired Public method and constructor comments are required 3 70
MissingOverride The method 'load(int)' is missing an @Override annotation. 3 85
CommentRequired Public method and constructor comments are required 3 123
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 3 123
AvoidUncheckedExceptionsInSignatures A method or constructor should not explicitly declare unchecked exceptions in its 'throws' clause 3 123

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortlet.java

Rule Violation Priority Ligne
CallSuperInConstructor It is a good practice to call super() in a constructor 3 63–66
MissingOverride The method 'getXml(HttpServletRequest)' is missing an @Override annotation. 3 74–113
ShortVariable Avoid variables with short names like i 3 79
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 98–103
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 3 98
IntegerInstantiation Avoid instantiating Integer objects. Call Integer.valueOf() instead. 2 100
UnnecessaryConversionTemporary Avoid unnecessary temporaries when converting primitives to Strings 3 100
MissingOverride The method 'getXmlDocument(HttpServletRequest)' is missing an @Override annotation. 3 121–124
MissingOverride The method 'remove()' is missing an @Override annotation. 3 137–140

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortletDAO.java

Rule Violation Priority Ligne
TooManyMethods This class has too many methods, consider refactoring it. 3 50–335
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 3 68–70
CommentRequired Public method and constructor comments are required 3 68–70
UncommentedEmptyMethodBody Document empty method body 3 69–70
MissingOverride The method 'delete(int)' is missing an @Override annotation. 3 77–83
MissingOverride The method 'load(int)' is missing an @Override annotation. 3 91–108
AvoidUncheckedExceptionsInSignatures A method or constructor should not explicitly declare unchecked exceptions in its 'throws' clause 3 110
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 3 110–112
CommentRequired Public method and constructor comments are required 3 110–112
UncommentedEmptyMethodBody Document empty method body 3 111–112
MissingOverride The method 'selectLinkPagesList()' is missing an @Override annotation. 3 119–134
MissingOverride The method 'selectMaxOrder(int)' is missing an @Override annotation. 3 142–157
MissingOverride The method 'selectLinkPagesInPortletList(int)' is missing an @Override annotation. 3 165–190
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 171
MissingOverride The method 'selectLinkPageOrder(int, int)' is missing an @Override annotation. 3 199–215
MissingOverride The method 'selectLinkPageIdByOrder(int, int)' is missing an @Override annotation. 3 224–241
MissingOverride The method 'storeLinkPageOrder(int, int, int)' is missing an @Override annotation. 3 250–258
MissingOverride The method 'deleteLinkPage(int, int)' is missing an @Override annotation. 3 266–276
MissingOverride The method 'deleteAllLinkPages(int)' is missing an @Override annotation. 3 283–289
MissingOverride The method 'testDuplicate(int, int)' is missing an @Override annotation. 3 298–314
MissingOverride The method 'insertLinkPage(int, int, int)' is missing an @Override annotation. 3 323–334

fr/paris/lutece/plugins/linkpages/business/portlet/LinkPagesPortletHome.java

Rule Violation Priority Ligne
AssignmentToNonFinalStatic Possible unsafe assignment to a non-final static field in a constructor. 3 56
RedundantFieldInitializer Avoid using redundant field initializer for '_singleton' 3 56
CallSuperInConstructor It is a good practice to call super() in a constructor 3 61–67
MissingOverride The method 'getPortletTypeId()' is missing an @Override annotation. 3 74–80
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strPortletTypeId' 3 79
NonThreadSafeSingleton Singleton is not thread safe 3 89–92
MissingOverride The method 'getDAO()' is missing an @Override annotation. 3 102–105

fr/paris/lutece/plugins/linkpages/web/portlet/LinkPagesPortletJspBean.java

Rule Violation Priority Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 62–468
ImmutableField Private field '_pageService' could be made final; it is only initialized in the declaration or constructor. 3 93
MissingOverride The method 'getCreate(HttpServletRequest)' is missing an @Override annotation. 3 112–136
MissingOverride The method 'getModify(HttpServletRequest)' is missing an @Override annotation. 3 144–180
MissingOverride The method 'doCreate(HttpServletRequest)' is missing an @Override annotation. 3 188–220
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 192
MissingOverride The method 'doModify(HttpServletRequest)' is missing an @Override annotation. 3 228–248
UnusedLocalVariable Avoid unused local variables such as 'nIdPage'. 3 286
IntegerInstantiation Avoid instantiating Integer objects. Call Integer.valueOf() instead. 2 294
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 400
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 402
ShortVariable Avoid variables with short names like i 3 452