PMD Results
The following document contains the results of PMD 7.19.0.
Violations By Priority
Priority 3
dev/metaschema/schemagen/datatype/AbstractDatatypeManager.java
| Rule | Violation | Line |
|---|---|---|
| UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 28 |
dev/metaschema/schemagen/json/impl/JsonGenerationState.java
| Rule | Violation | Line |
|---|---|---|
| CouplingBetweenObjects | A value of 38 may denote a high amount of coupling within the class (threshold: 20) | 6–374 |
dev/metaschema/schemagen/json/impl/JsonSchemaHelper.java
| Rule | Violation | Line |
|---|---|---|
| CouplingBetweenObjects | A value of 34 may denote a high amount of coupling within the class (threshold: 20) | 6–532 |
| GodClass | Possible God Class (WMC=47, ATFD=33, TCC=0.000%) | 55 |
| CyclomaticComplexity | The method 'toJsonValue(Object, IDataTypeAdapter<?>)' has a cyclomatic complexity of 18. | 139 |
dev/metaschema/schemagen/xml/impl/AbstractXmlDatatypeProvider.java
| Rule | Violation | Line |
|---|---|---|
| AvoidSynchronizedStatement | Use ReentrantLock rather than synchronization | 48–61 |
dev/metaschema/schemagen/xml/impl/DomDatatypeContent.java
| Rule | Violation | Line |
|---|---|---|
| CognitiveComplexity | The method 'writeElement(Element, XMLStreamWriter)' has a cognitive complexity of 47, current threshold is 15 | 131 |
| CyclomaticComplexity | The method 'writeElement(Element, XMLStreamWriter)' has a cyclomatic complexity of 27. | 131 |
| NPathComplexity | The method 'writeElement(Element, XMLStreamWriter)' has an NPath complexity of 3780, current threshold is 200 | 131 |
| AvoidDeeplyNestedIfStmts | Deeply nested if..then statements are hard to read | 151–155 |
dev/metaschema/schemagen/xml/impl/IndentingXMLStreamWriter.java
| Rule | Violation | Line |
|---|---|---|
| LinguisticNaming | Linguistics Antipattern - The field 'hasTextStack' indicates linguistically it is a boolean, but it is 'Deque<Boolean>' | 37 |
| UseObjectForClearerAPI | Rather than using a lot of String arguments, consider using a container object for those values. | 171 |
dev/metaschema/schemagen/xml/impl/IndentingXMLStreamWriter2.java
| Rule | Violation | Line |
|---|---|---|
| ExcessivePublicCount | This class has 48 public methods and attributes; current threshold is 45. | 29 |
| UseObjectForClearerAPI | Rather than using a lot of String arguments, consider using a container object for those values. | 152 |
dev/metaschema/schemagen/xml/impl/XmlGenerationState.java
| Rule | Violation | Line |
|---|---|---|
| CouplingBetweenObjects | A value of 21 may denote a high amount of coupling within the class (threshold: 20) | 6–448 |
dev/metaschema/schemagen/xml/impl/schematype/XmlComplexTypeAssemblyDefinition.java
| Rule | Violation | Line |
|---|---|---|
| EnumComparison | Enums should be compared using == | 98 |
Files
dev/metaschema/schemagen/datatype/AbstractDatatypeManager.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| UseConcurrentHashMap | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | 3 | 28 |
dev/metaschema/schemagen/json/impl/JsonGenerationState.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| CouplingBetweenObjects | A value of 38 may denote a high amount of coupling within the class (threshold: 20) | 3 | 6–374 |
dev/metaschema/schemagen/json/impl/JsonSchemaHelper.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| CouplingBetweenObjects | A value of 34 may denote a high amount of coupling within the class (threshold: 20) | 3 | 6–532 |
| GodClass | Possible God Class (WMC=47, ATFD=33, TCC=0.000%) | 3 | 55 |
| CyclomaticComplexity | The method 'toJsonValue(Object, IDataTypeAdapter<?>)' has a cyclomatic complexity of 18. | 3 | 139 |
dev/metaschema/schemagen/xml/impl/AbstractXmlDatatypeProvider.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| AvoidSynchronizedStatement | Use ReentrantLock rather than synchronization | 3 | 48–61 |
dev/metaschema/schemagen/xml/impl/DomDatatypeContent.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| CognitiveComplexity | The method 'writeElement(Element, XMLStreamWriter)' has a cognitive complexity of 47, current threshold is 15 | 3 | 131 |
| CyclomaticComplexity | The method 'writeElement(Element, XMLStreamWriter)' has a cyclomatic complexity of 27. | 3 | 131 |
| NPathComplexity | The method 'writeElement(Element, XMLStreamWriter)' has an NPath complexity of 3780, current threshold is 200 | 3 | 131 |
| AvoidDeeplyNestedIfStmts | Deeply nested if..then statements are hard to read | 3 | 151–155 |
dev/metaschema/schemagen/xml/impl/IndentingXMLStreamWriter.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| LinguisticNaming | Linguistics Antipattern - The field 'hasTextStack' indicates linguistically it is a boolean, but it is 'Deque<Boolean>' | 3 | 37 |
| UseObjectForClearerAPI | Rather than using a lot of String arguments, consider using a container object for those values. | 3 | 171 |
dev/metaschema/schemagen/xml/impl/IndentingXMLStreamWriter2.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| ExcessivePublicCount | This class has 48 public methods and attributes; current threshold is 45. | 3 | 29 |
| UseObjectForClearerAPI | Rather than using a lot of String arguments, consider using a container object for those values. | 3 | 152 |
dev/metaschema/schemagen/xml/impl/XmlGenerationState.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| CouplingBetweenObjects | A value of 21 may denote a high amount of coupling within the class (threshold: 20) | 3 | 6–448 |
dev/metaschema/schemagen/xml/impl/schematype/XmlComplexTypeAssemblyDefinition.java
| Rule | Violation | Priority | Line |
|---|---|---|---|
| EnumComparison | Enums should be compared using == | 3 | 98 |
Suppressed Violations
| Filename | Rule message | Suppression type | Reason |
|---|---|---|---|
| dev/metaschema/schemagen/AbstractSchemaGenerator.java | Avoid catching Exception in try-catch block | //nopmd | need to catch close exception |
| dev/metaschema/schemagen/ModuleIndex.java | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | @suppresswarnings | |
| dev/metaschema/schemagen/json/impl/DataTypeRestrictionDefinitionJsonSchema.java | The method 'generateEnumArray()' has a cyclomatic complexity of 11. | @suppresswarnings | |
| dev/metaschema/schemagen/json/impl/DataTypeRestrictionDefinitionJsonSchema.java | Avoid instantiating new objects inside loops | //nopmd | unavoidable |
| dev/metaschema/schemagen/json/impl/DataTypeRestrictionDefinitionJsonSchema.java | Avoid instantiating new objects inside loops | //nopmd | unavoidable |
| dev/metaschema/schemagen/json/impl/IJsonGenerationState.java | Rather than using a lot of String arguments, consider using a container object for those values. | @suppresswarnings | |
| dev/metaschema/schemagen/json/impl/JsonGenerationState.java | Rather than using a lot of String arguments, consider using a container object for those values. | @suppresswarnings | |
| dev/metaschema/schemagen/json/impl/JsonGenerationState.java | Ensure that resources like this JsonGenerator object are closed after use | //nopmd | not closable here |
| dev/metaschema/schemagen/xml/XmlSchemaGenerator.java | If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation | //nopmd | concurrency not needed |
| dev/metaschema/schemagen/xml/impl/DocumentationGenerator.java | The method 'generateDocumentation(String, MarkupLine, List<MarkupMultiline>, String, IXmlGenerationState)' has a cyclomatic complexity of 10. | //nopmd | acceptable complexity |
| dev/metaschema/schemagen/xml/impl/schematype/XmlComplexTypeAssemblyDefinition.java | The method 'generateModelInstance(IModelInstanceAbsolute, IXmlGenerationState)' has a cyclomatic complexity of 13. | //nopmd | acceptable complexity |
| dev/metaschema/schemagen/xml/impl/schematype/XmlSimpleTypeUnion.java | The method 'generate(IXmlGenerationState)' has a cyclomatic complexity of 10. | //nopmd | unavoidable complexity |
