Fork me on GitHub

PMD Results

The following document contains the results of PMD 6.13.0.

Violations By Priority

Priority 1

fr/paris/lutece/plugins/mylutece/authentication/AbstractAuthentication.java

Rule Violation Line
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 95–100
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 109–114

fr/paris/lutece/plugins/mylutece/authentication/ExternalAuthentication.java

Rule Violation Line
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 78–81
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 88–91
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 98–101
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 108–111
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 118–121
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 128–131
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 137–140
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 177–180
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 189–192
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 201–204
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 201–204
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 242–245
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 252–254

fr/paris/lutece/plugins/mylutece/authentication/MultiLuteceAuthentication.java

Rule Violation Line
FieldNamingConventions The constant name '_mapAuthentications' doesn't match '[A-Z][A-Z_0-9]*' 66
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 412–422

fr/paris/lutece/plugins/mylutece/authentication/PortalAuthentication.java

Rule Violation Line
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 162–165
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 202–205
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 214–218
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 227–230
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 227–230
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 267–269

fr/paris/lutece/plugins/mylutece/business/LuteceUserRoleDescription.java

Rule Violation Line
ConstructorCallsOverridableMethod Overridable method 'setType' called during object construction 75
ConstructorCallsOverridableMethod Overridable method 'setComplementaryDescription' called during object construction 76
FormalParameterNamingConventions The method parameter name '_strType' doesn't match '[a-z][a-zA-Z0-9]*' 94
FormalParameterNamingConventions The method parameter name '_strComplementaryDescription' doesn't match '[a-z][a-zA-Z0-9]*' 112

fr/paris/lutece/plugins/mylutece/service/MyLuteceExternalIdentityService.java

Rule Violation Line
FieldNamingConventions The static field name 'ATTRIBUTE_USER_MAPPING' doesn't match '_[a-z][a-zA-Z0-9]*' 54

fr/paris/lutece/plugins/mylutece/util/SecurityUtils.java

Rule Violation Line
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 870–880

Priority 2

fr/paris/lutece/plugins/mylutece/service/MyLuteceExternalIdentityService.java

Rule Violation Line
AvoidUsingVolatile Use of modifier volatile is not recommended. 56
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 121

fr/paris/lutece/plugins/mylutece/service/MyluteceExternalRoleService.java

Rule Violation Line
AvoidUsingVolatile Use of modifier volatile is not recommended. 22

fr/paris/lutece/plugins/mylutece/util/SecurityUtils.java

Rule Violation Line
AvoidReassigningParameters Avoid reassigning parameters such as 'strValue' 589

fr/paris/lutece/plugins/mylutece/web/security/AuthenticationFilterJspBean.java

Rule Violation Line
BooleanInstantiation Avoid instantiating Boolean objects; reference Boolean.TRUE or Boolean.FALSE or call Boolean.valueOf() instead. 257

Priority 3

fr/paris/lutece/plugins/mylutece/authentication/AbstractAuthentication.java

Rule Violation Line
CommentRequired Header comments are required 47–116

fr/paris/lutece/plugins/mylutece/authentication/ExternalAuthentication.java

Rule Violation Line
MissingOverride The method 'isExternalAuthentication()' is missing an @Override annotation. 57–60
MissingOverride The method 'isDelegatedAuthentication()' is missing an @Override annotation. 68–71
MissingOverride The method 'getLoginPageUrl()' is missing an @Override annotation. 78–81
MissingOverride The method 'getDoLoginUrl()' is missing an @Override annotation. 88–91
MissingOverride The method 'getDoLogoutUrl()' is missing an @Override annotation. 98–101
MissingOverride The method 'getNewAccountPageUrl()' is missing an @Override annotation. 108–111
MissingOverride The method 'getViewAccountPageUrl()' is missing an @Override annotation. 118–121
MissingOverride The method 'getLostPasswordPageUrl()' is missing an @Override annotation. 128–131
MissingOverride The method 'getAccessDeniedTemplate()' is missing an @Override annotation. 147–150
MissingOverride The method 'getAccessControledTemplate()' is missing an @Override annotation. 157–160
MissingOverride The method 'isUsersListAvailable()' is missing an @Override annotation. 167–170
MissingOverride The method 'getUsers()' is missing an @Override annotation. 177–180
MissingOverride The method 'getUser(String)' is missing an @Override annotation. 189–192
MissingOverride The method 'getRolesByUser(LuteceUser)' is missing an @Override annotation. 201–204
MissingOverride The method 'isMultiAuthenticationSupported()' is missing an @Override annotation. 213–216
MissingOverride The method 'getIconUrl()' is missing an @Override annotation. 222–225
UncommentedEmptyMethodBody Document empty method body 253–254

fr/paris/lutece/plugins/mylutece/authentication/MultiLuteceAuthentication.java

Rule Violation Line
GodClass Possible God Class (WMC=64, ATFD=64, TCC=22.727%) 62–685
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 66
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 66
MissingOverride The method 'getLoginPageUrl()' is missing an @Override annotation. 106–123
MissingOverride The method 'getDoLoginUrl()' is missing an @Override annotation. 131–148
MissingOverride The method 'getNewAccountPageUrl()' is missing an @Override annotation. 156–173
MissingOverride The method 'getViewAccountPageUrl()' is missing an @Override annotation. 181–198
MissingOverride The method 'getLostPasswordPageUrl()' is missing an @Override annotation. 206–223
MissingOverride The method 'getDoLogoutUrl()' is missing an @Override annotation. 302–319
MissingOverride The method 'getAccessDeniedTemplate()' is missing an @Override annotation. 326–329
MissingOverride The method 'getAccessControledTemplate()' is missing an @Override annotation. 336–339
MissingOverride The method 'getAnonymousUser()' is missing an @Override annotation. 345–360
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 351–357
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the AnonymousUser constructor if you want a default access modifier 353–356
MissingOverride The method 'getAuthServiceName()' is missing an @Override annotation. 366–369
MissingOverride The method 'getAuthType(HttpServletRequest)' is missing an @Override annotation. 375–378
MissingOverride The method 'getHttpAuthenticatedUser(HttpServletRequest)' is missing an @Override annotation. 388–406
MissingOverride The method 'getRolesByUser(LuteceUser)' is missing an @Override annotation. 412–422
MissingOverride The method 'getUser(String)' is missing an @Override annotation. 433–447
MissingOverride The method 'getUsers()' is missing an @Override annotation. 455–470
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 457
MissingOverride The method 'isExternalAuthentication()' is missing an @Override annotation. 476–479
MissingOverride The method 'isUserInRole(LuteceUser, HttpServletRequest, String)' is missing an @Override annotation. 485–500
MissingOverride The method 'isUsersListAvailable()' is missing an @Override annotation. 508–511
MissingOverride The method 'login(String, String, HttpServletRequest)' is missing an @Override annotation. 517–547
ConfusingTernary Avoid if (x != y) ..; else ..; 522–544
ConfusingTernary Avoid if (x != y) ..; else ..; 526–539
MissingOverride The method 'logout(LuteceUser)' is missing an @Override annotation. 553–577
ConfusingTernary Avoid if (x != y) ..; else ..; 555–576
ConfusingTernary Avoid if (x != y) ..; else ..; 559–571
MissingOverride The method 'isMultiAuthenticationSupported()' is missing an @Override annotation. 583–586
MissingOverride The method 'isDelegatedAuthentication()' is missing an @Override annotation. 604–607
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 616
MissingOverride The method 'getIconUrl()' is missing an @Override annotation. 641–644
MissingOverride The method 'getName()' is missing an @Override annotation. 652–655
MissingOverride The method 'getPluginName()' is missing an @Override annotation. 663–666

