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/notificationstore/business/AbstractFilterDao.java

Rule Violation Line
FieldNamingConventions The constant name '_listPrefixToRemove' doesn't match '[A-Z][A-Z_0-9]*' 74
FieldNamingConventions The constant name '_listTypeAllowedForSearch' doesn't match '[A-Z][A-Z_0-9]*' 75
FieldNamingConventions The final field name '_clazz' doesn't match '[a-z][a-zA-Z0-9]*' 77
ConstructorCallsOverridableMethod Overridable method 'initMapSql' called during object construction 94
FormalParameterNamingConventions The method parameter name 'SQL_QUERY_SELECTALL_ID' doesn't match '[a-z][a-zA-Z0-9]*' 109
LocalVariableNamingConventions The local variable name 'WhereClauses' doesn't match '[a-z][a-zA-Z0-9]*' 133

fr/paris/lutece/plugins/notificationstore/business/DemandDAO.java

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

fr/paris/lutece/plugins/notificationstore/business/DemandTypeHome.java

Rule Violation Line
FormalParameterNamingConventions The method parameter name 'type_id' doesn't match '[a-z][a-zA-Z0-9]*' 119

fr/paris/lutece/plugins/notificationstore/business/TemporaryStatusDAO.java

Rule Violation Line
FieldNamingConventions The constant name '_plugin' doesn't match '[A-Z][A-Z_0-9]*' 65

fr/paris/lutece/plugins/notificationstore/service/CustomerProvider.java

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

fr/paris/lutece/plugins/notificationstore/service/DemandService.java

Rule Violation Line
FormalParameterNamingConventions The method parameter name '_demandDao' doesn't match '[a-z][a-zA-Z0-9]*' 101
FormalParameterNamingConventions The method parameter name '_notificationEventDao' doesn't match '[a-z][a-zA-Z0-9]*' 101
FormalParameterNamingConventions The method parameter name '_notificationDao' doesn't match '[a-z][a-zA-Z0-9]*' 101
FormalParameterNamingConventions The method parameter name '_statusDao' doesn't match '[a-z][a-zA-Z0-9]*' 102
FormalParameterNamingConventions The method parameter name 'type_id' doesn't match '[a-z][a-zA-Z0-9]*' 350

fr/paris/lutece/plugins/notificationstore/service/NotificationService.java

Rule Violation Line
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 74757

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusCacheService.java

Rule Violation Line
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 47108

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusService.java

Rule Violation Line
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 55259

fr/paris/lutece/plugins/notificationstore/utils/NotificationStoreConstants.java

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

fr/paris/lutece/plugins/notificationstore/web/AbstractJspBean.java

Rule Violation Line
LocalVariableNamingConventions The local variable name '_model' doesn't match '[a-z][a-zA-Z0-9]*' 224
FormalParameterNamingConventions The method parameter name '_mapFilterCriteria' doesn't match '[a-z][a-zA-Z0-9]*' 245

fr/paris/lutece/plugins/notificationstore/web/DemandTypeJspBean.java

Rule Violation Line
FormalParameterNamingConventions The method parameter name '_mapFilterCriteria' doesn't match '[a-z][a-zA-Z0-9]*' 151

fr/paris/lutece/plugins/notificationstore/web/StatusJspBean.java

Rule Violation Line
FormalParameterNamingConventions The method parameter name '_mapFilterCriteria' doesn't match '[a-z][a-zA-Z0-9]*' 321

fr/paris/lutece/plugins/notificationstore/web/rs/DemandTypeRestService.java

Rule Violation Line
LocalVariableNamingConventions The local variable name '_mapper' doesn't match '[a-z][a-zA-Z0-9]*' 114

fr/paris/lutece/plugins/notificationstore/web/rs/swagger/SwaggerConstants.java

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

Priority 2

fr/paris/lutece/plugins/notificationstore/business/DemandDAO.java

Rule Violation Line
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 445
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 466

fr/paris/lutece/plugins/notificationstore/business/NotificationContentHome.java

Rule Violation Line
AvoidReassigningParameters Avoid reassigning parameters such as 'strNotificationContent' 326

fr/paris/lutece/plugins/notificationstore/service/CustomerProvider.java

Rule Violation Line
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 232

fr/paris/lutece/plugins/notificationstore/service/JsonGeneration.java

Rule Violation Line
SystemPrintln System.out.println is used 80
SystemPrintln System.out.println is used 100
SystemPrintln System.out.println is used 157

fr/paris/lutece/plugins/notificationstore/service/NotificationService.java

Rule Violation Line
GuardLogStatement Logger calls should be surrounded by log level guards. 334
GuardLogStatement Logger calls should be surrounded by log level guards. 390
GuardLogStatement Logger calls should be surrounded by log level guards. 730

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusService.java

Rule Violation Line
AvoidReassigningParameters Avoid reassigning parameters such as 'strStatus' 193

Priority 3

fr/paris/lutece/plugins/notificationstore/business/AbstractFilterDao.java

Rule Violation Line
AbstractClassWithoutAbstractMethod This abstract class does not have any abstract methods 50331
CommentRequired Header comments are required 50331
LooseCoupling Avoid using implementation types like 'HashMap'; use the interface instead 54
CommentRequired Protected method constructor comments are required 8195
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 114
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 115
CollapsibleIfStatements These nested if statements could be combined 148154
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 179
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 180

