SiLeBAT/FSK-Lab

View on GitHub

Showing 14,752 of 14,752 total issues

Method loadSettingsFrom has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

    @Override
    protected void loadSettingsFrom(NodeSettingsRO settings,
            DataTableSpec[] specs) throws NotConfigurableException {
        String mStr = null;
        String tsStr = null;

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

    @Override
    protected void loadSettingsFrom(NodeSettingsRO settings,
            BufferedDataTable[] input) throws NotConfigurableException {
        this.input = input;
        set = new SettingsHelper();

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

    private void addOrRemoveButtonPressed(JButton button) {
        for (String model : addButtons.keySet()) {
            List<JButton> modelAddButtons = addButtons.get(model);
            List<JButton> modelRemoveButtons = removeButtons.get(model);
            List<Map<String, JComboBox<String>>> modelBoxes = comboBoxes

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

    private ParamXml processCoefficient(Parameter param, ListOf<UnitDefinition> unitDefs, Map<String, Limits> limits) {
        // Creates ParamXml and adds description
        ParamXml paramXml = new ParamXml(param.getId(), null, param.getValue());

        // Assigns unit and category

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

    public void loadSettings(NodeSettingsRO settings) {
        try {
            fittingType = settings.getString(CFGKEY_FITTINGTYPE);
        } catch (InvalidSettingsException e) {
        }

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

        @Override
        public void write(List<KnimeTuple> tuples, boolean isPMFX, String dir, String mdName, Metadata metadata,
                boolean splitModels, String notes, ExecutionContext exec) throws Exception {

            List<OneStepTertiaryModel> tms = new LinkedList<>();

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

    private void createChart() {
        String selectedID = null;

        if (configPanel.isDisplayFocusedRow()) {
            selectedID = selectionPanel.getFocusedID();

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

        @Override
        public void write(List<KnimeTuple> tuples, boolean isPMFX, String dir, String mdName, Metadata metadata,
                boolean splitModels, String notes, ExecutionContext exec) throws Exception {

            List<ManualSecondaryModel> sms = new LinkedList<>();

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

    private void button12ActionPerformed(ActionEvent e) {
        if (myDBTable1.getActualTable().isHasForm()) {
            if (isFormVisible()) {
                myDBForm1.save();
                try {
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/gui/dbtable/MyDBPanel.java - About 35 mins 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 stopCellEditing has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

  public boolean stopCellEditing() {
    //System.out.println("stopCellEditing");
      ChangeEvent ce = new ChangeEvent(this);
      for (int i=listeners.size()-1; i>=0; i--) {
        listeners.elementAt(i).editingStopped(ce);
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/gui/dbtable/editoren/BLOBEditor.java - About 35 mins 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 dropDatabase has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

    void dropDatabase() {
        DBKernel.closeDBConnections(false);
        File f = new File(DBKernel.HSHDB_PATH);
        File[] files = f.listFiles();
        if (files != null) {
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/gui/Login.java - About 35 mins 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 loopInternal has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

     private void loopInternal(Vector<Integer> vv, int row, TableModel tm, String findString) {
         for (int col = 0; col < myTable.getFieldNames().length; col++) {
             if (myTable.getFieldNames()[col].equals(columnName)) {                 
                     Object o = tm.getValueAt(row, col + 2);
                     if (o != null && o.toString().equals(findString)) { // sonst Fehler in z.B. Methoden bei der Suchfunktion

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

    public void syncTableRowHeights() {
        JScrollPane scroller = getScroller();
        if (scroller != null && scroller.getRowHeader() != null && scroller.getRowHeader().getView() instanceof JTable) {
            JTable jTable = (JTable) scroller.getRowHeader().getView();
            JTable bigTable = this.getTable(); 
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/gui/dbtable/MyDBTable.java - About 35 mins 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 compare has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

  @Override
  public int compare(Object o1, Object o2) {
      //System.out.println("MyOtherSorter");
      if (o1 == null && o2 == null) return 0;
      else if (o1 == null) return 1;
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/gui/dbtable/sorter/MyOtherSorter.java - About 35 mins 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 get has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

     public Object get(KeyStroke keyStroke) {
         if (disableKeys != null) {
             for(int i=0; i<disableKeys.length; i++) {
                 if(keyStroke.equals(disableKeys[i])) {
                     return null;

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

    public void saveSettingsTo(Config c) {
        if (set != null) set.saveConfig(c.addConfig("PredictorSettings"));
        
         modelReaderUi.saveSettingsTo(c.addConfig("ModelReaderUi"));
         mdReaderUi.saveSettingsTo(c.addConfig("MdReaderUi"));

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

    private static String getMissingString(List<Integer> missing) {
        String s = "";

        if (missing.size() <= 10) {
            for (int m : missing) {

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

    public String getMetadata() {
        String result = "--------------  " + tableName + "  --------------\n";
        for (int i = 0; i < fieldNames.length; i++) {
            result += fieldNames[i] + "\t" + (fieldComments[i] == null ? fieldNames[i] : fieldComments[i]) + "\t" + fieldTypes[i] + "\n";
        }
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/MyTable.java - About 35 mins 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 getHash has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

    private LinkedHashMap<Object, String> getHash(String fieldName) {
        if (fieldName != null && this.getForeignHashs() != null) {
            String[] fn = this.getFieldNames();
            for (int i = 0; i < fn.length; i++) {
                if (fieldName.equals(fn[i])) {
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/MyTable.java - About 35 mins 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 getAdd2Select has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

    private String getAdd2Select(String fieldName, Integer fi) {
        if (fi == null) return "'" + fieldName + "'";
        String result = "";
        boolean isDbl = this.getFieldTypes()[fi].equals("DOUBLE");
        LinkedHashMap<Object, String> hash = this.getHash(fieldName);
Severity: Minor
Found in org.hsh.bfr.db/src/org/hsh/bfr/db/MyTable.java - About 35 mins 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

Severity
Category
Status
Source
Language