PMD Results

The following document contains the results of PMD 4.2.5.

Files

org/apache/myfaces/tobago/fileupload/FileUploadFacesContextFactoryImpl.java

ViolationLine
The class 'FileUploadFacesContextFactoryImpl' has a Cyclomatic Complexity of 10 (Highest = 11).64 - 144
The class 'FileUploadFacesContextFactoryImpl' has a Cyclomatic Complexity of 10 (Highest = 11).64 - 144
Private field 'facesContextFactory' could be made final; it is only initialized in the declaration or constructor.66
Private field 'repositoryPath' could be made final; it is only initialized in the declaration or constructor.67
Private field 'maxSize' could be made final; it is only initialized in the declaration or constructor.68
Parameter 'facesContextFactory' is not assigned and could be declared final70
The constructor 'FileUploadFacesContextFactoryImpl' has a Cyclomatic Complexity of 11.70 - 119
The constructor 'FileUploadFacesContextFactoryImpl' has a Cyclomatic Complexity of 11.70 - 119
Local variable 'repositoryPath' could be declared final81
Local variable 'file' could be declared final83
Avoid if (x != y) ..; else ..;84 - 92
Avoid if (x != y) ..; else ..;87 - 92
Avoid empty catch blocks94 - 96
Avoid empty catch blocks94 - 96
Local variable 'size' could be declared final99
Avoid empty catch blocks101 - 103
Avoid empty catch blocks101 - 103
Avoid empty catch blocks104 - 106
Avoid empty catch blocks104 - 106
Avoid empty catch blocks110 - 112
Avoid empty catch blocks110 - 112
Avoid reassigning parameters such as 'request'121
Parameter 'response' is not assigned and could be declared final121
Parameter 'lifecycle' is not assigned and could be declared final121
Parameter 'context' is not assigned and could be declared final121
The method 'getFacesContext' has a Cyclomatic Complexity of 7.121 - 143
Local variable 'contentType' could be declared final124
When doing a String.toLowerCase()/toUpperCase() call, use a Locale125
Local variable 'facesContext' could be declared final133
Local variable 'facesMessage' could be declared final135