PMD Results
The following document contains the results of PMD 5.3.5.
Files
fr/paris/lutece/plugins/directory/modules/exportfile/business/File.java
Violation |
Line |
Avoid short class names like File |
39–133 |
A getX() method which returns a boolean should be named isX() |
118–121 |
fr/paris/lutece/plugins/directory/modules/exportfile/business/MappingEntry.java
Violation |
Line |
A getX() method which returns a boolean should be named isX() |
150–153 |
fr/paris/lutece/plugins/directory/modules/exportfile/service/DirectoryService.java
Violation |
Line |
Avoid unused imports such as 'fr.paris.lutece.portal.service.util.AppPathService' |
51 |
Avoid unused imports such as 'fr.paris.lutece.portal.service.util.AppPathService' |
51 |
Avoid unused imports such as 'java.text.SimpleDateFormat' |
59 |
Avoid unused imports such as 'java.text.SimpleDateFormat' |
59 |
The class 'DirectoryService' has a Cyclomatic Complexity of 4 (Highest = 11). |
68–345 |
Singleton is not thread safe |
90–95 |
Avoid using Literals in Conditional Statements |
230 |
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() |
230 |
The method 'getRecordFieldStringValue' has a Cyclomatic Complexity of 11. |
288–343 |
Avoid using Literals in Conditional Statements |
307 |
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() |
320 |
Avoid using Literals in Conditional Statements |
320 |
fr/paris/lutece/plugins/directory/modules/exportfile/service/ExportFileDaemon.java
Violation |
Line |
The class 'ExportFileDaemon' has a Cyclomatic Complexity of 7 (Highest = 10). |
65–214 |
Private field '_directorySrvc' could be made final; it is only initialized in the declaration or constructor. |
67 |
The field name indicates a constant but its modifiers do not |
69 |
Private field 'PROPERTY_IMAGE_TITLE_DATE_FORMAT' could be made final; it is only initialized in the declaration or constructor. |
69 |
Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block |
93 |
The method 'doProcessAction' has a Cyclomatic Complexity of 10. |
112–173 |
Avoid variables with short names like in |
127 |
Avoid unused method parameters such as 'nIdEntry'. |
175 |
When instantiating a SimpleDateFormat object, specify a Locale |
180 |
Avoid variables with short names like dt |
180 |
fr/paris/lutece/plugins/directory/modules/exportfile/service/FileNameService.java
Violation |
Line |
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation |
19 |
Singleton is not thread safe |
25–31 |
Use ArrayList instead of Vector |
63 |
fr/paris/lutece/plugins/directory/modules/exportfile/web/FileJspBean.java
Violation |
Line |
Avoid unused private fields such as '_file'. |
91 |
Perhaps '_file' could be replaced by a local variable. |
91 |
Assigning an Object to null is a code smell. Consider refactoring. |
96 |
fr/paris/lutece/plugins/directory/modules/exportfile/web/ManageExportfileJspBean.java
Violation |
Line |
Abstract classes should be named AbstractXXX |
48–83 |
Perhaps '_nDefaultItemsPerPage' could be replaced by a local variable. |
59 |
Do not add empty strings |
77 |
fr/paris/lutece/plugins/directory/modules/exportfile/web/MappingEntryJspBean.java
Violation |
Line |
Avoid unused imports such as 'java.util.Vector' |
53 |
Avoid unused imports such as 'java.util.Vector' |
53 |
Avoid unused imports such as 'java.util.concurrent.ConcurrentHashMap' |
54 |
Avoid unused imports such as 'java.util.concurrent.ConcurrentHashMap' |
54 |
Avoid unused imports such as 'org.apache.commons.fileupload.FileItem' |
58 |
Avoid unused imports such as 'org.apache.commons.fileupload.FileItem' |
58 |
Avoid unused private fields such as 'PROPERTY_DEFAULT_LIST_MAPPINGENTRY_PER_PAGE'. |
97 |
Private field '_directoryService' could be made final; it is only initialized in the declaration or constructor. |
124 |
Private field '_fileNameService' could be made final; it is only initialized in the declaration or constructor. |
125 |
Assigning an Object to null is a code smell. Consider refactoring. |
130 |