fr/paris/lutece/plugins/notificationstore/business/DemandCategoryDAO.java

Rule Violation Line
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 201204

fr/paris/lutece/plugins/notificationstore/business/DemandCategoryHome.java

Rule Violation Line
EmptyStatementNotInLoop An empty statement (semicolon) not part of a loop 154

fr/paris/lutece/plugins/notificationstore/business/DemandDAO.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 66753
AvoidDuplicateLiterals The String literal "SELECT " appears 6 times in this file; the first occurrence is on line 85 85
ControlStatementBraces This statement should have braces 195
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 314
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 315
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 318
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 344
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 347
ConfusingTernary Avoid if (x != y) ..; else ..; 494
ConfusingTernary Avoid if (x != y) ..; else ..; 495
ConfusingTernary Avoid if (x != y) ..; else ..; 498
ShortVariable Avoid variables with short names like i 592
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 626627
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 634
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 639
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 646
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 650
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 655
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 692
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 699
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 700
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 706
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 709

fr/paris/lutece/plugins/notificationstore/business/DemandHome.java

Rule Violation Line
UnusedPrivateField Avoid unused private fields such as '_plugin'. 54
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 138139

fr/paris/lutece/plugins/notificationstore/business/DemandTypeDAO.java

Rule Violation Line
CommentRequired Public method and constructor comments are required 6579
AvoidDuplicateLiterals The String literal "String" appears 4 times in this file; the first occurrence is on line 75 75
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 253256

fr/paris/lutece/plugins/notificationstore/business/DemandTypeHome.java

Rule Violation Line
CommentRequired Public method and constructor comments are required 185188

fr/paris/lutece/plugins/notificationstore/business/NotificationContentDAO.java

Rule Violation Line
ConfusingTernary Avoid if (x != y) ..; else ..; 74
ConfusingTernary Avoid if (x != y) ..; else ..; 75
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 189

fr/paris/lutece/plugins/notificationstore/business/NotificationDAO.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 34707
TooManyMethods This class has too many methods, consider refactoring it. 78707
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the _mapper field if you want a default access modifier 116
DefaultPackage Use explicit scoping instead of the default package private level 116
CyclomaticComplexity The method 'getFilterCriteriaClauses(String, NotificationFilter)' has a cyclomatic complexity of 14. 194287
NPathComplexity The method 'getFilterCriteriaClauses(String, NotificationFilter)' has an NPath complexity of 4160 194287
AvoidSynchronizedAtMethodLevel Use block level rather than method level synchronization 330359
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 348
ShortVariable Avoid variables with short names like id 383
ShortVariable Avoid variables with short names like id 413
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 422
ConfusingTernary Avoid if (x != y) ..; else ..; 500
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 615
ConfusingTernary Avoid if (x != y) ..; else ..; 643
ConfusingTernary Avoid if (x != y) ..; else ..; 675
SimplifyBooleanReturns Avoid unnecessary if..then..else statements when returning booleans 697704

fr/paris/lutece/plugins/notificationstore/business/NotificationEventDAO.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 59448
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 89
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 104
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 129
ConfusingTernary Avoid if (x != y) ..; else ..; 145155
ConfusingTernary Avoid if (x != y) ..; else ..; 310
ConfusingTernary Avoid if (x != y) ..; else ..; 331
LinguisticNaming Linguistics Antipattern - The getter 'getFilterCriteriaClauses' should not return void linguistically 342386
CyclomaticComplexity The method 'addFilterCriteriaValues(DAOUtil, NotificationFilter)' has a cyclomatic complexity of 11. 394432
NPathComplexity The method 'addFilterCriteriaValues(DAOUtil, NotificationFilter)' has an NPath complexity of 384 394432
ShortVariable Avoid variables with short names like i 397
MissingOverride The method 'deleteBeforeDate(long)' is missing an @Override annotation. 437447

fr/paris/lutece/plugins/notificationstore/business/NotificationHome.java

Rule Violation Line
ShortVariable Avoid variables with short names like id 91

fr/paris/lutece/plugins/notificationstore/business/TemporaryStatusDAO.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 53278
ConfusingTernary Avoid if (x != y) ..; else ..; 77
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 192195

fr/paris/lutece/plugins/notificationstore/business/TemporaryStatusHome.java

Rule Violation Line
CommentRequired Public method and constructor comments are required 166169

fr/paris/lutece/plugins/notificationstore/service/CustomerProvider.java

Rule Violation Line
RedundantFieldInitializer Avoid using redundant field initializer for 'bIsInitialized' 86
ImmutableField Private field '_requestAuthor' could be made final; it is only initialized in the declaration or constructor. 90