fr/paris/lutece/plugins/mylutece/authentication/PortalAuthentication.java

Rule Violation Line
MissingOverride The method 'isExternalAuthentication()' is missing an @Override annotation. 57–60
MissingOverride The method 'isDelegatedAuthentication()' is missing an @Override annotation. 66–69
MissingOverride The method 'getLoginPageUrl()' is missing an @Override annotation. 75–78
MissingOverride The method 'getDoLoginUrl()' is missing an @Override annotation. 84–87
MissingOverride The method 'findResetPassword(HttpServletRequest, String)' is missing an @Override annotation. 93–96
MissingOverride The method 'getResetPasswordPageUrl(HttpServletRequest)' is missing an @Override annotation. 101–104
MissingOverride The method 'getNewAccountPageUrl()' is missing an @Override annotation. 111–114
MissingOverride The method 'getViewAccountPageUrl()' is missing an @Override annotation. 121–124
MissingOverride The method 'getDoLogoutUrl()' is missing an @Override annotation. 149–152
MissingOverride The method 'getHttpAuthenticatedUser(HttpServletRequest)' is missing an @Override annotation. 162–165
MissingOverride The method 'getAccessDeniedTemplate()' is missing an @Override annotation. 172–175
MissingOverride The method 'getAccessControledTemplate()' is missing an @Override annotation. 182–185
MissingOverride The method 'isUsersListAvailable()' is missing an @Override annotation. 192–195
MissingOverride The method 'getUsers()' is missing an @Override annotation. 202–205
MissingOverride The method 'getUser(String)' is missing an @Override annotation. 214–218
MissingOverride The method 'getRolesByUser(LuteceUser)' is missing an @Override annotation. 227–230
MissingOverride The method 'isMultiAuthenticationSupported()' is missing an @Override annotation. 238–241
MissingOverride The method 'getIconUrl()' is missing an @Override annotation. 247–250
UncommentedEmptyMethodBody Document empty method body 268–269

fr/paris/lutece/plugins/mylutece/business/LuteceUserAttributeDescription.java

Rule Violation Line
FieldDeclarationsShouldBeAtStartOfClass Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes. 61
FieldDeclarationsShouldBeAtStartOfClass Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes. 64
FieldDeclarationsShouldBeAtStartOfClass Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes. 67

fr/paris/lutece/plugins/mylutece/business/LuteceUserRoleDescription.java

Rule Violation Line
CallSuperInConstructor It is a good practice to call super() in a constructor 71–77

fr/paris/lutece/plugins/mylutece/business/attribute/AbstractAttribute.java

Rule Violation Line
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 78–80
UncommentedEmptyConstructor Document empty constructor 78–80
MissingOverride The method 'getIdAttribute()' is missing an @Override annotation. 87–90
MissingOverride The method 'setIdAttribute(int)' is missing an @Override annotation. 98–101
MissingOverride The method 'isMandatory()' is missing an @Override annotation. 108–111
MissingOverride The method 'setMandatory(boolean)' is missing an @Override annotation. 119–122
MissingOverride The method 'getListAttributeFields()' is missing an @Override annotation. 129–132
MissingOverride The method 'setListAttributeFields(List)' is missing an @Override annotation. 140–143
MissingOverride The method 'getTitle()' is missing an @Override annotation. 150–153
MissingOverride The method 'setTitle(String)' is missing an @Override annotation. 161–164
MissingOverride The method 'getHelpMessage()' is missing an @Override annotation. 171–174
MissingOverride The method 'setHelpMessage(String)' is missing an @Override annotation. 182–185
MissingOverride The method 'getPosition()' is missing an @Override annotation. 192–195
MissingOverride The method 'setPosition(int)' is missing an @Override annotation. 203–206
MissingOverride The method 'getAttributeType()' is missing an @Override annotation. 213–216
MissingOverride The method 'setAttributeType(AttributeType)' is missing an @Override annotation. 224–227
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 238
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 238
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 257
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 257
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 277
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 277
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 281
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 283
MissingOverride The method 'getPlugin()' is missing an @Override annotation. 307–310
MissingOverride The method 'setPlugin(Plugin)' is missing an @Override annotation. 318–321
MissingOverride The method 'getAnonymize()' is missing an @Override annotation. 328–331
MissingOverride The method 'setAnonymize(boolean)' is missing an @Override annotation. 339–342
MissingOverride The method 'isShownInSearch()' is missing an @Override annotation. 349–352
MissingOverride The method 'setShownInSearch(boolean)' is missing an @Override annotation. 360–363
MissingOverride The method 'getUserFieldsData(HttpServletRequest, int)' is missing an @Override annotation. 374–379

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeComboBox.java

Rule Violation Line
CallSuperInConstructor It is a good practice to call super() in a constructor 82–84
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 82–84
UncommentedEmptyConstructor Document empty constructor 82–84
MissingOverride The method 'getTemplateCreateAttribute()' is missing an @Override annotation. 91–94
MissingOverride The method 'getTemplateModifyAttribute()' is missing an @Override annotation. 101–104
MissingOverride The method 'getTemplateHtmlFormAttribute()' is missing an @Override annotation. 111–114
MissingOverride The method 'getTemplateHtmlFormSearchAttribute()' is missing an @Override annotation. 121–124
MissingOverride The method 'getPropertyCreatePageTitle()' is missing an @Override annotation. 131–134
MissingOverride The method 'getPropertyModifyPageTitle()' is missing an @Override annotation. 141–144
LinguisticNaming Linguistics Antipattern - The setter 'setAttributeData' should not return any type except void linguistically 153–182
MissingOverride The method 'setAttributeData(HttpServletRequest)' is missing an @Override annotation. 153–182
ConfusingTernary Avoid if (x != y) ..; else ..; 156
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 156
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 157
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 158
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 159
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 173
MissingOverride The method 'setAttributeType(Locale)' is missing an @Override annotation. 190–197
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 205
AvoidReassigningLoopVariables Avoid reassigning the loop control variable 'strValue' 216
MissingOverride The method 'isAnonymizable()' is missing an @Override annotation. 254–257

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeDAO.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 53–461
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 407

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeFieldDAO.java

Rule Violation Line
MissingOverride The method 'load(int, Plugin)' is missing an @Override annotation. 135–162
MissingOverride The method 'selectAttributeByIdField(int, Plugin)' is missing an @Override annotation. 173–208
MissingOverride The method 'selectAttributeFieldsByIdAttribute(int, Plugin)' is missing an @Override annotation. 219–248
MissingOverride The method 'insert(AttributeField, Plugin)' is missing an @Override annotation. 259–279
MissingOverride The method 'store(AttributeField, Plugin)' is missing an @Override annotation. 289–305
MissingOverride The method 'delete(int, Plugin)' is missing an @Override annotation. 315–323
MissingOverride The method 'deleteAttributeFieldsFromIdAttribute(int, Plugin)' is missing an @Override annotation. 333–341

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeFieldHome.java

Rule Violation Line
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. 47–144

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeHome.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 49–221
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. 49–221

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeText.java

