Showing 7,775 of 7,775 total issues
Method evalArgs
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public static Map<String, Object> evalArgs(BindEvaluatorX eval, Component comp, Map<String, Object> args,
Map<String, Object> implicit) {
if (args == 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
Method validateSaveFormBinding
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
private boolean validateSaveFormBinding(Component comp, SaveFormBinding binding, String command,
Map<String, Property[]> validates, boolean valid, Set<Property> notifys) {
//validate tracked savebinding
Set<SaveBinding> savebindings = ((BinderCtrl) binding.getBinder())
.getFormAssociatedSaveBindings(binding.getComponent());
- 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 create
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public static AccessInfo create(Binding binding, String accessExpr, Class<?> expectedType, ConditionType type,
String command, boolean ignoreTracker) {
Method getCommandMethod
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
private Method getCommandMethod(Class<?> clz, String command, CommandMethodInfoProvider cmdInfo,
Map<Class<?>, Map<String, CachedItem<Method>>> cache, int commandParamCount, boolean isGlobal) {
Avoid deeply nested control flow statements. Open
if (matchMedias != null && args.size() != 0) {
if (!matchMedias[0].isEmpty()) {
for (String s : matchMedias) {
if (!_matchMediaValues.containsKey(s))
continue;
Method doCommand
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
private int doCommand(Component comp, CommandBinding commandBinding, String command, Event evt,
Map<String, Object> commandArgs, Set<Property> notifys) {
Method handleNotifyChange
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
protected void handleNotifyChange(Binder binder, BindContext ctx, Object viewModel, Method m, ParamCall parCall, Set<Property> changes) {
Method addFormLoadBindings
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public void addFormLoadBindings(Component comp, String id, String loadExpr, String[] beforeCmds, String[] afterCmds,
Map<String, Object> bindingArgs) {
Method processReferenceBinding
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
private void processReferenceBinding(Component comp, String propName, Annotation ann) {
String loadExpr = null;
Map<String, String[]> args = null;
for (final Iterator<Entry<String, String[]>> it = ann.getAttributes().entrySet().iterator(); it.hasNext();) {
- 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 processFormInit
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
private void processFormInit(Component comp, String formId, Annotation ann) {
String initExpr = null;
Map<String, String[]> args = null;
for (final Iterator<Entry<String, String[]>> it = ann.getAttributes().entrySet().iterator(); it.hasNext();) {
- 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 validateSavePropertyBinding
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
private boolean validateSavePropertyBinding(Component comp, SavePropertyBinding binding, String command,
Map<String, Property[]> validates, boolean valid, Set<Property> notifys) {
Method validateSaveFormBinding
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
private boolean validateSaveFormBinding(Component comp, SaveFormBinding binding, String command,
Map<String, Property[]> validates, boolean valid, Set<Property> notifys) {
Method equals
has a Cognitive Complexity of 8 (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
Avoid deeply nested control flow statements. Open
if (renderer instanceof TemplateRendererCtrl) {
((TemplateRendererCtrl) renderer).setAttributeName(attr);
}
Avoid deeply nested control flow statements. Open
if (annot.annotationType() == ImmutableFields.class) {
found = true;
break;
}
Method addFormLoadBindings0
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
private void addFormLoadBindings0(Component comp, String formId, String loadExpr, String[] beforeCmds,
String[] afterCmds, Map<String, Object> bindingArgs) {
Method remove
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
private void remove(Entry toRemove) {
Entry[] tab = this.table;
int index = (toRemove.hash & 0x7fffffff) % tab.length;
for (Entry e = tab[index], prev = null; e != null; e = e.next) {
- 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 newLoadFormBinding
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
protected LoadFormBinding newLoadFormBinding(Component comp, String formId, String loadExpr,
ConditionType conditionType, String command, Map<String, Object> bindingArgs) {
Avoid deeply nested control flow statements. Open
if ("ZKMatchMedia".equals(name)) {
matchMedias = value.trim().split(",");
} else if ("ZKClientInfo".equals(name)) {
args.put(BinderCtrl.CLIENT_INFO, JSONValue.parse(value));
}
Method processPropertyInit
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
private void processPropertyInit(Component comp, String propName, Annotation ann,
ExpressionAnnoInfo converterInfo) {
String initExpr = null;
Map<String, String[]> args = 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"