Fork me on GitHub

Résultats PMD

Le document suivant contient les résultats de PMD 6.13.0.

Violations By Priority

Priority 1

fr/paris/lutece/nlptools/FileUtils.java

Rule Violation Ligne
AvoidFileStream Avoid instantiating FileInputStream, FileOutputStream, FileReader, or FileWriter 65
AvoidFileStream Avoid instantiating FileInputStream, FileOutputStream, FileReader, or FileWriter 94

Priority 2

fr/paris/lutece/nlptools/NLPAnonymizer.java

Rule Violation Ligne
SystemPrintln System.out.println is used 53
SystemPrintln System.out.println is used 75
SystemPrintln System.out.println is used 123

fr/paris/lutece/nlptools/PersonNameFinder.java

Rule Violation Ligne
SystemPrintln System.out.println is used 150
SystemPrintln System.out.println is used 180
SystemPrintln System.out.println is used 214
SystemPrintln System.out.println is used 278
SystemPrintln System.out.println is used 283

Priority 3

fr/paris/lutece/nlptools/AbstractFinder.java

Rule Violation Ligne
ImmutableField Private field '_listFoundEntities' could be made final; it is only initialized in the declaration or constructor. 48

fr/paris/lutece/nlptools/FileUtils.java

Rule Violation Ligne
UseUtilityClass All methods are static. Consider using a utility class instead. Alternatively, you could add a private constructor or make the class abstract to silence this warning. 50101
ShortVariable Avoid variables with short names like is 65
ShortVariable Avoid variables with short names like in 67
ShortVariable Avoid variables with short names like n 71
AssignmentInOperand Avoid assignments in operands 72

fr/paris/lutece/nlptools/FinderException.java

Rule Violation Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 4050
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the FinderException constructor if you want a default access modifier 4548

fr/paris/lutece/nlptools/NLPAnonymizer.java

Rule Violation Ligne
UseUtilityClass All methods are static. Consider using a utility class instead. Alternatively, you could add a private constructor or make the class abstract to silence this warning. 45125
CommentRequired Public method and constructor comments are required 49110
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 51
DoNotCallSystemExit System.exit() should not be used in J2EE/JEE apps 54
UnusedLocalVariable Avoid unused local variables such as 'nameFinder'. 64
DoNotCallSystemExit System.exit() should not be used in J2EE/JEE apps 109

fr/paris/lutece/nlptools/PersonNameFinder.java

Rule Violation Ligne
UnusedPrivateField Avoid unused private fields such as 'MODULO'. 55
ConfusingTernary Avoid if (x != y) ..; else ..; 136143
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 164
NPathComplexity The method 'replaceOccurrences(String, String)' has an NPath complexity of 302 200296
CyclomaticComplexity The method 'replaceOccurrences(String, String)' has a cyclomatic complexity of 14. 200296
ConfusingTernary Avoid if (x != y) ..; else ..; 202209
ShortVariable Avoid variables with short names like i 224
ShortVariable Avoid variables with short names like j 225
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 240
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 270
ShortVariable Avoid variables with short names like tm 310

Fichiers

fr/paris/lutece/nlptools/AbstractFinder.java

Rule Violation Priority Ligne
ImmutableField Private field '_listFoundEntities' could be made final; it is only initialized in the declaration or constructor. 3 48

fr/paris/lutece/nlptools/FileUtils.java

Rule Violation Priority Ligne
UseUtilityClass All methods are static. Consider using a utility class instead. Alternatively, you could add a private constructor or make the class abstract to silence this warning. 3 50101
AvoidFileStream Avoid instantiating FileInputStream, FileOutputStream, FileReader, or FileWriter 1 65
ShortVariable Avoid variables with short names like is 3 65
ShortVariable Avoid variables with short names like in 3 67
ShortVariable Avoid variables with short names like n 3 71
AssignmentInOperand Avoid assignments in operands 3 72
AvoidFileStream Avoid instantiating FileInputStream, FileOutputStream, FileReader, or FileWriter 1 94

fr/paris/lutece/nlptools/FinderException.java

Rule Violation Priority Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 4050
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the FinderException constructor if you want a default access modifier 3 4548

fr/paris/lutece/nlptools/NLPAnonymizer.java

Rule Violation Priority Ligne
UseUtilityClass All methods are static. Consider using a utility class instead. Alternatively, you could add a private constructor or make the class abstract to silence this warning. 3 45125
CommentRequired Public method and constructor comments are required 3 49110
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 3 51
SystemPrintln System.out.println is used 2 53
DoNotCallSystemExit System.exit() should not be used in J2EE/JEE apps 3 54
UnusedLocalVariable Avoid unused local variables such as 'nameFinder'. 3 64
SystemPrintln System.out.println is used 2 75
DoNotCallSystemExit System.exit() should not be used in J2EE/JEE apps 3 109
SystemPrintln System.out.println is used 2 123

fr/paris/lutece/nlptools/PersonNameFinder.java

Rule Violation Priority Ligne
UnusedPrivateField Avoid unused private fields such as 'MODULO'. 3 55
ConfusingTernary Avoid if (x != y) ..; else ..; 3 136143
SystemPrintln System.out.println is used 2 150
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 164
SystemPrintln System.out.println is used 2 180
NPathComplexity The method 'replaceOccurrences(String, String)' has an NPath complexity of 302 3 200296
CyclomaticComplexity The method 'replaceOccurrences(String, String)' has a cyclomatic complexity of 14. 3 200296
ConfusingTernary Avoid if (x != y) ..; else ..; 3 202209
SystemPrintln System.out.println is used 2 214
ShortVariable Avoid variables with short names like i 3 224
ShortVariable Avoid variables with short names like j 3 225
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 240
AppendCharacterWithChar Avoid appending characters as strings in StringBuffer.append. 3 270
SystemPrintln System.out.println is used 2 278
SystemPrintln System.out.println is used 2 283
ShortVariable Avoid variables with short names like tm 3 310