Rule Violation Line
CallSuperInConstructor It is a good practice to call super() in a constructor 85–87
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 85–87
UncommentedEmptyConstructor Document empty constructor 85–87
MissingOverride The method 'getTemplateCreateAttribute()' is missing an @Override annotation. 94–97
MissingOverride The method 'getTemplateModifyAttribute()' is missing an @Override annotation. 104–107
MissingOverride The method 'getTemplateHtmlFormAttribute()' is missing an @Override annotation. 114–117
MissingOverride The method 'getTemplateHtmlFormSearchAttribute()' is missing an @Override annotation. 124–127
MissingOverride The method 'getPropertyCreatePageTitle()' is missing an @Override annotation. 134–137
MissingOverride The method 'getPropertyModifyPageTitle()' is missing an @Override annotation. 144–147
MissingOverride The method 'setAttributeData(HttpServletRequest)' is missing an @Override annotation. 156–219
LinguisticNaming Linguistics Antipattern - The setter 'setAttributeData' should not return any type except void linguistically 156–219
ConfusingTernary Avoid if (x != y) ..; else ..; 159
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 159
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 160
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 161
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 162
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 163
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 164
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 208
MissingOverride The method 'setAttributeType(Locale)' is missing an @Override annotation. 227–234
MissingOverride The method 'getUserFieldsData(String, int)' is missing an @Override annotation. 245–270
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 247
MissingOverride The method 'isAnonymizable()' is missing an @Override annotation. 277–280

fr/paris/lutece/plugins/mylutece/business/attribute/IAttribute.java

Rule Violation Line
LinguisticNaming Linguistics Antipattern - The setter 'setAttributeData' should not return any type except void linguistically 266

fr/paris/lutece/plugins/mylutece/business/attribute/IAttributeDAO.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 48–182

fr/paris/lutece/plugins/mylutece/business/attribute/MyLuteceUserFieldDAO.java

Rule Violation Line
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 338

fr/paris/lutece/plugins/mylutece/business/attribute/MyLuteceUserFieldFilter.java

Rule Violation Line
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 104
AvoidPrintStackTrace Avoid printStackTrace(); use a logger call instead. 143
AvoidPrintStackTrace Avoid printStackTrace(); use a logger call instead. 173

fr/paris/lutece/plugins/mylutece/business/attribute/MyLuteceUserFieldHome.java

Rule Violation Line
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. 48–174

fr/paris/lutece/plugins/mylutece/business/portlet/IMyLutecePortletDAO.java

Rule Violation Line
MissingOverride The method 'delete(int)' is missing an @Override annotation. 51
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 59
MissingOverride The method 'load(int)' is missing an @Override annotation. 68
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 76

fr/paris/lutece/plugins/mylutece/business/portlet/MyLutecePortlet.java

Rule Violation Line
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 77–79
CallSuperInConstructor It is a good practice to call super() in a constructor 77–79
UncommentedEmptyConstructor Document empty constructor 77–79
ExcessiveMethodLength Avoid really long methods. 88–192
CyclomaticComplexity The method 'getXml(HttpServletRequest)' has a cyclomatic complexity of 13. 88–192
MissingOverride The method 'getXml(HttpServletRequest)' is missing an @Override annotation. 88–192
ConfusingTernary Avoid if (x != y) ..; else ..; 104–187
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 113
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 113
ConfusingTernary Avoid if (x != y) ..; else ..; 135–136
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 157
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 157
MissingOverride The method 'getXmlDocument(HttpServletRequest)' is missing an @Override annotation. 201–204
MissingOverride The method 'remove()' is missing an @Override annotation. 217–220

fr/paris/lutece/plugins/mylutece/business/portlet/MyLutecePortletDAO.java

Rule Violation Line
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 52–55
MissingOverride The method 'delete(int)' is missing an @Override annotation. 63–66
MissingOverride The method 'load(int)' is missing an @Override annotation. 75–81
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'portlet' 80
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 89–92

fr/paris/lutece/plugins/mylutece/business/portlet/MyLutecePortletHome.java

Rule Violation Line
AssignmentToNonFinalStatic Possible unsafe assignment to a non-final static field in a constructor. 50
RedundantFieldInitializer Avoid using redundant field initializer for '_singleton' 50
CallSuperInConstructor It is a good practice to call super() in a constructor 55–61
NonThreadSafeSingleton Singleton is not thread safe 70–73
MissingOverride The method 'getDAO()' is missing an @Override annotation. 83–86
MissingOverride The method 'getPortletTypeId()' is missing an @Override annotation. 93–99
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strPortletTypeId' 98

fr/paris/lutece/plugins/mylutece/service/AbstractAccountLifeTimeDaemon.java

Rule Violation Line
NPathComplexity The method 'run()' has an NPath complexity of 255024 99–355
ExcessiveMethodLength Avoid really long methods. 99–355
NcssCount The method 'run()' has a NCSS line count of 148. 99–355
CyclomaticComplexity The method 'run()' has a cyclomatic complexity of 38. 99–355
InsufficientStringBufferDeclaration StringBuffer constructor is initialized with size 16, but has at least 134 characters appended. 110
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 113
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 133
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 133
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 140
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 147
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 155
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 160
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 171
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 177
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 197
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 197
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 204
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 218
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 223
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 235
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 242
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 263
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 263
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 270
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 285
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 290
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 301
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 322
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 322
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 340
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 345
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 351

fr/paris/lutece/plugins/mylutece/service/AbstractAnonymizationDaemon.java

Rule Violation Line
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 76

fr/paris/lutece/plugins/mylutece/service/IMyLuteceExternalIdentityProviderService.java

Rule Violation Line
UnnecessaryModifier Unnecessary modifier 'public' on method 'getIdentityInformations': the method is declared in an interface type 55

fr/paris/lutece/plugins/mylutece/service/IMyLuteceExternalIdentityService.java

Rule Violation Line
CommentRequired Header comments are required 42–78
CommentRequired Public method and constructor comments are required 76

fr/paris/lutece/plugins/mylutece/service/MyLuteceDefaultRoleProvider.java

Rule Violation Line
ConfusingTernary Avoid if (x != y) ..; else ..; 69–76
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 85
ConfusingTernary Avoid if (x != y) ..; else ..; 90–102

fr/paris/lutece/plugins/mylutece/service/MyLuteceExternalIdentityService.java

Rule Violation Line
CommentRequired Header comments are required 49–182
NonThreadSafeSingleton Singleton is not thread safe 66–96
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 73
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 80–93
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 84–92
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 116
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 116
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 149
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 153
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 159–163
MissingOverride The method 'getProviders()' is missing an @Override annotation. 175–180

fr/paris/lutece/plugins/mylutece/service/MyLutecePlugin.java

Rule Violation Line
MissingOverride The method 'init()' is missing an @Override annotation. 51–53
UncommentedEmptyMethodBody Document empty method body 52–53

fr/paris/lutece/plugins/mylutece/service/MyLuteceResourceIdService.java

Rule Violation Line
CallSuperInConstructor It is a good practice to call super() in a constructor 65–68
MissingOverride The method 'register()' is missing an @Override annotation. 73–102
ShortVariable Avoid variables with short names like rt 75
ShortVariable Avoid variables with short names like p 81
MissingOverride The method 'getResourceIdList(Locale)' is missing an @Override annotation. 111–114
MissingOverride The method 'getTitle(String, Locale)' is missing an @Override annotation. 125–128

fr/paris/lutece/plugins/mylutece/service/MyLuteceUserAttributesService.java

Rule Violation Line
MissingOverride The method 'getAttribute(String, String)' is missing an @Override annotation. 55–66
MissingOverride The method 'getAttributes(String)' is missing an @Override annotation. 71–82
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 73
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 73

fr/paris/lutece/plugins/mylutece/service/MyLuteceUserService.java

Rule Violation Line
CommentRequired Header comments are required 47–90
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. 48–90
ConfusingTernary Avoid if (x != y) ..; else ..; 70

fr/paris/lutece/plugins/mylutece/service/MyluteceExternalRoleService.java

