LearnPAd/learnpad

View on GitHub

Showing 1,823 of 4,261 total issues

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

        if ( num>0) {
            /*elementsBPMN.addAll(elementsBPMNtemp);
            setAllElements(Elementstemp);*/
            this.Suggestion += Messages.getString("UsageInclusiveORGateways.SuggestionSubprocessKO",l)+sub.getName()+" "; //$NON-NLS-1$ //$NON-NLS-2$
            this.status = false;
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingANDGateways.java on lines 171..174
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingConvergingGateways.java on lines 170..173
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingDataObject.java on lines 99..102
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingEvents.java on lines 131..134
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingMessageEvent.java on lines 155..158
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingStartandEndEvents.java on lines 139..142
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingXORGateway.java on lines 105..108
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LoopMarkerAnnotation.java on lines 133..136
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/RestrictUsageTerminateEndEvent.java on lines 116..121
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageDefaultFlows.java on lines 108..113

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getATTRIBUTEPROFILEType_INTERREF(), this.getINTERREFType(), null, "iNTERREF", null, 0, -1, ATTRIBUTEPROFILEType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1717..1717
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1718..1718
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1755..1755
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1756..1756
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1757..1757
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1814..1814

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 46.

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 11 locations. Consider refactoring.
Open

        if ( num>0) {
            this.Suggestion += Messages.getString("LabelingConvergingGateways.SuggestionSubprocessKO",l)+sub.getName()+" "; //$NON-NLS-1$ //$NON-NLS-2$
            this.status = false;
        }
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingANDGateways.java on lines 171..174
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingDataObject.java on lines 99..102
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingEvents.java on lines 131..134
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingMessageEvent.java on lines 155..158
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingStartandEndEvents.java on lines 139..142
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingXORGateway.java on lines 105..108
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LoopMarkerAnnotation.java on lines 133..136
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/RestrictUsageTerminateEndEvent.java on lines 116..121
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageDefaultFlows.java on lines 108..113
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageInclusiveORGateways.java on lines 106..111

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 46.

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 6 locations. Consider refactoring.
Open

            } catch (ResourceInstantiationException x) {
              JOptionPane.showMessageDialog(Gaze.this,
                "Unable to load Gazetteer List (corrupted format).\n"
                +"file:///"+selected.getAbsolutePath()+"\n"
                +"Due to:\nResourceInstantiationException:"+x.getMessage()
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1044..1051
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1092..1099
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1264..1271
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1779..1786
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1819..1826

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 46.

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

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

        case VALUE_COL:
          if(feature.value instanceof List) {
            listItems.setText(feature.value.toString());
            return listPanel;
          }
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/FeaturesEditor.java on lines 486..494

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getINSTANCEType_INTERREF(), this.getINTERREFType(), null, "iNTERREF", null, 0, -1, INSTANCEType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1696..1696
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1717..1717
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1718..1718
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1755..1755
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1756..1756
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1814..1814

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 46.

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 11 locations. Consider refactoring.
Open

        if ( num>0) {
            /*    elementsBPMN.addAll(elementsBPMNtemp);
            setAllElements(Elementstemp);*/
            this.Suggestion += Messages.getString("RestrictUsageTerminateEndEvent.SuggestionSubprocessKO",l)+sub.getName()+" "; //$NON-NLS-1$ //$NON-NLS-2$
            this.status = false;
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingANDGateways.java on lines 171..174
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingConvergingGateways.java on lines 170..173
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingDataObject.java on lines 99..102
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingEvents.java on lines 131..134
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingMessageEvent.java on lines 155..158
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingStartandEndEvents.java on lines 139..142
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingXORGateway.java on lines 105..108
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LoopMarkerAnnotation.java on lines 133..136
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageDefaultFlows.java on lines 108..113
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageInclusiveORGateways.java on lines 106..111

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 46.

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

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

        case VALUE_COL:
          if(feature.value instanceof List) {
            listItems.setText(feature.value.toString());
            return listPanel;
          }
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/FeaturesEditor.java on lines 463..471

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 46.

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

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

    if(ontologyTreePanel.currentOResource2ColorMap.containsKey(conceptName)) {
      Color color =
        (Color)ontologyTreePanel.currentOResource2ColorMap.get(conceptName);
      labelPanel.setBackground(color);
      iconPanel.setBackground(Color.WHITE);
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/ComboRenderer.java on lines 107..112

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getCONNECTORType_RECORD(), this.getRECORDType(), null, "rECORD", null, 0, -1, CONNECTORType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1696..1696
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1717..1717
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1755..1755
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1756..1756
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1757..1757
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1814..1814

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getINSTANCEType_ATTRIBUTE(), this.getATTRIBUTEType(), null, "aTTRIBUTE", null, 0, -1, INSTANCEType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1696..1696
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1717..1717
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1718..1718
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1756..1756
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1757..1757
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1814..1814

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getCONNECTORType_ATTRIBUTE(), this.getATTRIBUTEType(), null, "aTTRIBUTE", null, 0, -1, CONNECTORType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1696..1696
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1718..1718
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1755..1755
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1756..1756
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1757..1757
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1814..1814

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getINSTANCEType_RECORD(), this.getRECORDType(), null, "rECORD", null, 0, -1, INSTANCEType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1696..1696
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1717..1717
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1718..1718
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1755..1755
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1757..1757
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1814..1814

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 46.

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 6 locations. Consider refactoring.
Open

            } catch (ResourceInstantiationException x) {
              JOptionPane.showMessageDialog(Gaze.this,
                "Unable to load Mapping Definition (corrupted format).\n"
                +"file:///"+selected.getAbsolutePath()+"\n"
                +"Due to:\nResourceInstantiationException:"+x.getMessage()
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1044..1051
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1092..1099
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1219..1226
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1264..1271
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/com/ontotext/gate/vr/Gaze.java on lines 1779..1786

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 46.

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

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

        for (UISocket session : activeSockets) {
            try {
                session.getRemote().sendString(
                        mapper.writeValueAsString(new SessionStarted(
                                simStartEvent.simulationsessionid,
lp-simulation-environment/simulator/src/main/java/eu/learnpad/simulator/uihandler/webserver/UIServlet.java on lines 92..103

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 46.

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

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

    if(ontologyTreePanel.currentOResource2ColorMap.containsKey(conceptName)) {
      Color color =
        (Color)ontologyTreePanel.currentOResource2ColorMap.get(conceptName);
      labelPanel.setBackground(color);
      iconLabel.setBackground(Color.WHITE);
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/CheckRenderer.java on lines 148..153

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 46.

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 11 locations. Consider refactoring.
Open

        if ( num>0) {
            this.Suggestion += Messages.getString("LabelingDataObject.SuggestionSubprocessKO",l)+sub.getName()+" "; //$NON-NLS-1$ //$NON-NLS-2$
            this.status = false;
        }
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingANDGateways.java on lines 171..174
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingConvergingGateways.java on lines 170..173
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingEvents.java on lines 131..134
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingMessageEvent.java on lines 155..158
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingStartandEndEvents.java on lines 139..142
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingXORGateway.java on lines 105..108
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LoopMarkerAnnotation.java on lines 133..136
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/RestrictUsageTerminateEndEvent.java on lines 116..121
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageDefaultFlows.java on lines 108..113
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageInclusiveORGateways.java on lines 106..111

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 46.

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 11 locations. Consider refactoring.
Open

        if ( num>0) {
            this.Suggestion += Messages.getString("LabelingStartandEndEvents.SuggestionSubprocessKO",l)+sub.getName()+" "; //$NON-NLS-1$ //$NON-NLS-2$
            this.status = false;
        }
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingANDGateways.java on lines 171..174
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingConvergingGateways.java on lines 170..173
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingDataObject.java on lines 99..102
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingEvents.java on lines 131..134
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingMessageEvent.java on lines 155..158
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingXORGateway.java on lines 105..108
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LoopMarkerAnnotation.java on lines 133..136
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/RestrictUsageTerminateEndEvent.java on lines 116..121
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageDefaultFlows.java on lines 108..113
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageInclusiveORGateways.java on lines 106..111

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 46.

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 13 locations. Consider refactoring.
Open

        initEReference(getROWType_INTERREF(), this.getINTERREFType(), null, "iNTERREF", null, 0, -1, ROWType.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1694..1694
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1695..1695
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1696..1696
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1717..1717
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1718..1718
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1719..1719
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1755..1755
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1756..1756
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1757..1757
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1776..1776
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1777..1777
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1813..1813

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 46.

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 11 locations. Consider refactoring.
Open

        if ( num>0) {
            this.Suggestion += Messages.getString("LabelingXORGateway.SuggestionSubprocessKO",l)+sub.getName()+" "; //$NON-NLS-1$ //$NON-NLS-2$
            this.status = false;
        }
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingANDGateways.java on lines 171..174
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingConvergingGateways.java on lines 170..173
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingDataObject.java on lines 99..102
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingEvents.java on lines 131..134
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingMessageEvent.java on lines 155..158
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LabelingStartandEndEvents.java on lines 139..142
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/labeling/LoopMarkerAnnotation.java on lines 133..136
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/RestrictUsageTerminateEndEvent.java on lines 116..121
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageDefaultFlows.java on lines 108..113
lp-model-verification/verification-component-understandability-plugin/src/main/java/eu/learnpad/verification/plugin/bpmn/guideline/impl/notationusage/UsageInclusiveORGateways.java on lines 106..111

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 46.

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

Severity
Category
Status
Source
Language