The following document contains the results of PMD 5.3.5.
Violation | Line |
---|---|
Avoid unused imports such as 'fr.paris.lutece.plugins.mylutece.modules.ldapdatabase.authentication.business.LdapDatabaseDAO' | 38 |
Avoid unused imports such as 'fr.paris.lutece.plugins.mylutece.modules.ldapdatabase.authentication.business.LdapDatabaseDAO' | 38 |
Avoid unused imports such as 'fr.paris.lutece.portal.service.spring.SpringContextService' | 46 |
Avoid unused imports such as 'fr.paris.lutece.portal.service.spring.SpringContextService' | 46 |
Avoid unnecessary constructors - the compiler will generate these for you | 81–84 |
Avoid declaring a variable if it is unreferenced before a possible exit point. | 138 |
Avoid declaring a variable if it is unreferenced before a possible exit point. | 152 |
Document empty method | 174–175 |
Violation | Line |
---|---|
Avoid using implementation types like 'ArrayList'; use the interface instead | 68 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 68 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 77 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 77 |
Violation | Line |
---|---|
Use explicit scoping instead of the default package private level | 71–74 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 118 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 118 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 142 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 142 |
Violation | Line |
---|---|
Avoid using implementation types like 'ArrayList'; use the interface instead | 82 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 82 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 94 |
Avoid using implementation types like 'ArrayList'; use the interface instead | 94 |
Violation | Line |
---|---|
Singleton is not thread safe | 58–62 |
Violation | Line |
---|---|
Use explicit scoping instead of the default package private level | 72–75 |
Violation | Line |
---|---|
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 67 |
Avoid unnecessary if..then..else statements when returning booleans | 67–70 |
Violation | Line |
---|---|
Possible God class (WMC=57, ATFD=42, TCC=0.06190476190476191) | 34–624 |
The class 'LdapBrowser' has a Cyclomatic Complexity of 3 (Highest = 10). | 61–624 |
Avoid excessively long variable names like PROPERTY_USER_DN_SEARCH_FILTER_BY_CRITERIA_GIVENNAME | 71 |
Avoid unnecessary constructors - the compiler will generate these for you | 121–123 |
Document empty constructor | 121–123 |
Avoid variables with short names like sr | 138 |
The String literal "' with search filter : " appears 4 times in this file; the first occurrence is on line 206 | 206 |
The method 'getUserPublicData' has a Cyclomatic Complexity of 10. | 228–316 |
Avoid variables with short names like sr | 231 |
Avoid using Literals in Conditional Statements | 290 |
Avoid variables with short names like dn | 329 |
Avoid variables with short names like sr | 330 |
Avoid using Literals in Conditional Statements | 362 |
Avoid variables with short names like in | 425 |
Avoid prefixing parameters by in, out or inOut. Uses Javadoc to document this behavior. | 425 |
Avoid variables with short names like sb | 437 |
StringBuffer constructor is initialized with size 16, but has at least 26 characters appended. | 437 |
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 438 |
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 439 |
StringBuffer (or StringBuilder).append is called consecutively without reusing the target variable. | 440 |
Position literals first in String comparisons for EqualsIgnoreCase | 517 |
Consider using varargs for methods or constructors which take an array the last parameter. | 547 |
Avoid unnecessary comparisons in boolean expressions | 553 |
Prefer StringBuffer over += for concatenating strings | 555 |
Prefer StringBuffer over += for concatenating strings | 559 |
Assigning an Object to null is a code smell. Consider refactoring. | 602 |
Violation | Line |
---|---|
Rather than using a lot of String arguments, consider using a container object for those values. | 68–69 |
Consider replacing this Hashtable with the newer java.util.Map | 71 |
Rather than using a lot of String arguments, consider using a container object for those values. | 106 |
Consider replacing this Hashtable with the newer java.util.Map | 111 |
Avoid variables with short names like sc | 134 |
Violation | Line |
---|---|
It is a good practice to call super() in a constructor | 116–118 |
Document empty constructor | 116–118 |
Avoid unnecessary constructors - the compiler will generate these for you | 116–118 |
Position literals first in String comparisons | 162 |
Avoid unnecessary comparisons in boolean expressions | 162 |
Avoid unnecessary comparisons in boolean expressions | 162 |
Position literals first in String comparisons | 162 |
Avoid unnecessary comparisons in boolean expressions | 163 |
Position literals first in String comparisons | 163 |
Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block | 170 |
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 176 |
Avoid declaring a variable if it is unreferenced before a possible exit point. | 196 |
Avoid declaring a variable if it is unreferenced before a possible exit point. | 197 |
Avoid declaring a variable if it is unreferenced before a possible exit point. | 198 |
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() | 215 |
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 359 |