Rule Violation Line
NonThreadSafeSingleton Singleton is not thread safe 34–42

fr/paris/lutece/plugins/mylutece/service/RoleResourceIdService.java

Rule Violation Line
CallSuperInConstructor It is a good practice to call super() in a constructor 59–62
MissingOverride The method 'register()' is missing an @Override annotation. 67–81
ShortVariable Avoid variables with short names like rt 69
ShortVariable Avoid variables with short names like p 75
MissingOverride The method 'getResourceIdList(Locale)' is missing an @Override annotation. 90–93
MissingOverride The method 'getTitle(String, Locale)' is missing an @Override annotation. 104–114

fr/paris/lutece/plugins/mylutece/service/attribute/MyLuteceUserFieldListenerService.java

Rule Violation Line
ImmutableField Private field '_listRegisteredListeners' could be made final; it is only initialized in the declaration or constructor. 53
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 53

fr/paris/lutece/plugins/mylutece/service/attribute/MyLuteceUserFieldService.java

Rule Violation Line
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. 60–218

fr/paris/lutece/plugins/mylutece/service/security/AuthenticationFilterService.java

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

fr/paris/lutece/plugins/mylutece/util/SecurityUtils.java

Rule Violation Line
GodClass Possible God Class (WMC=65, ATFD=72, TCC=13.547%) 67–928
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. 68–928
TooManyMethods This class has too many methods, consider refactoring it. 68–928
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'nValue' 428
SimplifiedTernary Ternary operators that can be simplified with || or && 451
CyclomaticComplexity The method 'checkPasswordForFrontOffice(IUserParameterService, Plugin, String, int)' has a cyclomatic complexity of 10. 731–790
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 755–758
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 760–763
SimplifiedTernary Ternary operators that can be simplified with || or && 925–926

fr/paris/lutece/plugins/mylutece/web/AbstractManageMyluteceJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 50–98

fr/paris/lutece/plugins/mylutece/web/ManageMyLuteceJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 65–173
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 104
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 104
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 105
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 105

fr/paris/lutece/plugins/mylutece/web/MyLuteceApp.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 34–715
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 82–715
GodClass Possible God Class (WMC=60, ATFD=88, TCC=6.719%) 82–715
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 160–162
UncommentedEmptyConstructor Document empty constructor 160–162
MissingOverride The method 'getPage(HttpServletRequest, int, Plugin)' is missing an @Override annotation. 175–203
CyclomaticComplexity The method 'getLoginPage(XPage, HttpServletRequest)' has a cyclomatic complexity of 10. 214–291
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 216
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 216
ExcessiveMethodLength Avoid really long methods. 301–407
CyclomaticComplexity The method 'doLogin(HttpServletRequest)' has a cyclomatic complexity of 16. 301–407
NPathComplexity The method 'doLogin(HttpServletRequest)' has an NPath complexity of 360 301–407
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 317
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 347
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 351
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 357
AvoidInstanceofChecksInCatchClause An instanceof check is being performed on the caught exception. Create a separate catch clause for this exception type. 360
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 370
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 374
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 380
ConfusingTernary Avoid if (x != y) ..; else ..; 396–404
LinguisticNaming Linguistics Antipattern - The method 'isUserAuthenticated' indicates linguistically it returns a boolean, but it returns 'String' 416–434
ConfusingTernary Avoid if (x != y) ..; else ..; 424–431
UnusedFormalParameter Avoid unused method parameters such as 'request'. 551
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 553
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 553
ShortVariable Avoid variables with short names like t 561
ShortVariable Avoid variables with short names like t 580
ShortVariable Avoid variables with short names like t 599
ShortVariable Avoid variables with short names like t 618
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strNextUrl' 690

fr/paris/lutece/plugins/mylutece/web/attribute/AttributeFieldJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 63–364
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 111
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 111
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 160
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 185
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 185
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 208
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 236
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 278
ShortVariable Avoid variables with short names like it 300
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 320
ShortVariable Avoid variables with short names like it 342
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 362

fr/paris/lutece/plugins/mylutece/web/attribute/AttributeJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 66–432
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 119
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 119
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 150–155
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 156–160
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 167
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 167
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 201–206
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 207–211
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 263
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 263
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 334
ShortVariable Avoid variables with short names like it 374
ShortVariable Avoid variables with short names like it 412

fr/paris/lutece/plugins/mylutece/web/includes/UserLoginInclude.java

Rule Violation Line
MissingOverride The method 'fillTemplate(Map, PageData, int, HttpServletRequest)' is missing an @Override annotation. 86–151
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 91
CollapsibleIfStatements These nested if statements could be combined 95–145
ConfusingTernary Avoid if (x != y) ..; else ..; 104–122
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 115–118
ShortVariable Avoid variables with short names like t 124

fr/paris/lutece/plugins/mylutece/web/portlet/MyLutecePortletJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 47–155
UncommentedEmptyConstructor Document empty constructor 61–63
CallSuperInConstructor It is a good practice to call super() in a constructor 61–63
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 61–63
MissingOverride The method 'getCreate(HttpServletRequest)' is missing an @Override annotation. 72–79
MissingOverride The method 'getModify(HttpServletRequest)' is missing an @Override annotation. 88–96
MissingOverride The method 'doCreate(HttpServletRequest)' is missing an @Override annotation. 105–125
MissingOverride The method 'doModify(HttpServletRequest)' is missing an @Override annotation. 134–154

fr/paris/lutece/plugins/mylutece/web/security/AuthenticationFilterJspBean.java

Rule Violation Line
AvoidDuplicateLiterals The String literal " is not authorized to permission " appears 7 times in this file; the first occurrence is on line 107 107
AvoidDuplicateLiterals The String literal "User " appears 7 times in this file; the first occurrence is on line 107 107
UnnecessaryConversionTemporary Avoid unnecessary temporaries when converting primitives to Strings 257
ConfusingTernary Avoid if (x != y) ..; else ..; 302–303
ConfusingTernary Avoid if (x != y) ..; else ..; 304–305

fr/paris/lutece/plugins/mylutece/web/security/MyluteceAuthFilter.java

Rule Violation Line
UncommentedEmptyMethodBody Document empty method body 83–84
CyclomaticComplexity The method 'doFilter(ServletRequest, ServletResponse, FilterChain)' has a cyclomatic complexity of 10. 99–145
CyclomaticComplexity The method 'filterAccess(HttpServletRequest)' has a cyclomatic complexity of 13. 171–225
CollapsibleIfStatements These nested if statements could be combined 182–187
ConfusingTernary Avoid if (x != y) ..; else ..; 320–327

Priority 4

fr/paris/lutece/plugins/mylutece/authentication/logs/ConnectionLogDAO.java

Rule Violation Line
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 60
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 60
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 61
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 61

fr/paris/lutece/plugins/mylutece/business/attribute/AbstractAttribute.java

Rule Violation Line
BooleanGetMethodName A getX() method which returns a boolean should be named isX() 328–331

fr/paris/lutece/plugins/mylutece/business/attribute/IAttribute.java

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

fr/paris/lutece/plugins/mylutece/util/SecurityUtils.java

Rule Violation Line
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.util.Date' due to existing import 'java.util.Date' 775

fr/paris/lutece/plugins/mylutece/web/ManageMyLuteceJspBean.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.business.user.AdminUser' 53

fr/paris/lutece/plugins/mylutece/web/MyLuteceApp.java

Rule Violation Line
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 343

Files

fr/paris/lutece/plugins/mylutece/authentication/AbstractAuthentication.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 47–116
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 95–100
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 109–114

