SiLeBAT/FSK-Lab

View on GitHub

Showing 6,856 of 14,752 total issues

File ColumnDocumentImpl.java has 255 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*
 * An XML document type.
 * Localname: Column
 * Namespace: http://www.bfr.bund.de/PCML-1_0
 * Java type: de.bund.bfr.pcml10.ColumnDocument

Function token has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    token: function (stream, state) {
      //check for state changes
      if (!state.inString && ((stream.peek() == '"') || (stream.peek() == "'"))) {
        state.stringType = stream.peek();
        stream.next(); // Skip quote
Severity: Major
Found in de.bund.bfr.knime.js/js-lib/codemirror-5.49.2/mode/toml/toml.js - About 2 hrs to fix

Function _createSimplePanel has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    _createSimplePanel(menu, modelHandler) {
        let O = this;
        _log('MODAL DETAILS / _createSimplePanel: ' + menu.id);

        // tab-pane
Severity: Major
Found in de.bund.bfr.knime.js/src/js/app/app.mt.details.js - About 2 hrs to fix

Function _createTableHead has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    _createTableHead(cols) {
        let O = this;
        _log('TABLE / _createTableHead');
        // thead
        let $thead = $('<thead></thead>');
Severity: Major
Found in de.bund.bfr.knime.js/src/js/app/app.table.js - About 2 hrs to fix

Function convertToValue has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        convertToValue: function (percent) {
            var min = this.options.min,
                max = this.options.max,
                min_decimals = min.toString().split(".")[1],
                max_decimals = max.toString().split(".")[1],
Severity: Major
Found in de.bund.bfr.knime.js/src/js/lib/ion.rangeSlider.js - About 2 hrs to fix

Function keydown has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

            keydown: function( event ) {
                if ( this.element.prop( "readOnly" ) ) {
                    suppressKeyPress = true;
                    suppressInput = true;
                    suppressKeyPressRepeat = true;

Function parse has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    parse: function( red, green, blue, alpha ) {
        if ( red === undefined ) {
            this._rgba = [ null, null, null, null ];
            return this;
        }

Function markText has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function markText(doc, from, to, options, type) {
  // Shared markers (across linked documents) are handled separately
  // (markTextShared will call out to this again, once per
  // document).
  if (options && options.shared) { return markTextShared(doc, from, to, options, type) }

Function markText has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function markText(doc, from, to, options, type) {
  // Shared markers (across linked documents) are handled separately
  // (markTextShared will call out to this again, once per
  // document).
  if (options && options.shared) { return markTextShared(doc, from, to, options, type) }

Function decode has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function decode(input) {
        // Don't use UCS-2
        var output = [],
            inputLength = input.length,
            out,

Function rules has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

module.exports = function rules() {
  var RULES = [
    { type: 'number',
      rules: [ { 'maximum': ['exclusiveMaximum'] },
               { 'minimum': ['exclusiveMinimum'] }, 'multipleOf', 'format'] },

Function resolveComponents has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function resolveComponents(base, relative) {
    var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
    var skipNormalization = arguments[3];

    var target = {};

Function 19 has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

},{}],19:[function(require,module,exports){
'use strict';
module.exports = function generate_const(it, $keyword, $ruleType) {
  var out = ' ';
  var $lvl = it.level;

Function update has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        update: function(){
            if (!this._allow_update)
                return this;

            var oldDates = this.dates.copy(),

File AssayImpl.java has 254 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/**
 */
package metadata.impl;

import metadata.Assay;

File clojure.js has 254 lines of code (exceeds 250 allowed). Consider refactoring.
Open

// CodeMirror, copyright (c) by Marijn Haverbeke and others
// Distributed under an MIT license: https://codemirror.net/LICENSE

(function(mod) {
  if (typeof exports === "object" && typeof module === "object") // CommonJS
Severity: Minor
Found in de.bund.bfr.knime.js/js-lib/codemirror-5.49.2/mode/clojure/clojure.js - About 2 hrs to fix

Method retrieveStudy has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
Open

    public Study retrieveStudy(Sheet sheet) {

        // Check first mandatory properties
        if (sheet.getRow(STUDY__STUDY_TITLE).getCell(I).getCellType() != Cell.CELL_TYPE_STRING) {
            throw new IllegalArgumentException("Missing study title");

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

    private void setModel4AgentsDef(final String[] agentsDefStr, final double[][] agentsDefDbl) {
        Object[][] tableContent = null;
        if (agentsDefStr != null) {
            tableContent = new Object[agentsDefStr.length][5];
            for (int i=0;i<agentsDefStr.length;i++) {

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

    public Study retrieveStudy(Sheet sheet) {

        // Check first mandatory properties
        if (sheet.getRow(STUDY__STUDY_TITLE).getCell(J).getCellType() != Cell.CELL_TYPE_STRING) {
            throw new IllegalArgumentException("Missing study title");

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

    private void thisKeyTyped(final KeyEvent e) {
          char ch = e.getKeyChar();
          if (ch == KeyEvent.VK_ENTER) {
              //
        }

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

Severity
Category
Status
Source
Language