SiLeBAT/FSK-Lab

View on GitHub

Showing 6,856 of 14,752 total issues

Function parseTretiaryModels has 150 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        function parseTretiaryModels(modelList){
            /*
             * we use the primary model data as a foundation for the tertiary model
             * this applies to the attributes that are equal in all secondary models/data rows
             */

Function generate__limit has 150 lines of code (exceeds 25 allowed). Consider refactoring.
Open

module.exports = function generate__limit(it, $keyword, $ruleType) {
  var out = ' ';
  var $lvl = it.level;
  var $dataLvl = it.dataLevel;
  var $schema = it.schema[$keyword];

File StudyImpl.java has 416 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/**
 */
package metadata.impl;

import java.net.URI;

File MetaDataPane.java has 416 lines of code (exceeds 250 allowed). Consider refactoring.
Open

package de.bund.bfr.knime.fsklab.nodes.common.ui;

import java.text.ParseException;
import java.util.Arrays;
import java.util.LinkedHashMap;

Function tokenize has 149 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function tokenize(stream, state) {
      // Finally advance the stream
      var ch = stream.next();

      // BLOCKCOMMENT
Severity: Major
Found in de.bund.bfr.knime.js/js-lib/codemirror-5.49.2/mode/sas/sas.js - About 5 hrs to fix

Function exports has 149 lines of code (exceeds 25 allowed). Consider refactoring.
Open

module.exports = function (grunt) {
    require('load-grunt-tasks')(grunt);
    const sass = require('node-sass');
 
    grunt.initConfig({
Severity: Major
Found in de.bund.bfr.knime.js/Gruntfile.js - About 5 hrs to fix

Function parseDate has 149 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    parseDate: function (format, value, settings) {
        if (format == null || value == null) {
            throw "Invalid arguments";
        }

Function fill has 149 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        fill: function(){
            var d = new Date(this.viewDate),
                year = d.getUTCFullYear(),
                month = d.getUTCMonth(),
                startYear = this.o.startDate !== -Infinity ? this.o.startDate.getUTCFullYear() : -Infinity,

Method updateModelPanel has 148 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    private void updateModelPanel() {
        for (String param : set.getSecModelTuples().keySet()) {
            if (!set.getSecModelMappings().containsKey(param)) {
                set.getSecModelMappings().put(param, new LinkedHashMap<String, String>());
            }

Method yylex has 148 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    private org.fife.ui.rsyntaxtextarea.Token yylex() {
        int zzInput;
        int zzAction;

        // cached fields:

Method yylex has 148 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    private org.fife.ui.rsyntaxtextarea.Token yylex() {
        int zzInput;
        int zzAction;

        // cached fields:

Method yylex has 148 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    private org.fife.ui.rsyntaxtextarea.Token yylex() {
        int zzInput;
        int zzAction;

        // cached fields:

Function calc has 148 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        calc: function (update) {
            if (!this.options) {
                return;
            }

Severity: Major
Found in de.bund.bfr.knime.js/src/js/lib/ion.rangeSlider.js - About 5 hrs to fix

Method convertPopulationGroup has a Cognitive Complexity of 39 (exceeds 5 allowed). Consider refactoring.
Open

    static PopulationGroup convertPopulationGroup(JsonNode node) {

        PopulationGroup group = new PopulationGroup();

        if (node.has("populationName")) {

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 keyTyped has a Cognitive Complexity of 39 (exceeds 5 allowed). Consider refactoring.
Open

  @Override
public void keyTyped(final KeyEvent keyEvent) {
      char ch = keyEvent.getKeyChar();
      //System.out.println(ch + "\t" + keyEvent.isConsumed());
    if (ch == KeyEvent.VK_TAB || ch == KeyEvent.VK_ENTER && !keyEvent.isAltDown() && !keyEvent.isControlDown()) {
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/gui/dbtable/MyDBTable.java - About 5 hrs to fix

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 insertM has a Cognitive Complexity of 39 (exceeds 5 allowed). Consider refactoring.
Open

    public Integer insertM(final ParametricModel m) {
        int modelId = m.modelId;
        Integer fID = getId4Formula(m.getFormula(), m.getLevel(), modelId);
        boolean iop = isObjectPresent("Modellkatalog", modelId);

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 ModelEstimationNodeDialog.java has 413 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*******************************************************************************
 * Copyright (c) 2015 Federal Institute for Risk Assessment (BfR), Germany
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by

Method initialize has 147 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    private void initialize() {
        m_useSeconds = new JCheckBox();
        m_useMinutes = new JCheckBox();
        m_useHours = new JCheckBox();
        m_useDate = new JCheckBox();

Function 7 has 147 lines of code (exceeds 25 allowed). Consider refactoring.
Open

},{}],7:[function(require,module,exports){
'use strict';


var Lexer = require('./lexer'),

Function position has 147 lines of code (exceeds 25 allowed). Consider refactoring.
Open

$.fn.position = function( options ) {
    if ( !options || !options.of ) {
        return _position.apply( this, arguments );
    }
Severity
Category
Status
Source
Language