fr/paris/lutece/plugins/mylutece/authentication/ExternalAuthentication.java

Rule Violation Priority Line
MissingOverride The method 'isExternalAuthentication()' is missing an @Override annotation. 3 57–60
MissingOverride The method 'isDelegatedAuthentication()' is missing an @Override annotation. 3 68–71
MissingOverride The method 'getLoginPageUrl()' is missing an @Override annotation. 3 78–81
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 78–81
MissingOverride The method 'getDoLoginUrl()' is missing an @Override annotation. 3 88–91
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 88–91
MissingOverride The method 'getDoLogoutUrl()' is missing an @Override annotation. 3 98–101
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 98–101
MissingOverride The method 'getNewAccountPageUrl()' is missing an @Override annotation. 3 108–111
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 108–111
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 118–121
MissingOverride The method 'getViewAccountPageUrl()' is missing an @Override annotation. 3 118–121
MissingOverride The method 'getLostPasswordPageUrl()' is missing an @Override annotation. 3 128–131
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 128–131
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 137–140
MissingOverride The method 'getAccessDeniedTemplate()' is missing an @Override annotation. 3 147–150
MissingOverride The method 'getAccessControledTemplate()' is missing an @Override annotation. 3 157–160
MissingOverride The method 'isUsersListAvailable()' is missing an @Override annotation. 3 167–170
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 177–180
MissingOverride The method 'getUsers()' is missing an @Override annotation. 3 177–180
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 189–192
MissingOverride The method 'getUser(String)' is missing an @Override annotation. 3 189–192
MissingOverride The method 'getRolesByUser(LuteceUser)' is missing an @Override annotation. 3 201–204
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 1 201–204
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 201–204
MissingOverride The method 'isMultiAuthenticationSupported()' is missing an @Override annotation. 3 213–216
MissingOverride The method 'getIconUrl()' is missing an @Override annotation. 3 222–225
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 242–245
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 252–254
UncommentedEmptyMethodBody Document empty method body 3 253–254

fr/paris/lutece/plugins/mylutece/authentication/MultiLuteceAuthentication.java

Rule Violation Priority Line
GodClass Possible God Class (WMC=64, ATFD=64, TCC=22.727%) 3 62–685
FieldNamingConventions The constant name '_mapAuthentications' doesn't match '[A-Z][A-Z_0-9]*' 1 66
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 66
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 66
MissingOverride The method 'getLoginPageUrl()' is missing an @Override annotation. 3 106–123
MissingOverride The method 'getDoLoginUrl()' is missing an @Override annotation. 3 131–148
MissingOverride The method 'getNewAccountPageUrl()' is missing an @Override annotation. 3 156–173
MissingOverride The method 'getViewAccountPageUrl()' is missing an @Override annotation. 3 181–198
MissingOverride The method 'getLostPasswordPageUrl()' is missing an @Override annotation. 3 206–223
MissingOverride The method 'getDoLogoutUrl()' is missing an @Override annotation. 3 302–319
MissingOverride The method 'getAccessDeniedTemplate()' is missing an @Override annotation. 3 326–329
MissingOverride The method 'getAccessControledTemplate()' is missing an @Override annotation. 3 336–339
MissingOverride The method 'getAnonymousUser()' is missing an @Override annotation. 3 345–360
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 351–357
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the AnonymousUser constructor if you want a default access modifier 3 353–356
MissingOverride The method 'getAuthServiceName()' is missing an @Override annotation. 3 366–369
MissingOverride The method 'getAuthType(HttpServletRequest)' is missing an @Override annotation. 3 375–378
MissingOverride The method 'getHttpAuthenticatedUser(HttpServletRequest)' is missing an @Override annotation. 3 388–406
MissingOverride The method 'getRolesByUser(LuteceUser)' is missing an @Override annotation. 3 412–422
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 1 412–422
MissingOverride The method 'getUser(String)' is missing an @Override annotation. 3 433–447
MissingOverride The method 'getUsers()' is missing an @Override annotation. 3 455–470
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 457
MissingOverride The method 'isExternalAuthentication()' is missing an @Override annotation. 3 476–479
MissingOverride The method 'isUserInRole(LuteceUser, HttpServletRequest, String)' is missing an @Override annotation. 3 485–500
MissingOverride The method 'isUsersListAvailable()' is missing an @Override annotation. 3 508–511
MissingOverride The method 'login(String, String, HttpServletRequest)' is missing an @Override annotation. 3 517–547
ConfusingTernary Avoid if (x != y) ..; else ..; 3 522–544
ConfusingTernary Avoid if (x != y) ..; else ..; 3 526–539
MissingOverride The method 'logout(LuteceUser)' is missing an @Override annotation. 3 553–577
ConfusingTernary Avoid if (x != y) ..; else ..; 3 555–576
ConfusingTernary Avoid if (x != y) ..; else ..; 3 559–571
MissingOverride The method 'isMultiAuthenticationSupported()' is missing an @Override annotation. 3 583–586
MissingOverride The method 'isDelegatedAuthentication()' is missing an @Override annotation. 3 604–607
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 616
MissingOverride The method 'getIconUrl()' is missing an @Override annotation. 3 641–644
MissingOverride The method 'getName()' is missing an @Override annotation. 3 652–655
MissingOverride The method 'getPluginName()' is missing an @Override annotation. 3 663–666

fr/paris/lutece/plugins/mylutece/authentication/PortalAuthentication.java

Rule Violation Priority Line
MissingOverride The method 'isExternalAuthentication()' is missing an @Override annotation. 3 57–60
MissingOverride The method 'isDelegatedAuthentication()' is missing an @Override annotation. 3 66–69
MissingOverride The method 'getLoginPageUrl()' is missing an @Override annotation. 3 75–78
MissingOverride The method 'getDoLoginUrl()' is missing an @Override annotation. 3 84–87
MissingOverride The method 'findResetPassword(HttpServletRequest, String)' is missing an @Override annotation. 3 93–96
MissingOverride The method 'getResetPasswordPageUrl(HttpServletRequest)' is missing an @Override annotation. 3 101–104
MissingOverride The method 'getNewAccountPageUrl()' is missing an @Override annotation. 3 111–114
MissingOverride The method 'getViewAccountPageUrl()' is missing an @Override annotation. 3 121–124
MissingOverride The method 'getDoLogoutUrl()' is missing an @Override annotation. 3 149–152
MissingOverride The method 'getHttpAuthenticatedUser(HttpServletRequest)' is missing an @Override annotation. 3 162–165
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 162–165
MissingOverride The method 'getAccessDeniedTemplate()' is missing an @Override annotation. 3 172–175
MissingOverride The method 'getAccessControledTemplate()' is missing an @Override annotation. 3 182–185
MissingOverride The method 'isUsersListAvailable()' is missing an @Override annotation. 3 192–195
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 202–205
MissingOverride The method 'getUsers()' is missing an @Override annotation. 3 202–205
MissingOverride The method 'getUser(String)' is missing an @Override annotation. 3 214–218
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 214–218
MissingOverride The method 'getRolesByUser(LuteceUser)' is missing an @Override annotation. 3 227–230
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 227–230
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 1 227–230
MissingOverride The method 'isMultiAuthenticationSupported()' is missing an @Override annotation. 3 238–241
MissingOverride The method 'getIconUrl()' is missing an @Override annotation. 3 247–250
EmptyMethodInAbstractClassShouldBeAbstract An empty method in an abstract class should be abstract instead 1 267–269
UncommentedEmptyMethodBody Document empty method body 3 268–269