fr/paris/lutece/plugins/notificationstore/service/DemandService.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 71467
UnusedPrivateField Avoid unused private fields such as '_statusDao'. 76
MissingOverride The method 'findByCustomerId(String)' is missing an @Override annotation. 120132
MissingOverride The method 'findByReference(String)' is missing an @Override annotation. 141153
MissingOverride The method 'findByPrimaryKey(String, String, String)' is missing an @Override annotation. 164175
MissingOverride The method 'create(Demand)' is missing an @Override annotation. 184192
MissingOverride The method 'create(Notification)' is missing an @Override annotation. 201212
MissingOverride The method 'create(NotificationEvent)' is missing an @Override annotation. 220225
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'notificationDao' 224
MissingOverride The method 'update(Demand)' is missing an @Override annotation. 234242
MissingOverride The method 'updateDemandsStatusId(int, int)' is missing an @Override annotation. 252255
MissingOverride The method 'remove(String, String, String)' is missing an @Override annotation. 265277
MissingOverride The method 'findEventsByDateAndDemandTypeIdAndStatus(long, long, String, String)' is missing an @Override annotation. 289299
MissingOverride The method 'getDemandTypesList()' is missing an @Override annotation. 330343
MissingOverride The method 'getDemandType(String)' is missing an @Override annotation. 350367
ShortVariable Avoid variables with short names like dt 352
ConfusingTernary Avoid if (x != y) ..; else ..; 354366
MissingOverride The method 'getIdsByCustomerIdAndDemandTypeId(String, String, String)' is missing an @Override annotation. 375378
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 450

fr/paris/lutece/plugins/notificationstore/service/DemandTypeService.java

Rule Violation Line
CommentRequired Header comments are required 4154

fr/paris/lutece/plugins/notificationstore/service/JsonGeneration.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. 62160
CommentRequired Public method and constructor comments are required 69103
ShortVariable Avoid variables with short names like i 83
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 94

fr/paris/lutece/plugins/notificationstore/service/NotificationService.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 34757
GodClass Possible God Class (WMC=90, ATFD=102, TCC=12.418%) 74757
CommentRequired Header comments are required 74757
CyclomaticComplexity The class 'NotificationService' has a total cyclomatic complexity of 90 (highest 15). 74757
TooManyMethods This class has too many methods, consider refactoring it. 75757
UnusedPrivateField Avoid unused private fields such as 'STATUS_SUCCESS'. 88
UnusedPrivateField Avoid unused private fields such as 'MESSAGE_MISSING_USER_ID'. 102
NonThreadSafeSingleton Singleton is not thread safe 129137
CyclomaticComplexity The method 'newNotification(String)' has a cyclomatic complexity of 10. 147210
AvoidCatchingNPE Avoid catching NullPointerException; consider removing the cause of the NPE. 184
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 184
IdenticalCatchBranches 'catch' branch identical to 'JsonParseException' branch 184187
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 192195
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 196199
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 196
CyclomaticComplexity The method 'processCustomer(Notification, List)' has a cyclomatic complexity of 15. 249318
NPathComplexity The method 'processCustomer(Notification, List)' has an NPath complexity of 230 249318
ConfusingTernary Avoid if (x != y) ..; else ..; 284296
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 298
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 300
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 345
IdenticalCatchBranches 'catch' branch identical to 'JsonParseException' branch 364367
AvoidCatchingNPE Avoid catching NullPointerException; consider removing the cause of the NPE. 364
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 364
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 372
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 372375
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 399
AvoidCatchingNPE Avoid catching NullPointerException; consider removing the cause of the NPE. 399
IdenticalCatchBranches 'catch' branch identical to 'JsonParseException' branch 399402
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 407
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 407410
CyclomaticComplexity The method 'store(Notification)' has a cyclomatic complexity of 13. 442503
ConfusingTernary Avoid if (x != y) ..; else ..; 523530
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 587
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 594
ShortMethodName Avoid using short method names 616
ShortVariable Avoid variables with short names like ex 630
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 640
InsufficientStringBufferDeclaration StringBuffer constructor is initialized with size 16, but has at least 170 characters appended. 656
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 657
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 3 consecutive times with literals. Use a single append with a single combined String. 657
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 658
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 658
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 659
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 659
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 659
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 660
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 660
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 660
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 661
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 661
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 661
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 662
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 666
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 666
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 667
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 673
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 673
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 674
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 674
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 675
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 675
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 676
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 676
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'notification' 739

fr/paris/lutece/plugins/notificationstore/service/NotificationStorePlugin.java

Rule Violation Line
UncommentedEmptyMethodBody Document empty method body 5455

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusCacheService.java

Rule Violation Line
CallSuperInConstructor It is a good practice to call super() in a constructor 5760
NonThreadSafeSingleton Singleton is not thread safe 6972

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusService.java

Rule Violation Line
NonThreadSafeSingleton Singleton is not thread safe 7984
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 138
UseLocaleWithCaseConversions When doing a String.toLowerCase()/toUpperCase() call, use a Locale 197
UseLocaleWithCaseConversions When doing a String.toLowerCase()/toUpperCase() call, use a Locale 203

fr/paris/lutece/plugins/notificationstore/utils/NotificationStoreConstants.java

Rule Violation Line
CommentRequired Header comments are required 36110
ShortVariable Avoid variables with short names like ID 55

fr/paris/lutece/plugins/notificationstore/utils/NotificationStoreUtils.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. 57107

fr/paris/lutece/plugins/notificationstore/web/AbstractJspBean.java

