Method parseChildren
has a Cognitive Complexity of 65 (exceeds 5 allowed). Consider refactoring. Open
protected Object parseChildren(XMLTokener tokener, Buffer buffer, MapEntity map) {
if (map == null) {
return null;
}
MapEntityStack stack = map.getStack();
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method parseToEntity
has a Cognitive Complexity of 65 (exceeds 5 allowed). Consider refactoring. Open
@Override
public BaseItem parseToEntity(BaseItem entity, Object source) {
if (source == null || source instanceof Buffer == false) {
return null;
}
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method parseEntity
has a Cognitive Complexity of 64 (exceeds 5 allowed). Consider refactoring. Open
public CharacterBuffer parseEntity(XMLTokener tokener, Buffer buffer, MapEntity map) {
CharacterBuffer valueItem = new CharacterBuffer();
if (tokener == null || buffer == null) {
return valueItem;
}
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
File XMLTokener.java
has 491 lines of code (exceeds 250 allowed). Consider refactoring. Open
package de.uniks.networkparser.xml;
/*
NetworkParser
The MIT License
Method parseEntity
has 112 lines of code (exceeds 25 allowed). Consider refactoring. Open
public CharacterBuffer parseEntity(XMLTokener tokener, Buffer buffer, MapEntity map) {
CharacterBuffer valueItem = new CharacterBuffer();
if (tokener == null || buffer == null) {
return valueItem;
}
Method parseToEntity
has 103 lines of code (exceeds 25 allowed). Consider refactoring. Open
@Override
public BaseItem parseToEntity(BaseItem entity, Object source) {
if (source == null || source instanceof Buffer == false) {
return null;
}
Method parseChildren
has 89 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected Object parseChildren(XMLTokener tokener, Buffer buffer, MapEntity map) {
if (map == null) {
return null;
}
MapEntityStack stack = map.getStack();
Method parseAttribute
has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring. Open
protected void parseAttribute(XMLTokener tokener, Buffer buffer, MapEntity map) {
if (map == null) {
return;
}
MapEntityStack stack = map.getStack();
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method parseAttribute
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected void parseAttribute(XMLTokener tokener, Buffer buffer, MapEntity map) {
if (map == null) {
return;
}
MapEntityStack stack = map.getStack();
Method skipHeader
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
public String skipHeader(Buffer buffer) {
boolean skip = false;
CharacterBuffer tag;
if (buffer == null) {
return null;
Method skipHeader
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public String skipHeader(Buffer buffer) {
boolean skip = false;
CharacterBuffer tag;
if (buffer == null) {
return null;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Avoid deeply nested control flow statements. Open
if (currentTag == null || currentTag.equals(endTag.toString())) {
break;
} else {
valueItem.with(test);
valueItem.with(endTag);
Avoid deeply nested control flow statements. Open
if (valueItem.equals(stack.getCurrentTag())) {
stack.popStack();
/* Skip > EndTag */
buffer.skip();
}
Method nextValue
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
public Object nextValue(Buffer buffer, BaseItem creator, boolean allowQuote, boolean allowDuppleMarks, char c) {
Method addToStack
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
protected Object addToStack(SendableEntityCreatorTag creator, XMLTokener tokener, CharacterBuffer tag,
CharacterBuffer value, MapEntity map) {
Avoid too many return
statements within this method. Open
return entity;
Avoid too many return
statements within this method. Open
return valueItem;
Avoid too many return
statements within this method. Open
return entity;
Avoid too many return
statements within this method. Open
return entity;
Avoid too many return
statements within this method. Open
return null;
Avoid too many return
statements within this method. Open
return entity;
Avoid too many return
statements within this method. Open
return valueItem;
Avoid too many return
statements within this method. Open
return entity;
FIXME found Open
/* FIXME public static XsdValidationLoggingErrorHandler */
- Exclude checks