fr/paris/lutece/plugins/mylutece/authentication/logs/ConnectionLogDAO.java

Rule Violation Priority Line
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 4 60
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 4 60
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 4 61
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 4 61

fr/paris/lutece/plugins/mylutece/business/LuteceUserAttributeDescription.java

Rule Violation Priority Line
FieldDeclarationsShouldBeAtStartOfClass Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes. 3 61
FieldDeclarationsShouldBeAtStartOfClass Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes. 3 64
FieldDeclarationsShouldBeAtStartOfClass Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes. 3 67

fr/paris/lutece/plugins/mylutece/business/LuteceUserRoleDescription.java

Rule Violation Priority Line
CallSuperInConstructor It is a good practice to call super() in a constructor 3 71–77
ConstructorCallsOverridableMethod Overridable method 'setType' called during object construction 1 75
ConstructorCallsOverridableMethod Overridable method 'setComplementaryDescription' called during object construction 1 76
FormalParameterNamingConventions The method parameter name '_strType' doesn't match '[a-z][a-zA-Z0-9]*' 1 94
FormalParameterNamingConventions The method parameter name '_strComplementaryDescription' doesn't match '[a-z][a-zA-Z0-9]*' 1 112

fr/paris/lutece/plugins/mylutece/business/attribute/AbstractAttribute.java

Rule Violation Priority Line
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 78–80
UncommentedEmptyConstructor Document empty constructor 3 78–80
MissingOverride The method 'getIdAttribute()' is missing an @Override annotation. 3 87–90
MissingOverride The method 'setIdAttribute(int)' is missing an @Override annotation. 3 98–101
MissingOverride The method 'isMandatory()' is missing an @Override annotation. 3 108–111
MissingOverride The method 'setMandatory(boolean)' is missing an @Override annotation. 3 119–122
MissingOverride The method 'getListAttributeFields()' is missing an @Override annotation. 3 129–132
MissingOverride The method 'setListAttributeFields(List)' is missing an @Override annotation. 3 140–143
MissingOverride The method 'getTitle()' is missing an @Override annotation. 3 150–153
MissingOverride The method 'setTitle(String)' is missing an @Override annotation. 3 161–164
MissingOverride The method 'getHelpMessage()' is missing an @Override annotation. 3 171–174
MissingOverride The method 'setHelpMessage(String)' is missing an @Override annotation. 3 182–185
MissingOverride The method 'getPosition()' is missing an @Override annotation. 3 192–195
MissingOverride The method 'setPosition(int)' is missing an @Override annotation. 3 203–206
MissingOverride The method 'getAttributeType()' is missing an @Override annotation. 3 213–216
MissingOverride The method 'setAttributeType(AttributeType)' is missing an @Override annotation. 3 224–227
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 238
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 238
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 257
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 257
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 277
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 277
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 281
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 283
MissingOverride The method 'getPlugin()' is missing an @Override annotation. 3 307–310
MissingOverride The method 'setPlugin(Plugin)' is missing an @Override annotation. 3 318–321
BooleanGetMethodName A getX() method which returns a boolean should be named isX() 4 328–331
MissingOverride The method 'getAnonymize()' is missing an @Override annotation. 3 328–331
MissingOverride The method 'setAnonymize(boolean)' is missing an @Override annotation. 3 339–342
MissingOverride The method 'isShownInSearch()' is missing an @Override annotation. 3 349–352
MissingOverride The method 'setShownInSearch(boolean)' is missing an @Override annotation. 3 360–363
MissingOverride The method 'getUserFieldsData(HttpServletRequest, int)' is missing an @Override annotation. 3 374–379

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeComboBox.java

Rule Violation Priority Line
CallSuperInConstructor It is a good practice to call super() in a constructor 3 82–84
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 82–84
UncommentedEmptyConstructor Document empty constructor 3 82–84
MissingOverride The method 'getTemplateCreateAttribute()' is missing an @Override annotation. 3 91–94
MissingOverride The method 'getTemplateModifyAttribute()' is missing an @Override annotation. 3 101–104
MissingOverride The method 'getTemplateHtmlFormAttribute()' is missing an @Override annotation. 3 111–114
MissingOverride The method 'getTemplateHtmlFormSearchAttribute()' is missing an @Override annotation. 3 121–124
MissingOverride The method 'getPropertyCreatePageTitle()' is missing an @Override annotation. 3 131–134
MissingOverride The method 'getPropertyModifyPageTitle()' is missing an @Override annotation. 3 141–144
LinguisticNaming Linguistics Antipattern - The setter 'setAttributeData' should not return any type except void linguistically 3 153–182
MissingOverride The method 'setAttributeData(HttpServletRequest)' is missing an @Override annotation. 3 153–182
ConfusingTernary Avoid if (x != y) ..; else ..; 3 156
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 156
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 157
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 158
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 159
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 173
MissingOverride The method 'setAttributeType(Locale)' is missing an @Override annotation. 3 190–197
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 205
AvoidReassigningLoopVariables Avoid reassigning the loop control variable 'strValue' 3 216
MissingOverride The method 'isAnonymizable()' is missing an @Override annotation. 3 254–257

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeDAO.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 53–461
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 407

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeFieldDAO.java

Rule Violation Priority Line
MissingOverride The method 'load(int, Plugin)' is missing an @Override annotation. 3 135–162
MissingOverride The method 'selectAttributeByIdField(int, Plugin)' is missing an @Override annotation. 3 173–208
MissingOverride The method 'selectAttributeFieldsByIdAttribute(int, Plugin)' is missing an @Override annotation. 3 219–248
MissingOverride The method 'insert(AttributeField, Plugin)' is missing an @Override annotation. 3 259–279
MissingOverride The method 'store(AttributeField, Plugin)' is missing an @Override annotation. 3 289–305
MissingOverride The method 'delete(int, Plugin)' is missing an @Override annotation. 3 315–323
MissingOverride The method 'deleteAttributeFieldsFromIdAttribute(int, Plugin)' is missing an @Override annotation. 3 333–341

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeFieldHome.java

Rule Violation Priority Line
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 47–144

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeHome.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 49–221
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 49–221

fr/paris/lutece/plugins/mylutece/business/attribute/AttributeText.java

Rule Violation Priority Line
CallSuperInConstructor It is a good practice to call super() in a constructor 3 85–87
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 85–87
UncommentedEmptyConstructor Document empty constructor 3 85–87
MissingOverride The method 'getTemplateCreateAttribute()' is missing an @Override annotation. 3 94–97
MissingOverride The method 'getTemplateModifyAttribute()' is missing an @Override annotation. 3 104–107
MissingOverride The method 'getTemplateHtmlFormAttribute()' is missing an @Override annotation. 3 114–117
MissingOverride The method 'getTemplateHtmlFormSearchAttribute()' is missing an @Override annotation. 3 124–127
MissingOverride The method 'getPropertyCreatePageTitle()' is missing an @Override annotation. 3 134–137
MissingOverride The method 'getPropertyModifyPageTitle()' is missing an @Override annotation. 3 144–147
MissingOverride The method 'setAttributeData(HttpServletRequest)' is missing an @Override annotation. 3 156–219
LinguisticNaming Linguistics Antipattern - The setter 'setAttributeData' should not return any type except void linguistically 3 156–219
ConfusingTernary Avoid if (x != y) ..; else ..; 3 159
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 159
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 160
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 161
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 162
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 163
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 164
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 208
MissingOverride The method 'setAttributeType(Locale)' is missing an @Override annotation. 3 227–234
MissingOverride The method 'getUserFieldsData(String, int)' is missing an @Override annotation. 3 245–270
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 247
MissingOverride The method 'isAnonymizable()' is missing an @Override annotation. 3 277–280

