Showing 7,777 of 7,777 total issues
Method jjMoveNfa_2
has 335 lines of code (exceeds 25 allowed). Consider refactoring. Open
private int jjMoveNfa_2(int startState, int curPos)
{
int startsAt = 0;
jjnewStateCnt = 30;
int i = 1;
Function setDocument
has 333 lines of code (exceeds 25 allowed). Consider refactoring. Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare, subWindow,
doc = node ? node.ownerDocument || node : preferredDoc;
// Return early if doc is invalid or already selected
Method setModel
has a Cognitive Complexity of 83 (exceeds 5 allowed). Consider refactoring. Open
public void setModel(ListModel<?> model) {
//ZK-3514: speed up
if (_model != null && _model != model) {
int threshold = Utils.getIntAttribute(this, "org.zkoss.zul.invalidateThreshold", 10, true);
int diff = Math.abs((model != null ? model.getSize() : 0) - _model.getSize());
- 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 Scrollbar.ts
has 709 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* Scrollbar.ts
Purpose:
Description:
Component
has 86 methods (exceeds 20 allowed). Consider refactoring. Open
public interface Component extends Scope, java.io.Serializable, Cloneable {
/** Returns the widget class (a.k.a., the widget type), or null
* if not available.
* The widget class is a JavaScript class, including the package name.
* For example, "zul.wnd.Window".
File UiVisualizer.java
has 705 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* UiVisualizer.java
Purpose:
Description:
Method renderValue
has a Cognitive Complexity of 81 (exceeds 5 allowed). Consider refactoring. Open
private String renderValue(Object value) {
if (value == null || value instanceof String) {
return renderValue((String) value);
}
if (value instanceof Date) {
- 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 parseLang
has 321 lines of code (exceeds 25 allowed). Consider refactoring. Open
private static void parseLang(Document doc, Locator locator, URL url, boolean addon) throws Exception {
final Element root = doc.getRootElement();
final String lang = IDOMs.getRequiredElementValue(root, "language-name");
final LanguageDefinition langdef;
final Device device;
InputElement
has 85 methods (exceeds 20 allowed). Consider refactoring. Open
public abstract class InputElement extends XulElement implements Constrainted, Readonly, Disable {
private static final Logger log = LoggerFactory.getLogger(InputElement.class);
static {
addClientEvent(InputElement.class, Events.ON_CHANGE, CE_IMPORTANT | CE_REPEAT_IGNORE);
Method Math
has a Cognitive Complexity of 80 (exceeds 5 allowed). Consider refactoring. Open
final public void Math() throws ParseException {
Multiplication();
label_12:
while (true) {
switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
- 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 tieValue
has a Cognitive Complexity of 80 (exceeds 5 allowed). Consider refactoring. Open
public void tieValue(Object comp, Object base, Object script, Object propName, Object value, Object basePath) {
if (value instanceof IndirectBinding) {
value = ((IndirectBinding) value).getValue(null);
}
if (base == null) { //track from component
- 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 lookup
has a Cognitive Complexity of 79 (exceeds 5 allowed). Consider refactoring. Open
public static Template lookup(Component comp, Component base, String name, Component compBase,
boolean excludeBase) {
if (comp == null)
return null;
Template template = (excludeBase && comp == base) ? null : comp.getTemplate(name);
- 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 browserInfo
has a Cognitive Complexity of 79 (exceeds 5 allowed). Consider refactoring. Open
private static void browserInfo(Map<String, Object> zk, String ua) {
if (ua != null) {
// ZK-1822: In locale Turkish, it can prevent 'I'.toLowerCase becomes 'i' without dot.
ua = ua.toLowerCase(Locale.ENGLISH);
if (_clientId != 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
Function _mouseDown
has a Cognitive Complexity of 79 (exceeds 5 allowed). Consider refactoring. Open
_mouseDown(evt: JQuery.MouseDownEvent<never, never, HTMLElement>): void {
if (this._pressTimer) {
clearInterval(this._pressTimer);
this._pressTimer = undefined;
}
- 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 DefinitionLoaders.java
has 688 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* DefinitionLoaders.java
Purpose:
Description:
Method getMethod
has a Cognitive Complexity of 78 (exceeds 5 allowed). Consider refactoring. Open
@SuppressWarnings("null")
public static Method getMethod(Object base, Object property,
Class<?>[] paramTypes, Object[] paramValues)
throws MethodNotFoundException {
if (base == null || property == 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
File AbstractTreeModel.java
has 684 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* AbstractTreeModel.java
Purpose:
Description:
PageDefinition
has 82 methods (exceeds 20 allowed). Consider refactoring. Open
public class PageDefinition implements NodeInfo {
/** A list of a children ({@link NodeInfo}). */
private final List<NodeInfo> _children = new LinkedList<NodeInfo>();
private final LanguageDefinition _langdef;
private final Locator _locator;
JQZK
has 82 functions (exceeds 20 allowed). Consider refactoring. Open
export class JQZK {
/**
* The associated instance of {@link JQZK.jq}, the object returned by `jq(...)`.
*/
declare jq: JQuery;
File ConfigParser.java
has 675 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* ConfigParser.java
Purpose:
Description: