Le document suivant contient les résultats de PMD 6.13.0.
| Rule | Violation | Ligne |
|---|---|---|
| ClassNamingConventions | The utility class name 'Constants' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' | 39–58 |
| Rule | Violation | Ligne |
|---|---|---|
| ClassNamingConventions | The utility class name 'MyLuteceSearchUserSearchEngine' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' | 63–112 |
| Rule | Violation | Ligne |
|---|---|---|
| ClassWithOnlyPrivateConstructorsShouldBeFinal | A class which only has private constructors should be final | 45–83 |
| Rule | Violation | Ligne |
|---|---|---|
| UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 132 |
| UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 154 |
| Rule | Violation | Ligne |
|---|---|---|
| UnnecessaryLocalBeforeReturn | Consider simply returning the value vs storing it in local variable 'listMyLuteceSearchUser' | 154 |
| Rule | Violation | Ligne |
|---|---|---|
| ShortVariable | Avoid variables with short names like ID | 45 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentRequired | Header comments are required | 47–92 |
| CommentRequired | Public method and constructor comments are required | 59–62 |
| NonThreadSafeSingleton | Singleton is not thread safe | 71–74 |
| UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 81 |
| Rule | Violation | Ligne |
|---|---|---|
| NonThreadSafeSingleton | Singleton is not thread safe | 74–77 |
| Rule | Violation | Ligne |
|---|---|---|
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the _pluginName field if you want a default access modifier | 79 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 79 |
| MissingOverride | The method 'indexDocuments()' is missing an @Override annotation. | 92–105 |
| MissingOverride | The method 'getDocuments(String)' is missing an @Override annotation. | 114–141 |
| AvoidCatchingGenericException | Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block | 130 |
| MissingOverride | The method 'getName()' is missing an @Override annotation. | 146–149 |
| MissingOverride | The method 'getVersion()' is missing an @Override annotation. | 154–157 |
| MissingOverride | The method 'isEnable()' is missing an @Override annotation. | 162–172 |
| MissingOverride | The method 'getDescription()' is missing an @Override annotation. | 179–182 |
| UnusedFormalParameter | Avoid unused method parameters such as 'plugin'. | 202 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 233 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 234 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 234 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 235 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 236 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 236 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 237 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 238 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 238 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 253 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 254 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 254 |
| MissingOverride | The method 'getListType()' is missing an @Override annotation. | 262–267 |
| MissingOverride | The method 'getSpecificSearchAppUrl()' is missing an @Override annotation. | 272–275 |
| Rule | Violation | Ligne |
|---|---|---|
| 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. | 64–112 |
| ShortVariable | Avoid variables with short names like ir | 78 |
| ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 91–103 |
| UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 95 |
| AvoidCatchingGenericException | Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block | 105 |
| Rule | Violation | Ligne |
|---|---|---|
| SingularField | Perhaps '_nDefaultItemsPerPage' could be replaced by a local variable. | 70 |
| Rule | Violation | Ligne |
|---|---|---|
| ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 34–522 |
| ImmutableField | Private field '_myLutecePlugin' could be made final; it is only initialized in the declaration or constructor. | 141 |
| SingularField | Perhaps '_listProviderAttribute' could be replaced by a local variable. | 143 |
| NullAssignment | Assigning an Object to null is a code smell. Consider refactoring. | 156 |
| NullAssignment | Assigning an Object to null is a code smell. Consider refactoring. | 157 |
| UseIndexOfChar | String.indexOf(char) is faster than String.indexOf(String). | 201 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 206–213 |
| EmptyStatementNotInLoop | An empty statement (semicolon) not part of a loop | 216 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 239 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 391 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 392–393 |
| UseIndexOfChar | String.indexOf(char) is faster than String.indexOf(String). | 423 |
| EmptyStatementNotInLoop | An empty statement (semicolon) not part of a loop | 430 |
| Rule | Violation | Ligne |
|---|---|---|
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 124 |
| Rule | Violation | Ligne |
|---|---|---|
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 102 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 116 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 125 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 205 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 205 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 132 |
| UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 154 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| UnnecessaryLocalBeforeReturn | Consider simply returning the value vs storing it in local variable 'listMyLuteceSearchUser' | 3 | 154 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ClassNamingConventions | The utility class name 'Constants' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' | 1 | 39–58 |
| ShortVariable | Avoid variables with short names like ID | 3 | 45 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| CommentRequired | Header comments are required | 3 | 47–92 |
| CommentRequired | Public method and constructor comments are required | 3 | 59–62 |
| NonThreadSafeSingleton | Singleton is not thread safe | 3 | 71–74 |
| UseDiamondOperator | Explicit type arguments can be replaced by Diamond Operator | 3 | 81 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| NonThreadSafeSingleton | Singleton is not thread safe | 3 | 74–77 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| CommentDefaultAccessModifier | To avoid mistakes add a comment at the beginning of the _pluginName field if you want a default access modifier | 3 | 79 |
| DefaultPackage | Use explicit scoping instead of the default package private level | 3 | 79 |
| MissingOverride | The method 'indexDocuments()' is missing an @Override annotation. | 3 | 92–105 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 4 | 102 |
| MissingOverride | The method 'getDocuments(String)' is missing an @Override annotation. | 3 | 114–141 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 4 | 116 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 4 | 125 |
| AvoidCatchingGenericException | Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block | 3 | 130 |
| MissingOverride | The method 'getName()' is missing an @Override annotation. | 3 | 146–149 |
| MissingOverride | The method 'getVersion()' is missing an @Override annotation. | 3 | 154–157 |
| MissingOverride | The method 'isEnable()' is missing an @Override annotation. | 3 | 162–172 |
| MissingOverride | The method 'getDescription()' is missing an @Override annotation. | 3 | 179–182 |
| UnusedFormalParameter | Avoid unused method parameters such as 'plugin'. | 3 | 202 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 4 | 205 |
| UnnecessaryFullyQualifiedName | Unnecessary use of fully qualified name 'org.apache.lucene.document.Document' due to existing import 'org.apache.lucene.document.Document' | 4 | 205 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 233 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 3 | 234 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 234 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 235 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 236 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 3 | 236 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 237 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 238 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 3 | 238 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 253 |
| AppendCharacterWithChar | Avoid appending characters as strings in StringBuffer.append. | 3 | 254 |
| ConsecutiveAppendsShouldReuse | StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 3 | 254 |
| MissingOverride | The method 'getListType()' is missing an @Override annotation. | 3 | 262–267 |
| MissingOverride | The method 'getSpecificSearchAppUrl()' is missing an @Override annotation. | 3 | 272–275 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ClassNamingConventions | The utility class name 'MyLuteceSearchUserSearchEngine' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' | 1 | 63–112 |
| 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 | 64–112 |
| ShortVariable | Avoid variables with short names like ir | 3 | 78 |
| ForLoopCanBeForeach | This for loop can be replaced by a foreach loop | 3 | 91–103 |
| UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 95 |
| AvoidCatchingGenericException | Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block | 3 | 105 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ClassWithOnlyPrivateConstructorsShouldBeFinal | A class which only has private constructors should be final | 1 | 45–83 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| SingularField | Perhaps '_nDefaultItemsPerPage' could be replaced by a local variable. | 3 | 70 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ExcessiveImports | A high number of imports can indicate a high degree of coupling within an object. | 3 | 34–522 |
| ImmutableField | Private field '_myLutecePlugin' could be made final; it is only initialized in the declaration or constructor. | 3 | 141 |
| SingularField | Perhaps '_listProviderAttribute' could be replaced by a local variable. | 3 | 143 |
| NullAssignment | Assigning an Object to null is a code smell. Consider refactoring. | 3 | 156 |
| NullAssignment | Assigning an Object to null is a code smell. Consider refactoring. | 3 | 157 |
| UseIndexOfChar | String.indexOf(char) is faster than String.indexOf(String). | 3 | 201 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 206–213 |
| EmptyStatementNotInLoop | An empty statement (semicolon) not part of a loop | 3 | 216 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 239 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 391 |
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 392–393 |
| UseIndexOfChar | String.indexOf(char) is faster than String.indexOf(String). | 3 | 423 |
| EmptyStatementNotInLoop | An empty statement (semicolon) not part of a loop | 3 | 430 |
| Rule | Violation | Priority | Ligne |
|---|---|---|---|
| ConfusingTernary | Avoid if (x != y) ..; else ..; | 3 | 124 |