Fork me on GitHub

PMD Results

The following document contains the results of PMD 7.19.0.

Violations By Priority

Priority 3

dev/metaschema/cli/commands/AbstractConvertSubcommand.java

Rule Violation Line
CyclomaticComplexity The method 'execute()' has a cyclomatic complexity of 10. 106

dev/metaschema/cli/commands/AbstractValidateContentCommand.java

Rule Violation Line
CouplingBetweenObjects A value of 22 may denote a high amount of coupling within the class (threshold: 20) 6480
GodClass Possible God Class (WMC=59, ATFD=18, TCC=3.571%) 158
CognitiveComplexity The method 'validate(URI, Format, CommandLine, IBindingContext)' has a cognitive complexity of 37, current threshold is 15 282
NPathComplexity The method 'validate(URI, Format, CommandLine, IBindingContext)' has an NPath complexity of 664, current threshold is 200 282
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 345349
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 350356

dev/metaschema/cli/commands/GenerateSchemaCommand.java

Rule Violation Line
EnumComparison Enums should be compared using == 126

dev/metaschema/cli/commands/ListAllowedValuesCommand.java

Rule Violation Line
UnnecessaryWarningSuppression Unnecessary suppression "PMD.OnlyOneReturn" in @SuppressWarnings annotation 123
UnnecessaryWarningSuppression Unnecessary suppression "PMD.CognitiveComplexity" in @SuppressWarnings annotation 125
CyclomaticComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cyclomatic complexity of 10. 127

dev/metaschema/cli/commands/metapath/EvaluateMetapathCommand.java

Rule Violation Line
CognitiveComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cognitive complexity of 21, current threshold is 15 115
CyclomaticComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cyclomatic complexity of 24. 115
AvoidCatchingGenericException Avoid catching Exception in try-catch block 210
AvoidCatchingGenericException Avoid catching RuntimeException in try-catch block 222

dev/metaschema/cli/commands/metapath/ListFunctionsSubcommand.java

Rule Violation Line
CognitiveComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cognitive complexity of 22, current threshold is 15 65
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 92

dev/metaschema/cli/util/LoggingValidationHandler.java

Rule Violation Line
CyclomaticComplexity The method 'getLogger(IValidationFinding)' has a cyclomatic complexity of 10. 186

Files

dev/metaschema/cli/commands/AbstractConvertSubcommand.java

Rule Violation Priority Line
CyclomaticComplexity The method 'execute()' has a cyclomatic complexity of 10. 3 106

dev/metaschema/cli/commands/AbstractValidateContentCommand.java

Rule Violation Priority Line
CouplingBetweenObjects A value of 22 may denote a high amount of coupling within the class (threshold: 20) 3 6480
GodClass Possible God Class (WMC=59, ATFD=18, TCC=3.571%) 3 158
CognitiveComplexity The method 'validate(URI, Format, CommandLine, IBindingContext)' has a cognitive complexity of 37, current threshold is 15 3 282
NPathComplexity The method 'validate(URI, Format, CommandLine, IBindingContext)' has an NPath complexity of 664, current threshold is 200 3 282
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 345349
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 350356

dev/metaschema/cli/commands/GenerateSchemaCommand.java

Rule Violation Priority Line
EnumComparison Enums should be compared using == 3 126

dev/metaschema/cli/commands/ListAllowedValuesCommand.java

Rule Violation Priority Line
UnnecessaryWarningSuppression Unnecessary suppression "PMD.OnlyOneReturn" in @SuppressWarnings annotation 3 123
UnnecessaryWarningSuppression Unnecessary suppression "PMD.CognitiveComplexity" in @SuppressWarnings annotation 3 125
CyclomaticComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cyclomatic complexity of 10. 3 127

dev/metaschema/cli/commands/metapath/EvaluateMetapathCommand.java

Rule Violation Priority Line
CognitiveComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cognitive complexity of 21, current threshold is 15 3 115
CyclomaticComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cyclomatic complexity of 24. 3 115
AvoidCatchingGenericException Avoid catching Exception in try-catch block 3 210
AvoidCatchingGenericException Avoid catching RuntimeException in try-catch block 3 222

dev/metaschema/cli/commands/metapath/ListFunctionsSubcommand.java

Rule Violation Priority Line
CognitiveComplexity The method 'executeCommand(CallingContext, CommandLine)' has a cognitive complexity of 22, current threshold is 15 3 65
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 92

dev/metaschema/cli/util/LoggingValidationHandler.java

Rule Violation Priority Line
CyclomaticComplexity The method 'getLogger(IValidationFinding)' has a cyclomatic complexity of 10. 3 186

Suppressed Violations

Filename Rule message Suppression type Reason
dev/metaschema/cli/CLI.java If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation @suppresswarnings
dev/metaschema/cli/commands/AbstractValidateContentCommand.java The method 'validate(URI, Format, CommandLine, IBindingContext)' has a cyclomatic complexity of 29. @suppresswarnings
dev/metaschema/cli/commands/ListAllowedValuesCommand.java A value of 28 may denote a high amount of coupling within the class (threshold: 20) @suppresswarnings
dev/metaschema/cli/commands/ListAllowedValuesCommand.java Avoid catching RuntimeException in try-catch block @suppresswarnings
dev/metaschema/cli/commands/MetaschemaCommands.java Possible God Class (WMC=57, ATFD=21, TCC=0.000%) @suppresswarnings
dev/metaschema/cli/commands/metapath/EvaluateMetapathCommand.java Avoid unused method parameters such as 'callingContext'. @suppresswarnings