Rule Violation Line
CommentRequired Header comments are required 51247
LooseCoupling Avoid using implementation types like 'HashMap'; use the interface instead 82
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 132
DefaultPackage Use explicit scoping instead of the default package private level 132
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getPluginDefaultNumberOfItemPerPage method if you want a default access modifier 134137
DefaultPackage Use explicit scoping instead of the default package private level 134137
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 144
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 157
CompareObjectsWithEquals Use equals() to compare object references. 192
LooseCoupling Avoid using implementation types like 'HashMap'; use the interface instead 245

fr/paris/lutece/plugins/notificationstore/web/AbstractManageDemandJspBean.java

Rule Violation Line
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 116
DefaultPackage Use explicit scoping instead of the default package private level 116

fr/paris/lutece/plugins/notificationstore/web/AbstractManageDemandTypeJspBean.java

Rule Violation Line
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 120
DefaultPackage Use explicit scoping instead of the default package private level 120

fr/paris/lutece/plugins/notificationstore/web/AbstractManageJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 49116
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 115
DefaultPackage Use explicit scoping instead of the default package private level 115

fr/paris/lutece/plugins/notificationstore/web/DemandCategoryJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 62301
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 122
DefaultPackage Use explicit scoping instead of the default package private level 140147
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 141147
ConfusingTernary Avoid if (x != y) ..; else ..; 167

fr/paris/lutece/plugins/notificationstore/web/DemandJspBean.java

Rule Violation Line
CommentRequired Header comments are required 58197
NPathComplexity The method 'getManageDemand(HttpServletRequest)' has an NPath complexity of 27776 104184
CyclomaticComplexity The method 'getManageDemand(HttpServletRequest)' has a cyclomatic complexity of 21. 104184
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 135138
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 145148
DefaultPackage Use explicit scoping instead of the default package private level 186196
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 187196

fr/paris/lutece/plugins/notificationstore/web/DemandTypeJspBean.java

Rule Violation Line
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 125
DefaultPackage Use explicit scoping instead of the default package private level 138145
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 139145
ConfusingTernary Avoid if (x != y) ..; else ..; 166

fr/paris/lutece/plugins/notificationstore/web/NotificationEventJspBean.java

Rule Violation Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 58207
CommentRequired Header comments are required 58207
NPathComplexity The method 'getManageNotificationEvent(HttpServletRequest)' has an NPath complexity of 46144 100197
CyclomaticComplexity The method 'getManageNotificationEvent(HttpServletRequest)' has a cyclomatic complexity of 25. 100197
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 134137
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 144147
DefaultPackage Use explicit scoping instead of the default package private level 199206
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 200206

fr/paris/lutece/plugins/notificationstore/web/NotificationJspBean.java

Rule Violation Line
CommentRequired Header comments are required 59228
CyclomaticComplexity The method 'getManageNotification(HttpServletRequest)' has a cyclomatic complexity of 22. 103190
NPathComplexity The method 'getManageNotification(HttpServletRequest)' has an NPath complexity of 18496 103190
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 137140
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 147150
UnnecessaryAnnotationValueElement Avoid the use of value in annotations when its the only element 200
DefaultPackage Use explicit scoping instead of the default package private level 218226
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 219226

fr/paris/lutece/plugins/notificationstore/web/StatusJspBean.java

Rule Violation Line
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 130
DefaultPackage Use explicit scoping instead of the default package private level 143150
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 144150
ConfusingTernary Avoid if (x != y) ..; else ..; 162

fr/paris/lutece/plugins/notificationstore/web/rs/DemandCategoryRestService.java

Rule Violation Line
ShortVariable Avoid variables with short names like id 153
ConfusingTernary Avoid if (x != y) ..; else ..; 167184
ShortVariable Avoid variables with short names like id 199
ShortVariable Avoid variables with short names like id 230

fr/paris/lutece/plugins/notificationstore/web/rs/DemandRestService.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 34305
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 111117
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 119
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 160167
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 169
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 182
CommentRequired Public method and constructor comments are required 216232
ConfusingTernary Avoid if (x != y) ..; else ..; 246260

fr/paris/lutece/plugins/notificationstore/web/rs/DemandTypeRestService.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 34301
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 147151
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 194199
ConfusingTernary Avoid if (x != y) ..; else ..; 209228

fr/paris/lutece/plugins/notificationstore/web/rs/NotificationRestService.java

Rule Violation Line
CommentRequired Header comments are required 70176
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 118122

fr/paris/lutece/plugins/notificationstore/web/rs/swagger/SwaggerConfig.java

Rule Violation Line
CommentRequired Header comments are required 4749

fr/paris/lutece/plugins/notificationstore/web/rs/swagger/SwaggerConstants.java

Rule Violation Line
ShortVariable Avoid variables with short names like ID 47

Priority 4

fr/paris/lutece/plugins/notificationstore/business/DemandDAO.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'com.fasterxml.jackson.databind.JsonMappingException' 59

fr/paris/lutece/plugins/notificationstore/business/DemandHome.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.plugin.PluginService' 41

fr/paris/lutece/plugins/notificationstore/business/NotificationContentHome.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.plugin.Plugin' 49

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusService.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.plugin.Plugin' 45

fr/paris/lutece/plugins/notificationstore/utils/NotificationStoreUtils.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.plugins.grubusiness.business.demand.TemporaryStatus' 45

