SiLeBAT/FSK-Lab

View on GitHub

Showing 14,752 of 14,752 total issues

Function _positionDropdown has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  AttachBody.prototype._positionDropdown = function () {
    var $window = $(window);

    var isCurrentlyAbove = this.$dropdown[0].classList
      .contains('select2-dropdown--above');
Severity: Major
Found in de.bund.bfr.knime.js/src/js/lib/select2.full.js - About 2 hrs to fix

Function _registerEvents has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  Select2.prototype._registerEvents = function () {
    var self = this;

    this.on('open', function () {
      self.$container[0].classList.add('select2-container--open');
Severity: Major
Found in de.bund.bfr.knime.js/src/js/lib/select2.full.js - About 2 hrs to fix

Function format has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  d3.format = function(specifier) {
    var match = d3_format_re.exec(specifier), fill = match[1] || " ", align = match[2] || ">", sign = match[3] || "", symbol = match[4] || "", zfill = match[5], width = +match[6], comma = match[7], precision = match[8], type = match[9], scale = 1, suffix = "", integer = false;
    if (precision) precision = +precision.substring(1);
    if (zfill || fill === "0" && align === "=") {
      zfill = fill = "0";

Function d3_interpolateString has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  function d3_interpolateString(a, b) {
    var m, i, j, s0 = 0, s1 = 0, s = [], q = [], n, o;
    a = a + "", b = b + "";
    d3_interpolate_number.lastIndex = 0;
    for (i = 0; m = d3_interpolate_number.exec(b); ++i) {

Function _registerEvents has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  Select2.prototype._registerEvents = function () {
    var self = this;

    this.on('open', function () {
      self.$container.addClass('select2-container--open');
Severity: Major
Found in de.bund.bfr.knime.pmm.nodes/js-lib/select2/4_0_3/debug/js/select2.js - About 2 hrs to fix

Function resize has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    resize: function() {
        var outerDimensions,
            that = $(this).resizable( "instance" ),
            o = that.options,
            cs = that.size,

Function drawD3Plot has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function drawD3Plot(headless) 
    {
        
        // the plot element has to be reset because otherwise functionPlot may draw artifacts
        if(!headless){

Function init has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

ContentEditableInput.prototype.init = function (display) {
    var this$1 = this;

  var input = this, cm = input.cm
  var div = input.div = display.lineDiv

Function init has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

ContentEditableInput.prototype.init = function (display) {
    var this$1 = this;

  var input = this, cm = input.cm
  var div = input.div = display.lineDiv

Function traverseAllChildrenImpl has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) {
  var type = typeof children;

  if (type === 'undefined' || type === 'boolean') {
    // All of the above are perceived as null.

Function 23 has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

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

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    @Test
    public void testEmptyStudy() {
        
        metadata.Study emptyOldStudy = metadata.MetadataFactory.eINSTANCE.createStudy();
        Study study = EmfMetadataModule.convertStudy(MAPPER.valueToTree(emptyOldStudy));
de.bund.bfr.knime.fsklab.metadata.model.tests/src/metadata/EmfMetadataModuleTest.java on lines 749..771

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 161.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    @Test
    public void testEmptyParameter() {
        
        metadata.Parameter emptyOldParameter = metadata.MetadataFactory.eINSTANCE.createParameter();
        Parameter parameter = EmfMetadataModule.convertParameter(MAPPER.valueToTree(emptyOldParameter));
de.bund.bfr.knime.fsklab.metadata.model.tests/src/metadata/EmfMetadataModuleTest.java on lines 682..704

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 161.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

FoodProcessSetting has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

public class FoodProcessSetting {
    private final String PARAM_PROCESSNAME = "processName";
    private final String PARAM_DURATION = "duration";
    private final String PARAM_NUMBERCOMPUTATIONS = "numberComputations";
    /*

MetadataFactory has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

public interface MetadataFactory extends EFactory {
    /**
     * The singleton instance of the factory.
     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->

PopulationGroupImpl has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

public class PopulationGroupImpl extends MinimalEObjectImpl.Container implements PopulationGroup {
    /**
     * The default value of the '{@link #getPopulationName() <em>Population Name</em>}' attribute.
     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->

OtherModelModelMath has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-07-02T16:22:48.194+02:00")
public class OtherModelModelMath {
  @SerializedName("parameter")
  private List<Parameter> parameter = new ArrayList<Parameter>();

PredictiveModelModelMath has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-07-02T16:22:48.194+02:00")
public class PredictiveModelModelMath {
  @SerializedName("parameter")
  private List<Parameter> parameter = new ArrayList<Parameter>();

ModelPlotterViewConfig has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

final class ModelPlotterViewConfig {

  static final String CHART_TITLE = "chartTitle";

  static final String FUNCTION = "function";

GenericModelDataBackground has 23 methods (exceeds 20 allowed). Consider refactoring.
Open

@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-07-02T16:22:48.194+02:00")
public class GenericModelDataBackground {
  @SerializedName("study")
  private Study study = null;

Severity
Category
Status
Source
Language