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/geocode/v1/web/rs/service/GeoCodeTransportRest.java

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

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpAccessTransport.java

Rule Violation Line
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 150
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 154

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpApiManagerAccessTransport.java

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

fr/paris/lutece/plugins/geocode/v1/web/rs/util/Constants.java

Rule Violation Line
ClassNamingConventions The utility class name 'Constants' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' 346
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 346

fr/paris/lutece/plugins/geocode/v1/web/service/CustomResponseStatusValidator.java

Rule Violation Line
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 3860
FieldNamingConventions The static field name 'instance' doesn't match '_[a-z][a-zA-Z0-9]*' 40

Priority 2

fr/paris/lutece/plugins/geocode/v1/web/rs/service/GeoCodeTransportMockRest.java

Rule Violation Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 59
GuardLogStatement Logger calls should be surrounded by log level guards. 67
GuardLogStatement Logger calls should be surrounded by log level guards. 90

fr/paris/lutece/plugins/geocode/v1/web/rs/service/GeoCodeTransportRest.java

Rule Violation Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 61
GuardLogStatement Logger calls should be surrounded by log level guards. 93
GuardLogStatement Logger calls should be surrounded by log level guards. 107
GuardLogStatement Logger calls should be surrounded by log level guards. 122
GuardLogStatement Logger calls should be surrounded by log level guards. 137
GuardLogStatement Logger calls should be surrounded by log level guards. 151

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpAccessTransport.java

Rule Violation Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 59

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpApiManagerAccessTransport.java

Rule Violation Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 63
GuardLogStatement Logger calls should be surrounded by log level guards. 102
GuardLogStatement Logger calls should be surrounded by log level guards. 139

Priority 3

fr/paris/lutece/plugins/geocode/v1/web/rs/dto/City.java

Rule Violation Line
CommentRequired Header comments are required 11235
UnusedPrivateField Avoid unused private fields such as '_strValueMinComplete'. 41

fr/paris/lutece/plugins/geocode/v1/web/rs/dto/Country.java

Rule Violation Line
CommentRequired Header comments are required 11102

fr/paris/lutece/plugins/geocode/v1/web/rs/service/AbstractTransportRest.java

Rule Violation Line
AbstractClassWithoutAbstractMethod This abstract class does not have any abstract methods 4489

fr/paris/lutece/plugins/geocode/v1/web/rs/service/GeoCodeTransportMockRest.java

Rule Violation Line
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 68
PositionLiteralsFirstInComparisons Position literals first in String comparisons 72
AvoidDuplicateLiterals The String literal "2000-01-01 00:00:00" appears 7 times in this file; the first occurrence is on line 78 78
AvoidDuplicateLiterals The String literal "1943-01-01 00:00:00" appears 6 times in this file; the first occurrence is on line 79 79
AvoidDuplicateLiterals The String literal "Toulon" appears 5 times in this file; the first occurrence is on line 94 94
PositionLiteralsFirstInComparisons Position literals first in String comparisons 94
NcssCount The method 'getListCitesByNameAndDateLike(String, Date)' has a NCSS line count of 72. 113207
AvoidDuplicateLiterals The String literal "2050-01-01 00:00:00" appears 5 times in this file; the first occurrence is on line 124 124
AvoidDuplicateLiterals The String literal "Villefranche" appears 6 times in this file; the first occurrence is on line 147 147
PositionLiteralsFirstInComparisons Position literals first in String comparisons 217

fr/paris/lutece/plugins/geocode/v1/web/rs/service/GeoCodeTransportRest.java

Rule Violation Line
ShortVariable Avoid variables with short names like df 56
DefaultPackage Use explicit scoping instead of the default package private level 56
SimpleDateFormatNeedsLocale When instantiating a SimpleDateFormat object, specify a Locale 56
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the df field if you want a default access modifier 56
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 94
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 108
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 123
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 138
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 152

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpAccessTransport.java

Rule Violation Line
CommentRequired Public method and constructor comments are required 6467
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 92
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 123
ShortVariable Avoid variables with short names like e 141
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 141
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 165
MissingOverride The method 'setApiEndPointUrl(String)' is missing an @Override annotation. 175179
MissingOverride The method 'getApiEndPointUrl()' is missing an @Override annotation. 186190
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 214
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 245
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 254

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpApiManagerAccessTransport.java

Rule Violation Line
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 98
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 104
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 104
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 105
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 105
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 113
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 120

fr/paris/lutece/plugins/geocode/v1/web/rs/util/Constants.java

Rule Violation Line
CommentRequired Header comments are required 346

fr/paris/lutece/plugins/geocode/v1/web/service/CustomResponseStatusValidator.java

Rule Violation Line
CommentRequired Header comments are required 3860
CommentRequired Public method and constructor comments are required 4249
NonThreadSafeSingleton Singleton is not thread safe 4447
ShortVariable Avoid variables with short names like i 56

fr/paris/lutece/plugins/geocode/v1/web/service/GeoCodeService.java

Rule Violation Line
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 92
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 107
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 122
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 135
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 148

fr/paris/lutece/plugins/geocode/v1/web/service/IGeoCodeTransportProvider.java

Rule Violation Line
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 58
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 70
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 82
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 94
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 106

fr/paris/lutece/plugins/geocode/v1/web/service/IHttpTransportProvider.java

Rule Violation Line
UnnecessaryModifier Unnecessary modifier 'public' on method 'setApiEndPointUrl': the method is declared in an interface type 52
UnnecessaryModifier Unnecessary modifier 'public' on method 'getApiEndPointUrl': the method is declared in an interface type 59
UnnecessaryModifier Unnecessary modifier 'public' on method 'doGet': the method is declared in an interface type 6163
CommentRequired Public method and constructor comments are required 6163
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 63
UnnecessaryModifier Unnecessary modifier 'public' on method 'doGetList': the method is declared in an interface type 6667
CommentRequired Public method and constructor comments are required 6667
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 67

Priority 4

fr/paris/lutece/plugins/geocode/v1/web/rs/dto/City.java

Rule Violation Line
ShortClassName Avoid short class names like City 11235

Files

fr/paris/lutece/plugins/geocode/v1/web/rs/dto/City.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 11235
ShortClassName Avoid short class names like City 4 11235
UnusedPrivateField Avoid unused private fields such as '_strValueMinComplete'. 3 41

fr/paris/lutece/plugins/geocode/v1/web/rs/dto/Country.java

Rule Violation Priority Line
CommentRequired Header comments are required 3 11102

fr/paris/lutece/plugins/geocode/v1/web/rs/service/AbstractTransportRest.java

Rule Violation Priority Line
AbstractClassWithoutAbstractMethod This abstract class does not have any abstract methods 3 4489

fr/paris/lutece/plugins/geocode/v1/web/rs/service/GeoCodeTransportMockRest.java

Rule Violation Priority Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 2 59
GuardLogStatement Logger calls should be surrounded by log level guards. 2 67
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 68
PositionLiteralsFirstInComparisons Position literals first in String comparisons 3 72
AvoidDuplicateLiterals The String literal "2000-01-01 00:00:00" appears 7 times in this file; the first occurrence is on line 78 3 78
AvoidDuplicateLiterals The String literal "1943-01-01 00:00:00" appears 6 times in this file; the first occurrence is on line 79 3 79
GuardLogStatement Logger calls should be surrounded by log level guards. 2 90
AvoidDuplicateLiterals The String literal "Toulon" appears 5 times in this file; the first occurrence is on line 94 3 94
PositionLiteralsFirstInComparisons Position literals first in String comparisons 3 94
NcssCount The method 'getListCitesByNameAndDateLike(String, Date)' has a NCSS line count of 72. 3 113207
AvoidDuplicateLiterals The String literal "2050-01-01 00:00:00" appears 5 times in this file; the first occurrence is on line 124 3 124
AvoidDuplicateLiterals The String literal "Villefranche" appears 6 times in this file; the first occurrence is on line 147 3 147
PositionLiteralsFirstInComparisons Position literals first in String comparisons 3 217

fr/paris/lutece/plugins/geocode/v1/web/rs/service/GeoCodeTransportRest.java

Rule Violation Priority Line
FieldNamingConventions The field name 'df' doesn't match '_[a-z][a-zA-Z0-9]*' 1 56
ShortVariable Avoid variables with short names like df 3 56
DefaultPackage Use explicit scoping instead of the default package private level 3 56
SimpleDateFormatNeedsLocale When instantiating a SimpleDateFormat object, specify a Locale 3 56
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the df field if you want a default access modifier 3 56
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 2 61
GuardLogStatement Logger calls should be surrounded by log level guards. 2 93
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 94
GuardLogStatement Logger calls should be surrounded by log level guards. 2 107
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 108
GuardLogStatement Logger calls should be surrounded by log level guards. 2 122
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 123
GuardLogStatement Logger calls should be surrounded by log level guards. 2 137
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 138
GuardLogStatement Logger calls should be surrounded by log level guards. 2 151
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 152

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpAccessTransport.java

Rule Violation Priority Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 2 59
CommentRequired Public method and constructor comments are required 3 6467
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 92
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 123
ShortVariable Avoid variables with short names like e 3 141
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 141
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 1 150
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 1 154
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 165
MissingOverride The method 'setApiEndPointUrl(String)' is missing an @Override annotation. 3 175179
MissingOverride The method 'getApiEndPointUrl()' is missing an @Override annotation. 3 186190
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 214
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 245
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 254

fr/paris/lutece/plugins/geocode/v1/web/rs/service/HttpApiManagerAccessTransport.java

Rule Violation Priority Line
LoggerIsNotStaticFinal The Logger variable declaration does not contain the static and final modifiers 2 63
FieldNamingConventions The constant name '_objectMapper' doesn't match '[A-Z][A-Z_0-9]*' 1 64
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 98
GuardLogStatement Logger calls should be surrounded by log level guards. 2 102
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 104
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 104
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 105
UseDiamondOperator Explicit type arguments can be replaced by Diamond Operator 3 105
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 113
AvoidCatchingGenericException Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 3 120
GuardLogStatement Logger calls should be surrounded by log level guards. 2 139

fr/paris/lutece/plugins/geocode/v1/web/rs/util/Constants.java

Rule Violation Priority Line
ClassNamingConventions The utility class name 'Constants' doesn't match '[A-Z][a-zA-Z0-9]+(Utils?|Helper|Home|Service)' 1 346
CommentRequired Header comments are required 3 346
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 1 346

fr/paris/lutece/plugins/geocode/v1/web/service/CustomResponseStatusValidator.java

Rule Violation Priority Line
ClassWithOnlyPrivateConstructorsShouldBeFinal A class which only has private constructors should be final 1 3860
CommentRequired Header comments are required 3 3860
FieldNamingConventions The static field name 'instance' doesn't match '_[a-z][a-zA-Z0-9]*' 1 40
CommentRequired Public method and constructor comments are required 3 4249
NonThreadSafeSingleton Singleton is not thread safe 3 4447
ShortVariable Avoid variables with short names like i 3 56

fr/paris/lutece/plugins/geocode/v1/web/service/GeoCodeService.java

Rule Violation Priority Line
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 92
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 107
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 122
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 135
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 148

fr/paris/lutece/plugins/geocode/v1/web/service/IGeoCodeTransportProvider.java

Rule Violation Priority Line
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 58
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 70
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 82
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 94
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 106

fr/paris/lutece/plugins/geocode/v1/web/service/IHttpTransportProvider.java

Rule Violation Priority Line
UnnecessaryModifier Unnecessary modifier 'public' on method 'setApiEndPointUrl': the method is declared in an interface type 3 52
UnnecessaryModifier Unnecessary modifier 'public' on method 'getApiEndPointUrl': the method is declared in an interface type 3 59
UnnecessaryModifier Unnecessary modifier 'public' on method 'doGet': the method is declared in an interface type 3 6163
CommentRequired Public method and constructor comments are required 3 6163
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 63
UnnecessaryModifier Unnecessary modifier 'public' on method 'doGetList': the method is declared in an interface type 3 6667
CommentRequired Public method and constructor comments are required 3 6667
SignatureDeclareThrowsException A method/constructor should not explicitly throw java.lang.Exception 3 67