fr/paris/lutece/plugins/mylutece/business/attribute/IAttribute.java

Rule Violation Priority Line
BooleanGetMethodName A getX() method which returns a boolean should be named isX() 4 173
LinguisticNaming Linguistics Antipattern - The setter 'setAttributeData' should not return any type except void linguistically 3 266

fr/paris/lutece/plugins/mylutece/business/attribute/IAttributeDAO.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 48–182

fr/paris/lutece/plugins/mylutece/business/attribute/MyLuteceUserFieldDAO.java

Rule Violation Priority Line
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 3 338

fr/paris/lutece/plugins/mylutece/business/attribute/MyLuteceUserFieldFilter.java

Rule Violation Priority Line
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 104
AvoidPrintStackTrace Avoid printStackTrace(); use a logger call instead. 3 143
AvoidPrintStackTrace Avoid printStackTrace(); use a logger call instead. 3 173

fr/paris/lutece/plugins/mylutece/business/attribute/MyLuteceUserFieldHome.java

Rule Violation Priority Line
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 48–174

fr/paris/lutece/plugins/mylutece/business/portlet/IMyLutecePortletDAO.java

Rule Violation Priority Line
MissingOverride The method 'delete(int)' is missing an @Override annotation. 3 51
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 3 59
MissingOverride The method 'load(int)' is missing an @Override annotation. 3 68
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 3 76

fr/paris/lutece/plugins/mylutece/business/portlet/MyLutecePortlet.java

Rule Violation Priority Line
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 77–79
CallSuperInConstructor It is a good practice to call super() in a constructor 3 77–79
UncommentedEmptyConstructor Document empty constructor 3 77–79
ExcessiveMethodLength Avoid really long methods. 3 88–192
CyclomaticComplexity The method 'getXml(HttpServletRequest)' has a cyclomatic complexity of 13. 3 88–192
MissingOverride The method 'getXml(HttpServletRequest)' is missing an @Override annotation. 3 88–192
ConfusingTernary Avoid if (x != y) ..; else ..; 3 104–187
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 113
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 113
ConfusingTernary Avoid if (x != y) ..; else ..; 3 135–136
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 157
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 157
MissingOverride The method 'getXmlDocument(HttpServletRequest)' is missing an @Override annotation. 3 201–204
MissingOverride The method 'remove()' is missing an @Override annotation. 3 217–220

fr/paris/lutece/plugins/mylutece/business/portlet/MyLutecePortletDAO.java

Rule Violation Priority Line
MissingOverride The method 'insert(Portlet)' is missing an @Override annotation. 3 52–55
MissingOverride The method 'delete(int)' is missing an @Override annotation. 3 63–66
MissingOverride The method 'load(int)' is missing an @Override annotation. 3 75–81
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'portlet' 3 80
MissingOverride The method 'store(Portlet)' is missing an @Override annotation. 3 89–92

fr/paris/lutece/plugins/mylutece/business/portlet/MyLutecePortletHome.java

Rule Violation Priority Line
AssignmentToNonFinalStatic Possible unsafe assignment to a non-final static field in a constructor. 3 50
RedundantFieldInitializer Avoid using redundant field initializer for '_singleton' 3 50
CallSuperInConstructor It is a good practice to call super() in a constructor 3 55–61
NonThreadSafeSingleton Singleton is not thread safe 3 70–73
MissingOverride The method 'getDAO()' is missing an @Override annotation. 3 83–86
MissingOverride The method 'getPortletTypeId()' is missing an @Override annotation. 3 93–99
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strPortletTypeId' 3 98

fr/paris/lutece/plugins/mylutece/service/AbstractAccountLifeTimeDaemon.java

Rule Violation Priority Line
NPathComplexity The method 'run()' has an NPath complexity of 255024 3 99–355
ExcessiveMethodLength Avoid really long methods. 3 99–355
NcssCount The method 'run()' has a NCSS line count of 148. 3 99–355
CyclomaticComplexity The method 'run()' has a cyclomatic complexity of 38. 3 99–355
InsufficientStringBufferDeclaration StringBuffer constructor is initialized with size 16, but has at least 134 characters appended. 3 110
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 113
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 133
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 133
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 140
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 147
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 155
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 160
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 171
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 177
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 197
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 197
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 204
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 218
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 223
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 235
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 242
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 263
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 263
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 270
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 285
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 290
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 301
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 322
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 322
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 340
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 345
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 351

fr/paris/lutece/plugins/mylutece/service/AbstractAnonymizationDaemon.java

Rule Violation Priority Line
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 76

fr/paris/lutece/plugins/mylutece/service/IMyLuteceExternalIdentityProviderService.java

Rule Violation Priority Line
UnnecessaryModifier Unnecessary modifier 'public' on method 'getIdentityInformations': the method is declared in an interface type 3 55

fr/paris/lutece/plugins/mylutece/service/IMyLuteceExternalIdentityService.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 42–78
CommentRequired Public method and constructor comments are required 3 76

fr/paris/lutece/plugins/mylutece/service/MyLuteceDefaultRoleProvider.java

Rule Violation Priority Line
ConfusingTernary Avoid if (x != y) ..; else ..; 3 69–76
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 85
ConfusingTernary Avoid if (x != y) ..; else ..; 3 90–102

fr/paris/lutece/plugins/mylutece/service/MyLuteceExternalIdentityService.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 49–182
FieldNamingConventions The static field name 'ATTRIBUTE_USER_MAPPING' doesn't match '_[a-z][a-zA-Z0-9]*' 1 54
AvoidUsingVolatile Use of modifier volatile is not recommended. 2 56
NonThreadSafeSingleton Singleton is not thread safe 3 66–96
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 73
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 3 80–93
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 84–92
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 116
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 116
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 2 121
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 149
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 153
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 3 159–163
MissingOverride The method 'getProviders()' is missing an @Override annotation. 3 175–180

fr/paris/lutece/plugins/mylutece/service/MyLutecePlugin.java

Rule Violation Priority Line
MissingOverride The method 'init()' is missing an @Override annotation. 3 51–53
UncommentedEmptyMethodBody Document empty method body 3 52–53

fr/paris/lutece/plugins/mylutece/service/MyLuteceResourceIdService.java

Rule Violation Priority Line
CallSuperInConstructor It is a good practice to call super() in a constructor 3 65–68
MissingOverride The method 'register()' is missing an @Override annotation. 3 73–102
ShortVariable Avoid variables with short names like rt 3 75
ShortVariable Avoid variables with short names like p 3 81
MissingOverride The method 'getResourceIdList(Locale)' is missing an @Override annotation. 3 111–114
MissingOverride The method 'getTitle(String, Locale)' is missing an @Override annotation. 3 125–128

fr/paris/lutece/plugins/mylutece/service/MyLuteceUserAttributesService.java

Rule Violation Priority Line
MissingOverride The method 'getAttribute(String, String)' is missing an @Override annotation. 3 55–66
MissingOverride The method 'getAttributes(String)' is missing an @Override annotation. 3 71–82
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 73
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 73

fr/paris/lutece/plugins/mylutece/service/MyLuteceUserService.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 47–90
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 48–90
ConfusingTernary Avoid if (x != y) ..; else ..; 3 70

fr/paris/lutece/plugins/mylutece/service/MyluteceExternalRoleService.java

Rule Violation Priority Line
AvoidUsingVolatile Use of modifier volatile is not recommended. 2 22
NonThreadSafeSingleton Singleton is not thread safe 3 34–42