Files

fr/paris/lutece/plugins/notificationstore/business/AbstractFilterDao.java

Rule Violation Priority Line
AbstractClassWithoutAbstractMethod This abstract class does not have any abstract methods 3 50331
CommentRequired Header comments are required 3 50331
LooseCoupling Avoid using implementation types like 'HashMap'; use the interface instead 3 54
FieldNamingConventions The constant name '_listPrefixToRemove' doesn't match '[A-Z][A-Z_0-9]*' 1 74
FieldNamingConventions The constant name '_listTypeAllowedForSearch' doesn't match '[A-Z][A-Z_0-9]*' 1 75
FieldNamingConventions The final field name '_clazz' doesn't match '[a-z][a-zA-Z0-9]*' 1 77
CommentRequired Protected method constructor comments are required 3 8195
ConstructorCallsOverridableMethod Overridable method 'initMapSql' called during object construction 1 94
FormalParameterNamingConventions The method parameter name 'SQL_QUERY_SELECTALL_ID' doesn't match '[a-z][a-zA-Z0-9]*' 1 109
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 114
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 115
LocalVariableNamingConventions The local variable name 'WhereClauses' doesn't match '[a-z][a-zA-Z0-9]*' 1 133
CollapsibleIfStatements These nested if statements could be combined 3 148154
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 179
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 180

fr/paris/lutece/plugins/notificationstore/business/DemandCategoryDAO.java

Rule Violation Priority Line
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 3 201204

fr/paris/lutece/plugins/notificationstore/business/DemandCategoryHome.java

Rule Violation Priority Line
EmptyStatementNotInLoop An empty statement (semicolon) not part of a loop 3 154

fr/paris/lutece/plugins/notificationstore/business/DemandDAO.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'com.fasterxml.jackson.databind.JsonMappingException' 4 59
TooManyMethods This class has too many methods, consider refactoring it. 3 66753
AvoidDuplicateLiterals The String literal "SELECT " appears 6 times in this file; the first occurrence is on line 85 3 85
FieldNamingConventions The static field name 'hashMapTypeRef' doesn't match '_[a-z][a-zA-Z0-9]*' 1 136
ControlStatementBraces This statement should have braces 3 195
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 314
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 315
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 318
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 344
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 347
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 2 445
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 2 466
ConfusingTernary Avoid if (x != y) ..; else ..; 3 494
ConfusingTernary Avoid if (x != y) ..; else ..; 3 495
ConfusingTernary Avoid if (x != y) ..; else ..; 3 498
ShortVariable Avoid variables with short names like i 3 592
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 626627
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 634
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 639
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 646
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 650
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 655
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 692
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 699
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 700
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 706
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 709

fr/paris/lutece/plugins/notificationstore/business/DemandHome.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.plugin.PluginService' 4 41
UnusedPrivateField Avoid unused private fields such as '_plugin'. 3 54
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 138139

fr/paris/lutece/plugins/notificationstore/business/DemandTypeDAO.java

Rule Violation Priority Line
CommentRequired Public method and constructor comments are required 3 6579
AvoidDuplicateLiterals The String literal "String" appears 4 times in this file; the first occurrence is on line 75 3 75
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 3 253256

fr/paris/lutece/plugins/notificationstore/business/DemandTypeHome.java

Rule Violation Priority Line
FormalParameterNamingConventions The method parameter name 'type_id' doesn't match '[a-z][a-zA-Z0-9]*' 1 119
CommentRequired Public method and constructor comments are required 3 185188

fr/paris/lutece/plugins/notificationstore/business/NotificationContentDAO.java

Rule Violation Priority Line
ConfusingTernary Avoid if (x != y) ..; else ..; 3 74
ConfusingTernary Avoid if (x != y) ..; else ..; 3 75
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 189

fr/paris/lutece/plugins/notificationstore/business/NotificationContentHome.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.plugin.Plugin' 4 49
AvoidReassigningParameters Avoid reassigning parameters such as 'strNotificationContent' 2 326

fr/paris/lutece/plugins/notificationstore/business/NotificationDAO.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 34707
TooManyMethods This class has too many methods, consider refactoring it. 3 78707
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the _mapper field if you want a default access modifier 3 116
DefaultPackage Use explicit scoping instead of the default package private level 3 116
CyclomaticComplexity The method 'getFilterCriteriaClauses(String, NotificationFilter)' has a cyclomatic complexity of 14. 3 194287
NPathComplexity The method 'getFilterCriteriaClauses(String, NotificationFilter)' has an NPath complexity of 4160 3 194287
AvoidSynchronizedAtMethodLevel Use block level rather than method level synchronization 3 330359
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 348
ShortVariable Avoid variables with short names like id 3 383
ShortVariable Avoid variables with short names like id 3 413
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 3 422
ConfusingTernary Avoid if (x != y) ..; else ..; 3 500
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 615
ConfusingTernary Avoid if (x != y) ..; else ..; 3 643
ConfusingTernary Avoid if (x != y) ..; else ..; 3 675
SimplifyBooleanReturns Avoid unnecessary if..then..else statements when returning booleans 3 697704

