Showing 4,841 of 7,782 total issues
File SimpleSession.java
has 324 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* SimpleSession.java
Purpose:
Description:
Method getNextToken
has 94 lines of code (exceeds 25 allowed). Consider refactoring. Open
public Token getNextToken()
{
Token matchedToken;
int curPos = 0;
File ConventionWire.java
has 323 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* ConventionWire.java
Purpose:
Description:
Method expendValue
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
private String expendValue(Map labels, String value) {
if (labels != null && value != null) {
int offset = 0;
while (offset < value.length()) {
int start = value.indexOf("${", offset);
- 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 myGetAcsObj
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
private static final AccessibleObject
myGetAcsObj(Class<?> cls, String name, Class<?>[] argTypes, int flags)
throws NoSuchMethodException {
//try public set/get
final String decoratedName =
- 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 Value
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
final public void Value() throws ParseException {
AstValue jjtn001 = new AstValue(JJTVALUE);
boolean jjtc001 = true;
jjtree.openNodeScope(jjtn001);
try {
- 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 buildNextShadowCtx
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
private ComponentMatchCtx buildNextShadowCtx() {
Component comp = _currCtx.getComponent();
boolean isShadow = comp instanceof ShadowElement;
Component child = getNextUntrackedChild(comp);
if (!isShadow) {
- 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 process
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
protected boolean process(Session sess, HttpServletRequest request, HttpServletResponse response, String originPath,
boolean bRichlet) throws ServletException, IOException {
// Fix Server-Side Request Forgery (SSRF)
String path = Https.sanitizePath(originPath);
- 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 addByCompoundValue
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public void addByCompoundValue(String cval, Location loc) {
final int len = cval.length();
if (cval.charAt(1) == '{' && cval.charAt(len - 1) == '}') { //Format 1
addInV5(cval.substring(2, len - 1));
return;
- 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 renderProperties
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
protected void renderProperties(ContentRenderer renderer) throws IOException {
_initialized = true;
render(renderer, "id", _id);
if (_auxinf != null && !_auxinf.visible) //don't call isVisible since it might be overriden (backward compatible)
renderer.render("visible", false);
- 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 init
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
private void init() {
_uri = null;
final List<Object[]> results = new LinkedList<Object[]>();
for (int j = 0, len = _fulfill.length();;) {
int k = j;
- 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 checkBinding
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public void checkBinding(Binder binder, Component comp) {
final ComponentCtrl compCtrl = (ComponentCtrl) comp;
for (String p : compCtrl.getAnnotatedProperties()) {
if (BINDER_ATTR.equals(p) || VIEW_MODEL_ATTR.equals(p) || VALIDATION_MESSAGES_ATTR.equals(p)) {
continue;
- 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 getValue
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public Object getValue(ELContext context, Object base, Object property)
throws NullPointerException, PropertyNotFoundException, ELException {
if (context == null) {
throw new NullPointerException();
}
- 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 coerceToUi
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
@SuppressWarnings("unchecked")
public Object coerceToUi(Object val, Component comp, BindContext ctx) {
Tree tree = (Tree) comp;
final TreeModel<Object> model = tree.getModel();
if (model != null && !(model instanceof TreeSelectableModel)) {
- 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 equals
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
static boolean equals(Object a, Object b) {
if (a == b) {
return true;
}
if (a == null || b == 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 load
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public void load(BindContext ctx) {
final Binder binder = getBinder();
final BindEvaluatorX eval = binder.getEvaluatorX();
final Component comp = getComponent();
final BindingExecutionInfoCollector collector = ((BinderCtrl) getBinder()).getBindingExecutionInfoCollector();
- 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 beforeChildAdded
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public void beforeChildAdded(Component newChild, Component refChild) {
if (newChild instanceof Rows) {
if (_rows != null && _rows != newChild)
throw new UiException("Only one rows child is allowed: " + this
+ "\nNote: rows is created automatically if live data");
- 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 onListDataChange
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
private void onListDataChange(ListDataEvent event) {
int type = event.getType();
// ZK-4549: should ignore before handling sorting
if (getAttribute(Attributes.BEFORE_MODEL_ITEMS_RENDERED) != null
&& (type == ListDataEvent.INTERVAL_ADDED || type == ListDataEvent.INTERVAL_REMOVED))
- 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 renderProperties
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
protected void renderProperties(org.zkoss.zk.ui.sys.ContentRenderer renderer) throws java.io.IOException {
super.renderProperties(renderer);
render(renderer, "name", _name);
if (_rows > 0)
- 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 beforeChildAdded
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public void beforeChildAdded(Component newChild, Component refChild) {
if (newChild instanceof Treecols) {
if (_treecols != null && _treecols != newChild)
throw new UiException("Only one treecols is allowed: " + this);
} else if (newChild instanceof Treefoot) {
- 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"