fr/paris/lutece/plugins/mylutece/service/RoleResourceIdService.java

Rule Violation Priority Line
CallSuperInConstructor It is a good practice to call super() in a constructor 3 59–62
MissingOverride The method 'register()' is missing an @Override annotation. 3 67–81
ShortVariable Avoid variables with short names like rt 3 69
ShortVariable Avoid variables with short names like p 3 75
MissingOverride The method 'getResourceIdList(Locale)' is missing an @Override annotation. 3 90–93
MissingOverride The method 'getTitle(String, Locale)' is missing an @Override annotation. 3 104–114

fr/paris/lutece/plugins/mylutece/service/attribute/MyLuteceUserFieldListenerService.java

Rule Violation Priority Line
ImmutableField Private field '_listRegisteredListeners' could be made final; it is only initialized in the declaration or constructor. 3 53
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 53

fr/paris/lutece/plugins/mylutece/service/attribute/MyLuteceUserFieldService.java

Rule Violation Priority Line
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 60–218

fr/paris/lutece/plugins/mylutece/service/security/AuthenticationFilterService.java

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

fr/paris/lutece/plugins/mylutece/util/SecurityUtils.java

Rule Violation Priority Line
GodClass Possible God Class (WMC=65, ATFD=72, TCC=13.547%) 3 67–928
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 68–928
TooManyMethods This class has too many methods, consider refactoring it. 3 68–928
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'nValue' 3 428
SimplifiedTernary Ternary operators that can be simplified with || or && 3 451
AvoidReassigningParameters Avoid reassigning parameters such as 'strValue' 2 589
CyclomaticComplexity The method 'checkPasswordForFrontOffice(IUserParameterService, Plugin, String, int)' has a cyclomatic complexity of 10. 3 731–790
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 755–758
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 760–763
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.util.Date' due to existing import 'java.util.Date' 4 775
ReturnEmptyArrayRatherThanNull Return an empty array rather than null. 1 870–880
SimplifiedTernary Ternary operators that can be simplified with || or && 3 925–926

fr/paris/lutece/plugins/mylutece/web/AbstractManageMyluteceJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 50–98

fr/paris/lutece/plugins/mylutece/web/ManageMyLuteceJspBean.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.business.user.AdminUser' 4 53
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 65–173
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 104
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 104
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 105
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 105

fr/paris/lutece/plugins/mylutece/web/MyLuteceApp.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 34–715
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 82–715
GodClass Possible God Class (WMC=60, ATFD=88, TCC=6.719%) 3 82–715
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 160–162
UncommentedEmptyConstructor Document empty constructor 3 160–162
MissingOverride The method 'getPage(HttpServletRequest, int, Plugin)' is missing an @Override annotation. 3 175–203
CyclomaticComplexity The method 'getLoginPage(XPage, HttpServletRequest)' has a cyclomatic complexity of 10. 3 214–291
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 216
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 216
ExcessiveMethodLength Avoid really long methods. 3 301–407
CyclomaticComplexity The method 'doLogin(HttpServletRequest)' has a cyclomatic complexity of 16. 3 301–407
NPathComplexity The method 'doLogin(HttpServletRequest)' has an NPath complexity of 360 3 301–407
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 317
UnnecessaryFullyQualifiedName Unnecessary use of fully qualified name 'java.sql.Timestamp' due to existing import 'java.sql.Timestamp' 4 343
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 347
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 351
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 357
AvoidInstanceofChecksInCatchClause An instanceof check is being performed on the caught exception. Create a separate catch clause for this exception type. 3 360
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 370
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 374
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 380
ConfusingTernary Avoid if (x != y) ..; else ..; 3 396–404
LinguisticNaming Linguistics Antipattern - The method 'isUserAuthenticated' indicates linguistically it returns a boolean, but it returns 'String' 3 416–434
ConfusingTernary Avoid if (x != y) ..; else ..; 3 424–431
UnusedFormalParameter Avoid unused method parameters such as 'request'. 3 551
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 553
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 553
ShortVariable Avoid variables with short names like t 3 561
ShortVariable Avoid variables with short names like t 3 580
ShortVariable Avoid variables with short names like t 3 599
ShortVariable Avoid variables with short names like t 3 618
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strNextUrl' 3 690

fr/paris/lutece/plugins/mylutece/web/attribute/AttributeFieldJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 63–364
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 111
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 111
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 3 160
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 185
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 185
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 208
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 3 236
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 3 278
ShortVariable Avoid variables with short names like it 3 300
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 3 320
ShortVariable Avoid variables with short names like it 3 342
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 3 362

fr/paris/lutece/plugins/mylutece/web/attribute/AttributeJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 66–432
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 119
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 119
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 3 150–155
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 3 156–160
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 167
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 167
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 3 201–206
IdenticalCatchBranches 'catch' branch identical to 'ClassNotFoundException' branch 3 207–211
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 263
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 263
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'strUrl' 3 334
ShortVariable Avoid variables with short names like it 3 374
ShortVariable Avoid variables with short names like it 3 412

fr/paris/lutece/plugins/mylutece/web/includes/UserLoginInclude.java

Rule Violation Priority Line
MissingOverride The method 'fillTemplate(Map, PageData, int, HttpServletRequest)' is missing an @Override annotation. 3 86–151
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 91
CollapsibleIfStatements These nested if statements could be combined 3 95–145
ConfusingTernary Avoid if (x != y) ..; else ..; 3 104–122
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 115–118
ShortVariable Avoid variables with short names like t 3 124

fr/paris/lutece/plugins/mylutece/web/portlet/MyLutecePortletJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 47–155
UncommentedEmptyConstructor Document empty constructor 3 61–63
CallSuperInConstructor It is a good practice to call super() in a constructor 3 61–63
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 61–63
MissingOverride The method 'getCreate(HttpServletRequest)' is missing an @Override annotation. 3 72–79
MissingOverride The method 'getModify(HttpServletRequest)' is missing an @Override annotation. 3 88–96
MissingOverride The method 'doCreate(HttpServletRequest)' is missing an @Override annotation. 3 105–125
MissingOverride The method 'doModify(HttpServletRequest)' is missing an @Override annotation. 3 134–154

fr/paris/lutece/plugins/mylutece/web/security/AuthenticationFilterJspBean.java

Rule Violation Priority Line
AvoidDuplicateLiterals The String literal " is not authorized to permission " appears 7 times in this file; the first occurrence is on line 107 3 107
AvoidDuplicateLiterals The String literal "User " appears 7 times in this file; the first occurrence is on line 107 3 107
BooleanInstantiation Avoid instantiating Boolean objects; reference Boolean.TRUE or Boolean.FALSE or call Boolean.valueOf() instead. 2 257
UnnecessaryConversionTemporary Avoid unnecessary temporaries when converting primitives to Strings 3 257
ConfusingTernary Avoid if (x != y) ..; else ..; 3 302–303
ConfusingTernary Avoid if (x != y) ..; else ..; 3 304–305

fr/paris/lutece/plugins/mylutece/web/security/MyluteceAuthFilter.java

Rule Violation Priority Line
UncommentedEmptyMethodBody Document empty method body 3 83–84
CyclomaticComplexity The method 'doFilter(ServletRequest, ServletResponse, FilterChain)' has a cyclomatic complexity of 10. 3 99–145
CyclomaticComplexity The method 'filterAccess(HttpServletRequest)' has a cyclomatic complexity of 13. 3 171–225
CollapsibleIfStatements These nested if statements could be combined 3 182–187
ConfusingTernary Avoid if (x != y) ..; else ..; 3 320–327