fr/paris/lutece/plugins/notificationstore/business/NotificationEventDAO.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 59448
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 89
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 104
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 3 129
ConfusingTernary Avoid if (x != y) ..; else ..; 3 145155
ConfusingTernary Avoid if (x != y) ..; else ..; 3 310
ConfusingTernary Avoid if (x != y) ..; else ..; 3 331
LinguisticNaming Linguistics Antipattern - The getter 'getFilterCriteriaClauses' should not return void linguistically 3 342386
CyclomaticComplexity The method 'addFilterCriteriaValues(DAOUtil, NotificationFilter)' has a cyclomatic complexity of 11. 3 394432
NPathComplexity The method 'addFilterCriteriaValues(DAOUtil, NotificationFilter)' has an NPath complexity of 384 3 394432
ShortVariable Avoid variables with short names like i 3 397
MissingOverride The method 'deleteBeforeDate(long)' is missing an @Override annotation. 3 437447

fr/paris/lutece/plugins/notificationstore/business/NotificationHome.java

Rule Violation Priority Line
ShortVariable Avoid variables with short names like id 3 91

fr/paris/lutece/plugins/notificationstore/business/TemporaryStatusDAO.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 53278
FieldNamingConventions The constant name '_plugin' doesn't match '[A-Z][A-Z_0-9]*' 1 65
ConfusingTernary Avoid if (x != y) ..; else ..; 3 77
ForLoopCanBeForeach This for loop can be replaced by a foreach loop 3 192195

fr/paris/lutece/plugins/notificationstore/business/TemporaryStatusHome.java

Rule Violation Priority Line
CommentRequired Public method and constructor comments are required 3 166169

fr/paris/lutece/plugins/notificationstore/service/CustomerProvider.java

Rule Violation Priority Line
RedundantFieldInitializer Avoid using redundant field initializer for 'bIsInitialized' 3 86
FieldNamingConventions The static field name 'bIsInitialized' doesn't match '_[a-z][a-zA-Z0-9]*' 1 86
ImmutableField Private field '_requestAuthor' could be made final; it is only initialized in the declaration or constructor. 3 90
AvoidBranchingStatementAsLastInLoop Avoid using a branching statement as the last in a loop. 2 232

fr/paris/lutece/plugins/notificationstore/service/DemandService.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 71467
UnusedPrivateField Avoid unused private fields such as '_statusDao'. 3 76
FormalParameterNamingConventions The method parameter name '_demandDao' doesn't match '[a-z][a-zA-Z0-9]*' 1 101
FormalParameterNamingConventions The method parameter name '_notificationEventDao' doesn't match '[a-z][a-zA-Z0-9]*' 1 101
FormalParameterNamingConventions The method parameter name '_notificationDao' doesn't match '[a-z][a-zA-Z0-9]*' 1 101
FormalParameterNamingConventions The method parameter name '_statusDao' doesn't match '[a-z][a-zA-Z0-9]*' 1 102
MissingOverride The method 'findByCustomerId(String)' is missing an @Override annotation. 3 120132
MissingOverride The method 'findByReference(String)' is missing an @Override annotation. 3 141153
MissingOverride The method 'findByPrimaryKey(String, String, String)' is missing an @Override annotation. 3 164175
MissingOverride The method 'create(Demand)' is missing an @Override annotation. 3 184192
MissingOverride The method 'create(Notification)' is missing an @Override annotation. 3 201212
MissingOverride The method 'create(NotificationEvent)' is missing an @Override annotation. 3 220225
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'notificationDao' 3 224
MissingOverride The method 'update(Demand)' is missing an @Override annotation. 3 234242
MissingOverride The method 'updateDemandsStatusId(int, int)' is missing an @Override annotation. 3 252255
MissingOverride The method 'remove(String, String, String)' is missing an @Override annotation. 3 265277
MissingOverride The method 'findEventsByDateAndDemandTypeIdAndStatus(long, long, String, String)' is missing an @Override annotation. 3 289299
MissingOverride The method 'getDemandTypesList()' is missing an @Override annotation. 3 330343
FormalParameterNamingConventions The method parameter name 'type_id' doesn't match '[a-z][a-zA-Z0-9]*' 1 350
MissingOverride The method 'getDemandType(String)' is missing an @Override annotation. 3 350367
ShortVariable Avoid variables with short names like dt 3 352
ConfusingTernary Avoid if (x != y) ..; else ..; 3 354366
MissingOverride The method 'getIdsByCustomerIdAndDemandTypeId(String, String, String)' is missing an @Override annotation. 3 375378
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 450

fr/paris/lutece/plugins/notificationstore/service/DemandTypeService.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 4154

fr/paris/lutece/plugins/notificationstore/service/JsonGeneration.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 62160
CommentRequired Public method and constructor comments are required 3 69103
SystemPrintln System.out.println is used 2 80
ShortVariable Avoid variables with short names like i 3 83
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 94
SystemPrintln System.out.println is used 2 100
SystemPrintln System.out.println is used 2 157

