The following document contains the results of PMD 6.13.0.
Rule | Violation | Line |
---|---|---|
LocalVariableNamingConventions | The local variable name '_bTemplate' doesn't match '[a-z][a-zA-Z0-9]*' | 307 |
Rule | Violation | Line |
---|---|---|
TooManyMethods | This class has too many methods, consider refactoring it. | 42–161 |
Rule | Violation | Line |
---|---|---|
TooManyMethods | This class has too many methods, consider refactoring it. | 46–259 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 159 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 218 |
Rule | Violation | Line |
---|---|---|
TooManyMethods | This class has too many methods, consider refactoring it. | 52–248 |
Rule | Violation | Line |
---|---|---|
ShortVariable | Avoid variables with short names like id | 63 |
Rule | Violation | Line |
---|---|---|
ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 34–343 |
UnusedPrivateField | Avoid unused private fields such as 'MARK_FILE_ID'. | 81 |
UnusedPrivateField | Avoid unused private fields such as 'DOCUMENT_RESOURCE_SERVLET_URL'. | 83 |
ImmutableField | Private field '_newsletterService' could be made final; it is only initialized in the declaration or constructor. | 86 |
UnusedPrivateField | Avoid unused private fields such as '_newsletterService'. | 86 |
CyclomaticComplexity | The method 'generateDocumentsList(NewsletterBlog, int, Timestamp, String, AdminUser, Locale)' has a cyclomatic complexity of 15. | 145–207 |
NPathComplexity | The method 'generateDocumentsList(NewsletterBlog, int, Timestamp, String, AdminUser, Locale)' has an NPath complexity of 243 | 145–207 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 149 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 153 |
UseUnderscoresInNumericLiterals | Number 86400000 should separate every third digit with an underscore | 154 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 154 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 177 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 193 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 227 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 227 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 228 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 237 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 248 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 279 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 279 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 280 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 289 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 300 |
Rule | Violation | Line |
---|---|---|
ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 34–389 |
UnusedPrivateField | Avoid unused private fields such as 'BLOGSLIST_PORTLET'. | 79 |
UnusedPrivateField | Avoid unused private fields such as 'MARK_USE_CATEGORIES'. | 100 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 144 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 144 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 164 |
ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 238–242 |
ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 251–255 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 281 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 375–382 |
Rule | Violation | Line |
---|---|---|
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_IMG'. | 52 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_A'. | 53 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_SUBSTRING_BEGIN'. | 54 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_SUBSTRING_END'. | 55 |
UnusedPrivateField | Avoid unused private fields such as '_newsletterDocumentService'. | 57 |
Rule | Violation | Line |
---|---|---|
ShortVariable | Avoid variables with short names like i | 99 |
Rule | Violation | Line |
---|---|---|
ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 34–267 |
UnusedPrivateField | Avoid unused private fields such as '_newsletterService'. | 118 |
ImmutableField | Private field '_newsletterService' could be made final; it is only initialized in the declaration or constructor. | 118 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 136 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 142 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 145 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 148 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 148 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 207 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 209 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 210 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 211 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 211 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 211 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 213 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 220 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 222 |
Rule | Violation | Line |
---|---|---|
BooleanGetMethodName | A getX() method which returns a boolean should be named isX() | 92–95 |
Rule | Violation | Line |
---|---|---|
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.newsletter.business.NewsLetterTemplate' | 58 |
UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'java.util.GregorianCalendar' due to existing import 'java.util.GregorianCalendar' | 152 |
Rule | Violation | Line |
---|---|---|
UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'java.util.ArrayList' due to existing import 'java.util.ArrayList' | 195 |
Rule | Violation | Line |
---|---|---|
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.blog.business.Blog' | 36 |
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.blog.service.BlogService' | 37 |
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.newsletter.util.NewsLetterConstants' | 40 |
UnusedImports | Avoid unused imports such as 'org.apache.commons.lang3.StringUtils' | 42 |
UnusedImports | Avoid unused imports such as 'org.w3c.dom.NamedNodeMap' | 43 |
UnusedImports | Avoid unused imports such as 'org.w3c.dom.Node' | 44 |
UnusedImports | Avoid unused imports such as 'org.w3c.dom.NodeList' | 45 |
Rule | Violation | Line |
---|---|---|
UnusedImports | Avoid unused imports such as 'org.apache.commons.lang3.StringUtils' | 36 |
Rule | Violation | Line |
---|---|---|
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.newsletter.modules.blog.util.NewsletterBlogUtils' | 43 |
UnusedImports | Avoid unused imports such as 'java.util.ArrayList' | 64 |
Rule | Violation | Priority | Line |
---|---|---|---|
TooManyMethods | This class has too many methods, consider refactoring it. | 3 | 42–161 |
Rule | Violation | Priority | Line |
---|---|---|---|
BooleanGetMethodName | A getX() method which returns a boolean should be named isX() | 4 | 92–95 |
Rule | Violation | Priority | Line |
---|---|---|---|
TooManyMethods | This class has too many methods, consider refactoring it. | 3 | 46–259 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 159 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 218 |
Rule | Violation | Priority | Line |
---|---|---|---|
TooManyMethods | This class has too many methods, consider refactoring it. | 3 | 52–248 |
Rule | Violation | Priority | Line |
---|---|---|---|
ShortVariable | Avoid variables with short names like id | 3 | 63 |
Rule | Violation | Priority | Line |
---|---|---|---|
ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 3 | 34–343 |
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.newsletter.business.NewsLetterTemplate' | 4 | 58 |
UnusedPrivateField | Avoid unused private fields such as 'MARK_FILE_ID'. | 3 | 81 |
UnusedPrivateField | Avoid unused private fields such as 'DOCUMENT_RESOURCE_SERVLET_URL'. | 3 | 83 |
ImmutableField | Private field '_newsletterService' could be made final; it is only initialized in the declaration or constructor. | 3 | 86 |
UnusedPrivateField | Avoid unused private fields such as '_newsletterService'. | 3 | 86 |
CyclomaticComplexity | The method 'generateDocumentsList(NewsletterBlog, int, Timestamp, String, AdminUser, Locale)' has a cyclomatic complexity of 15. | 3 | 145–207 |
NPathComplexity | The method 'generateDocumentsList(NewsletterBlog, int, Timestamp, String, AdminUser, Locale)' has an NPath complexity of 243 | 3 | 145–207 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 149 |
UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'java.util.GregorianCalendar' due to existing import 'java.util.GregorianCalendar' | 4 | 152 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 153 |
UseUnderscoresInNumericLiterals | Number 86400000 should separate every third digit with an underscore | 3 | 154 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 154 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 177 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 193 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 227 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 227 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 228 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 237 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 248 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 279 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 279 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 280 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 289 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 300 |
LocalVariableNamingConventions | The local variable name '_bTemplate' doesn't match '[a-z][a-zA-Z0-9]*' | 1 | 307 |
Rule | Violation | Priority | Line |
---|---|---|---|
ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 3 | 34–389 |
UnusedPrivateField | Avoid unused private fields such as 'BLOGSLIST_PORTLET'. | 3 | 79 |
UnusedPrivateField | Avoid unused private fields such as 'MARK_USE_CATEGORIES'. | 3 | 100 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 144 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 144 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 164 |
UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'java.util.ArrayList' due to existing import 'java.util.ArrayList' | 4 | 195 |
ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 3 | 238–242 |
ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 3 | 251–255 |
UseCollectionIsEmpty | Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 3 | 281 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 375–382 |
Rule | Violation | Priority | Line |
---|---|---|---|
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.blog.business.Blog' | 4 | 36 |
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.blog.service.BlogService' | 4 | 37 |
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.newsletter.util.NewsLetterConstants' | 4 | 40 |
UnusedImports | Avoid unused imports such as 'org.apache.commons.lang3.StringUtils' | 4 | 42 |
UnusedImports | Avoid unused imports such as 'org.w3c.dom.NamedNodeMap' | 4 | 43 |
UnusedImports | Avoid unused imports such as 'org.w3c.dom.Node' | 4 | 44 |
UnusedImports | Avoid unused imports such as 'org.w3c.dom.NodeList' | 4 | 45 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_IMG'. | 3 | 52 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_A'. | 3 | 53 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_SUBSTRING_BEGIN'. | 3 | 54 |
UnusedPrivateField | Avoid unused private fields such as 'CONSTANT_SUBSTRING_END'. | 3 | 55 |
UnusedPrivateField | Avoid unused private fields such as '_newsletterDocumentService'. | 3 | 57 |
Rule | Violation | Priority | Line |
---|---|---|---|
UnusedImports | Avoid unused imports such as 'org.apache.commons.lang3.StringUtils' | 4 | 36 |
ShortVariable | Avoid variables with short names like i | 3 | 99 |
Rule | Violation | Priority | Line |
---|---|---|---|
ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 3 | 34–267 |
UnusedImports | Avoid unused imports such as 'fr.paris.lutece.plugins.newsletter.modules.blog.util.NewsletterBlogUtils' | 4 | 43 |
UnusedImports | Avoid unused imports such as 'java.util.ArrayList' | 4 | 64 |
UnusedPrivateField | Avoid unused private fields such as '_newsletterService'. | 3 | 118 |
ImmutableField | Private field '_newsletterService' could be made final; it is only initialized in the declaration or constructor. | 3 | 118 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 136 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 142 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 145 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 148 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 148 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 207 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 209 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 210 |
UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 211 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 211 |
UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 211 |
ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 213 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 220 |
PrematureDeclaration | Avoid declaring a variable if it is unreferenced before a possible exit point. | 3 | 222 |