PMD Results
The following document contains the results of PMD 5.3.5.
Files
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/business/listener/DirectoryPDFProducerRemovalListener.java
Violation |
Line |
Avoid variables with short names like id |
58 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/business/zipbasket/ZipBasketDAO.java
Violation |
Line |
Use block level rather than method level synchronization |
90–105 |
Avoid using a branching statement as the last in a loop. |
268 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/business/zipbasket/queue/ZipItem.java
Violation |
Line |
Returning '_listIdRecord' may expose an internal array. |
41 |
Consider using varargs for methods or constructors which take an array the last parameter. |
48 |
The user-supplied array 'listIdRecord' is stored directly. |
48 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/service/DirectoryManageZipBasketService.java
Violation |
Line |
The String literal "\n\tChanging zip status to '" appears 4 times in this file; the first occurrence is on line 358 |
358 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/service/DirectoryPDFProducerArchiveResourceIdService.java
Violation |
Line |
Avoid variables with short names like rt |
86 |
Avoid variables with short names like p |
97 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/service/ZipService.java
Violation |
Line |
Avoid variables with short names like os |
127 |
Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block |
152 |
Rather than using a lot of String arguments, consider using a container object for those values. |
215–216 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/service/daemon/AddZipToBasketDaemon.java
Violation |
Line |
The class 'AddZipToBasketDaemon' has a Cyclomatic Complexity of 6 (Highest = 13). |
19–175 |
The class 'AddZipToBasketDaemon' has a Standard Cyclomatic Complexity of 6 (Highest = 13). |
19–175 |
The class 'AddZipToBasketDaemon' has a Modified Cyclomatic Complexity of 6 (Highest = 13). |
19–175 |
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation |
25 |
The method 'run' has a Standard Cyclomatic Complexity of 13. |
31–124 |
The method 'run' has a Cyclomatic Complexity of 13. |
31–124 |
The method 'run' has a Modified Cyclomatic Complexity of 13. |
31–124 |
Avoid using Literals in Conditional Statements |
48 |
Use block level rather than method level synchronization |
126–155 |
Use block level rather than method level synchronization |
157–168 |
Consider simply returning the value vs storing it in local variable 'item' |
166 |
Use block level rather than method level synchronization |
170–173 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/service/daemon/AsyncAddZipBasketService.java
Violation |
Line |
The class 'AsyncAddZipBasketService' has a Cyclomatic Complexity of 5 (Highest = 12). |
20–135 |
The user-supplied array 'listIdRecord' is stored directly. |
55 |
Consider using varargs for methods or constructors which take an array the last parameter. |
55 |
The method 'run' has a Cyclomatic Complexity of 12. |
69–134 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/service/daemon/ZipCleanerDaemon.java
Violation |
Line |
Private field '_manageZipBasketService' could be made final; it is only initialized in the declaration or constructor. |
65 |
StringBuffer constructor is initialized with size 16, but has at least 52 characters appended. |
73 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/utils/FilesUtils.java
Violation |
Line |
The class 'FilesUtils' has a Cyclomatic Complexity of 4 (Highest = 12). |
74–330 |
Avoid variables with short names like sz |
99 |
These nested if statements could be combined |
116–119 |
These nested if statements could be combined |
133–136 |
The method 'getAllFilesRecorded' has a Cyclomatic Complexity of 12. |
163–215 |
Avoid declaring a variable if it is unreferenced before a possible exit point. |
167 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/web/ZipBasketJspBean.java
Violation |
Line |
A high number of imports can indicate a high degree of coupling within an object. |
34–592 |
The class 'ZipBasketJspBean' has a Cyclomatic Complexity of 5 (Highest = 12). |
85–592 |
Avoid unused private fields such as '_manageConfigProducerService'. |
137 |
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation |
158 |
The method 'getConfirmAddZipBasket' has a Cyclomatic Complexity of 12. |
213–266 |
Deeply nested if..then statements are hard to read |
230–233 |
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() |
544 |
Assigning an Object to null is a code smell. Consider refactoring. |
564 |
fr/paris/lutece/plugins/directory/modules/pdfproducerarchive/web/action/ZipBasketAction.java
Violation |
Line |
Avoid unnecessary if..then..else statements when returning booleans |
116–119 |