fr/paris/lutece/plugins/notificationstore/service/NotificationService.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 34757
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 1 74757
GodClass Possible God Class (WMC=90, ATFD=102, TCC=12.418%) 3 74757
CommentRequired Header comments are required 3 74757
CyclomaticComplexity The class 'NotificationService' has a total cyclomatic complexity of 90 (highest 15). 3 74757
TooManyMethods This class has too many methods, consider refactoring it. 3 75757
UnusedPrivateField Avoid unused private fields such as 'STATUS_SUCCESS'. 3 88
UnusedPrivateField Avoid unused private fields such as 'MESSAGE_MISSING_USER_ID'. 3 102
NonThreadSafeSingleton Singleton is not thread safe 3 129137
CyclomaticComplexity The method 'newNotification(String)' has a cyclomatic complexity of 10. 3 147210
AvoidCatchingNPE Avoid catching NullPointerException; consider removing the cause of the NPE. 3 184
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 184
IdenticalCatchBranches 'catch' branch identical to 'JsonParseException' branch 3 184187
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 3 192195
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 3 196199
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 196
CyclomaticComplexity The method 'processCustomer(Notification, List)' has a cyclomatic complexity of 15. 3 249318
NPathComplexity The method 'processCustomer(Notification, List)' has an NPath complexity of 230 3 249318
ConfusingTernary Avoid if (x != y) ..; else ..; 3 284296
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 298
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 300
GuardLogStatement Logger calls should be surrounded by log level guards. 2 334
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 345
IdenticalCatchBranches 'catch' branch identical to 'JsonParseException' branch 3 364367
AvoidCatchingNPE Avoid catching NullPointerException; consider removing the cause of the NPE. 3 364
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 364
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 372
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 3 372375
GuardLogStatement Logger calls should be surrounded by log level guards. 2 390
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 399
AvoidCatchingNPE Avoid catching NullPointerException; consider removing the cause of the NPE. 3 399
IdenticalCatchBranches 'catch' branch identical to 'JsonParseException' branch 3 399402
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 407
IdenticalCatchBranches 'catch' branch identical to 'IOException' branch 3 407410
CyclomaticComplexity The method 'store(Notification)' has a cyclomatic complexity of 13. 3 442503
ConfusingTernary Avoid if (x != y) ..; else ..; 3 523530
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 587
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 594
ShortMethodName Avoid using short method names 3 616
ShortVariable Avoid variables with short names like ex 3 630
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 640
InsufficientStringBufferDeclaration StringBuffer constructor is initialized with size 16, but has at least 170 characters appended. 3 656
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 657
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 3 consecutive times with literals. Use a single append with a single combined String. 3 657
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 658
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 658
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 659
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 659
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 659
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 660
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 660
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 660
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 661
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 661
ConsecutiveAppendsShouldReuse StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. 3 661
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 662
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 666
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 666
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 667
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 673
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 673
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 674
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 674
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 675
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 675
ConsecutiveLiteralAppends StringBuffer (or StringBuilder).append is called 2 consecutive times with literals. Use a single append with a single combined String. 3 676
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 676
GuardLogStatement Logger calls should be surrounded by log level guards. 2 730
UnnecessaryLocalBeforeReturn Consider simply returning the value vs storing it in local variable 'notification' 3 739

fr/paris/lutece/plugins/notificationstore/service/NotificationStorePlugin.java

Rule Violation Priority Line
UncommentedEmptyMethodBody Document empty method body 3 5455

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusCacheService.java

Rule Violation Priority Line
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 1 47108
CallSuperInConstructor It is a good practice to call super() in a constructor 3 5760
NonThreadSafeSingleton Singleton is not thread safe 3 6972

fr/paris/lutece/plugins/notificationstore/service/TemporaryStatusService.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.plugin.Plugin' 4 45
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 1 55259
NonThreadSafeSingleton Singleton is not thread safe 3 7984
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 138
AvoidReassigningParameters Avoid reassigning parameters such as 'strStatus' 2 193
UseLocaleWithCaseConversions When doing a String.toLowerCase()/toUpperCase() call, use a Locale 3 197
UseLocaleWithCaseConversions When doing a String.toLowerCase()/toUpperCase() call, use a Locale 3 203

fr/paris/lutece/plugins/notificationstore/utils/NotificationStoreConstants.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 36110
ClassNamingConventions The utility class name 'NotificationStoreConstants' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' 1 36110
ShortVariable Avoid variables with short names like ID 3 55

fr/paris/lutece/plugins/notificationstore/utils/NotificationStoreUtils.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'fr.paris.lutece.plugins.grubusiness.business.demand.TemporaryStatus' 4 45
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 57107

fr/paris/lutece/plugins/notificationstore/web/AbstractJspBean.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 51247
LooseCoupling Avoid using implementation types like 'HashMap'; use the interface instead 3 82
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 132
DefaultPackage Use explicit scoping instead of the default package private level 3 132
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getPluginDefaultNumberOfItemPerPage method if you want a default access modifier 3 134137
DefaultPackage Use explicit scoping instead of the default package private level 3 134137
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 144
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 157
CompareObjectsWithEquals Use equals() to compare object references. 3 192
LocalVariableNamingConventions The local variable name '_model' doesn't match '[a-z][a-zA-Z0-9]*' 1 224
FormalParameterNamingConventions The method parameter name '_mapFilterCriteria' doesn't match '[a-z][a-zA-Z0-9]*' 1 245
LooseCoupling Avoid using implementation types like 'HashMap'; use the interface instead 3 245

