Le document suivant contient les résultats de PMD 6.13.0.
| Rule | Violation | Ligne |
|---|---|---|
| FieldNamingConventions | The final field name '_nBatchSize' doesn't match '[a-z][a-zA-Z0-9]*' | 48 |
| FieldNamingConventions | The final field name '_listIdDataObjects' doesn't match '[a-z][a-zA-Z0-9]*' | 49 |
| FieldNamingConventions | The final field name '_dataSource' doesn't match '[a-z][a-zA-Z0-9]*' | 50 |
| Rule | Violation | Ligne |
|---|---|---|
| FormalParameterNamingConventions | The method parameter name '_plugin' doesn't match '[a-z][a-zA-Z0-9]*' | 182 |
| Rule | Violation | Ligne |
|---|---|---|
| ClassWithOnlyPrivateConstructorsShouldBeFinal | A class which only has private constructors should be final | 40–68 |
| Rule | Violation | Ligne |
|---|---|---|
| AvoidReassigningParameters | Avoid reassigning parameters such as 'elastic' | 212 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 241 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 258 |
| AvoidReassigningParameters | Avoid reassigning parameters such as 'elastic' | 276 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 299 |
| Rule | Violation | Ligne |
|---|---|---|
| AvoidReassigningParameters | Avoid reassigning parameters such as 'elastic' | 420 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 443 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 448 |
| Rule | Violation | Ligne |
|---|---|---|
| ShortVariable | Avoid variables with short names like id | 97 |
| MissingOverride | The method 'setId(String)' is missing an @Override annotation. | 97–100 |
| CommentRequired | Public method and constructor comments are required | 97–100 |
| CommentRequired | Public method and constructor comments are required | 108–111 |
| CommentRequired | Public method and constructor comments are required | 119–122 |
| CommentRequired | Public method and constructor comments are required | 130–133 |
| Rule | Violation | Ligne |
|---|---|---|
| ImmutableField | Private field '_queueTmpDataObject' could be made final; it is only initialized in the declaration or constructor. | 51 |
| RedundantFieldInitializer | Avoid using redundant field initializer for '_nNextFirstId' | 52 |
| CommentRequired | Public method and constructor comments are required | 54–65 |
| ControlStatementBraces | This statement should have braces | 83 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 89–97 |
| Rule | Violation | Ligne |
|---|---|---|
| UnnecessaryModifier | Unnecessary modifiers 'public static final' on field 'PROPERTY_BULK_BATCH_SIZE': the field is declared in an interface type | 48 |
| UseUnderscoresInNumericLiterals | Number 10000 should separate every third digit with an underscore | 49 |
| UnnecessaryModifier | Unnecessary modifiers 'public static final' on field 'BATCH_SIZE': the field is declared in an interface type | 49 |
| Rule | Violation | Ligne |
|---|---|---|
| UnnecessaryModifier | Unnecessary modifier 'public' on method 'provideAttributes': the method is declared in an interface type | 49 |
| UnnecessaryModifier | Unnecessary modifier 'public' on method 'provideAttributes': the method is declared in an interface type | 58 |
| Rule | Violation | Ligne |
|---|---|---|
| TooManyMethods | This class has too many methods, consider refactoring it. | 46–183 |
| Rule | Violation | Ligne |
|---|---|---|
| TooManyMethods | This class has too many methods, consider refactoring it. | 50–416 |
| ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 380–382 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentRequired | Header comments are required | 55–401 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 85 |
| DoNotUseThreads | To be compliant to J2EE, a webapp should not use any thread. | 104 |
| ShortVariable | Avoid variables with short names like br | 216 |
| Rule | Violation | Ligne |
|---|---|---|
| TooManyMethods | This class has too many methods, consider refactoring it. | 60–500 |
| 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–500 |
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the DataSourceService constructor if you want a default access modifier | 73–75 |
| UncommentedEmptyConstructor | Document empty constructor | 73–75 |
| DoNotUseThreads | To be compliant to J2EE, a webapp should not use any thread. | 127 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 208 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 231 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 317 |
| ShortVariable | Avoid variables with short names like br | 424 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentRequired | Header comments are required | 40–68 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentRequired | Header comments are required | 38–182 |
| AvoidStringBufferField | StringBuffers can grow quite a lot, and so may become a source of memory leak (if the owning class has a long life time). | 43 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 171–179 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentRequired | Header comments are required | 39–49 |
| Rule | Violation | Ligne |
|---|---|---|
| MissingSerialVersionUID | Classes implementing Serializable should set a serialVersionUID | 50–110 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 109 |
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier | 109 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the _mapper field if you want a default access modifier | 129 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 129 |
| UnnecessaryAnnotationValueElement | Avoid the use of value in annotations when its the only element | 154 |
| UnnecessaryAnnotationValueElement | Avoid the use of value in annotations when its the only element | 235 |
| NullAssignment | Assigning an Object to null is a code smell. Consider refactoring. | 238 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 255–264 |
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier | 256–264 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 283 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ShortVariable | Avoid variables with short names like id | 3 | 97 |
| MissingOverride | The method 'setId(String)' is missing an @Override annotation. | 3 | 97–100 |
| CommentRequired | Public method and constructor comments are required | 3 | 97–100 |
| CommentRequired | Public method and constructor comments are required | 3 | 108–111 |
| CommentRequired | Public method and constructor comments are required | 3 | 119–122 |
| CommentRequired | Public method and constructor comments are required | 3 | 130–133 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| FieldNamingConventions | The final field name '_nBatchSize' doesn't match '[a-z][a-zA-Z0-9]*' | 1 | 48 |
| FieldNamingConventions | The final field name '_listIdDataObjects' doesn't match '[a-z][a-zA-Z0-9]*' | 1 | 49 |
| FieldNamingConventions | The final field name '_dataSource' doesn't match '[a-z][a-zA-Z0-9]*' | 1 | 50 |
| ImmutableField | Private field '_queueTmpDataObject' could be made final; it is only initialized in the declaration or constructor. | 3 | 51 |
| RedundantFieldInitializer | Avoid using redundant field initializer for '_nNextFirstId' | 3 | 52 |
| CommentRequired | Public method and constructor comments are required | 3 | 54–65 |
| ControlStatementBraces | This statement should have braces | 3 | 83 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 89–97 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| UnnecessaryModifier | Unnecessary modifiers 'public static final' on field 'PROPERTY_BULK_BATCH_SIZE': the field is declared in an interface type | 3 | 48 |
| UseUnderscoresInNumericLiterals | Number 10000 should separate every third digit with an underscore | 3 | 49 |
| UnnecessaryModifier | Unnecessary modifiers 'public static final' on field 'BATCH_SIZE': the field is declared in an interface type | 3 | 49 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| UnnecessaryModifier | Unnecessary modifier 'public' on method 'provideAttributes': the method is declared in an interface type | 3 | 49 |
| UnnecessaryModifier | Unnecessary modifier 'public' on method 'provideAttributes': the method is declared in an interface type | 3 | 58 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| TooManyMethods | This class has too many methods, consider refactoring it. | 3 | 46–183 |
| FormalParameterNamingConventions | The method parameter name '_plugin' doesn't match '[a-z][a-zA-Z0-9]*' | 1 | 182 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| TooManyMethods | This class has too many methods, consider refactoring it. | 3 | 50–416 |
| ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 3 | 380–382 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| CommentRequired | Header comments are required | 3 | 55–401 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 3 | 85 |
| DoNotUseThreads | To be compliant to J2EE, a webapp should not use any thread. | 3 | 104 |
| AvoidReassigningParameters | Avoid reassigning parameters such as 'elastic' | 2 | 212 |
| ShortVariable | Avoid variables with short names like br | 3 | 216 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 2 | 241 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 2 | 258 |
| AvoidReassigningParameters | Avoid reassigning parameters such as 'elastic' | 2 | 276 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 2 | 299 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| TooManyMethods | This class has too many methods, consider refactoring it. | 3 | 60–500 |
| 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–500 |
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the DataSourceService constructor if you want a default access modifier | 3 | 73–75 |
| UncommentedEmptyConstructor | Document empty constructor | 3 | 73–75 |
| DoNotUseThreads | To be compliant to J2EE, a webapp should not use any thread. | 3 | 127 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 208 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 231 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 3 | 317 |
| AvoidReassigningParameters | Avoid reassigning parameters such as 'elastic' | 2 | 420 |
| ShortVariable | Avoid variables with short names like br | 3 | 424 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 2 | 443 |
| GuardLogStatement | Logger calls should be surrounded by log level guards. | 2 | 448 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ClassWithOnlyPrivateConstructorsShouldBeFinal | A class which only has private constructors should be final | 1 | 40–68 |
| CommentRequired | Header comments are required | 3 | 40–68 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| CommentRequired | Header comments are required | 3 | 38–182 |
| AvoidStringBufferField | StringBuffers can grow quite a lot, and so may become a source of memory leak (if the owning class has a long life time). | 3 | 43 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 171–179 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| CommentRequired | Header comments are required | 3 | 39–49 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| MissingSerialVersionUID | Classes implementing Serializable should set a serialVersionUID | 3 | 50–110 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 3 | 109 |
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier | 3 | 109 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the _mapper field if you want a default access modifier | 3 | 129 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 3 | 129 |
| UnnecessaryAnnotationValueElement | Avoid the use of value in annotations when its the only element | 3 | 154 |
| UnnecessaryAnnotationValueElement | Avoid the use of value in annotations when its the only element | 3 | 235 |
| NullAssignment | Assigning an Object to null is a code smell. Consider refactoring. | 3 | 238 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 3 | 255–264 |
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the getItemsFromIds method if you want a default access modifier | 3 | 256–264 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 283 |