fr/paris/lutece/plugins/notificationstore/web/AbstractManageDemandJspBean.java

Rule Violation Priority Line
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 116
DefaultPackage Use explicit scoping instead of the default package private level 3 116

fr/paris/lutece/plugins/notificationstore/web/AbstractManageDemandTypeJspBean.java

Rule Violation Priority Line
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 120
DefaultPackage Use explicit scoping instead of the default package private level 3 120

fr/paris/lutece/plugins/notificationstore/web/AbstractManageJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 49116
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 115
DefaultPackage Use explicit scoping instead of the default package private level 3 115

fr/paris/lutece/plugins/notificationstore/web/DemandCategoryJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 62301
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 122
DefaultPackage Use explicit scoping instead of the default package private level 3 140147
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 141147
ConfusingTernary Avoid if (x != y) ..; else ..; 3 167

fr/paris/lutece/plugins/notificationstore/web/DemandJspBean.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 58197
NPathComplexity The method 'getManageDemand(HttpServletRequest)' has an NPath complexity of 27776 3 104184
CyclomaticComplexity The method 'getManageDemand(HttpServletRequest)' has a cyclomatic complexity of 21. 3 104184
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 135138
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 145148
DefaultPackage Use explicit scoping instead of the default package private level 3 186196
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 187196

fr/paris/lutece/plugins/notificationstore/web/DemandTypeJspBean.java

Rule Violation Priority Line
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 125
DefaultPackage Use explicit scoping instead of the default package private level 3 138145
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 139145
FormalParameterNamingConventions The method parameter name '_mapFilterCriteria' doesn't match '[a-z][a-zA-Z0-9]*' 1 151
ConfusingTernary Avoid if (x != y) ..; else ..; 3 166

fr/paris/lutece/plugins/notificationstore/web/NotificationEventJspBean.java

Rule Violation Priority Line
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 58207
CommentRequired Header comments are required 3 58207
NPathComplexity The method 'getManageNotificationEvent(HttpServletRequest)' has an NPath complexity of 46144 3 100197
CyclomaticComplexity The method 'getManageNotificationEvent(HttpServletRequest)' has a cyclomatic complexity of 25. 3 100197
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 134137
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 144147
DefaultPackage Use explicit scoping instead of the default package private level 3 199206
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 200206

fr/paris/lutece/plugins/notificationstore/web/NotificationJspBean.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 59228
CyclomaticComplexity The method 'getManageNotification(HttpServletRequest)' has a cyclomatic complexity of 22. 3 103190
NPathComplexity The method 'getManageNotification(HttpServletRequest)' has an NPath complexity of 18496 3 103190
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 137140
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 147150
UnnecessaryAnnotationValueElement Avoid the use of value in annotations when its the only element 3 200
DefaultPackage Use explicit scoping instead of the default package private level 3 218226
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 219226

fr/paris/lutece/plugins/notificationstore/web/StatusJspBean.java

Rule Violation Priority Line
NullAssignment Assigning an Object to null is a code smell. Consider refactoring. 3 130
DefaultPackage Use explicit scoping instead of the default package private level 3 143150
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier 3 144150
ConfusingTernary Avoid if (x != y) ..; else ..; 3 162
FormalParameterNamingConventions The method parameter name '_mapFilterCriteria' doesn't match '[a-z][a-zA-Z0-9]*' 1 321

fr/paris/lutece/plugins/notificationstore/web/rs/DemandCategoryRestService.java

Rule Violation Priority Line
ShortVariable Avoid variables with short names like id 3 153
ConfusingTernary Avoid if (x != y) ..; else ..; 3 167184
ShortVariable Avoid variables with short names like id 3 199
ShortVariable Avoid variables with short names like id 3 230

fr/paris/lutece/plugins/notificationstore/web/rs/DemandRestService.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 34305
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 111117
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 119
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 160167
PrematureDeclaration Avoid declaring a variable if it is unreferenced before a possible exit point. 3 169
InefficientStringBuffering Avoid concatenating nonliterals in a StringBuffer/StringBuilder constructor or append(). 3 182
CommentRequired Public method and constructor comments are required 3 216232
ConfusingTernary Avoid if (x != y) ..; else ..; 3 246260

fr/paris/lutece/plugins/notificationstore/web/rs/DemandTypeRestService.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 34301
LocalVariableNamingConventions The local variable name '_mapper' doesn't match '[a-z][a-zA-Z0-9]*' 1 114
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 147151
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 194199
ConfusingTernary Avoid if (x != y) ..; else ..; 3 209228

fr/paris/lutece/plugins/notificationstore/web/rs/NotificationRestService.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 70176
UseObjectForClearerAPI Rather than using a lot of String arguments, consider using a container object for those values. 3 118122

fr/paris/lutece/plugins/notificationstore/web/rs/swagger/SwaggerConfig.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 4749

fr/paris/lutece/plugins/notificationstore/web/rs/swagger/SwaggerConstants.java

Rule Violation Priority Line
ClassNamingConventions The utility class name 'SwaggerConstants' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' 1 3977
ShortVariable Avoid variables with short names like ID 3 47