LearnPAd/learnpad

View on GitHub

Showing 1,823 of 4,261 total issues

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

    if(item.getSource() instanceof OClass) {
      iconLabel.setIcon(MainFrame.getIcon("ontology-class"));
    }
    else if(item.getSource() instanceof OInstance) {
      iconLabel.setIcon(MainFrame.getIcon("ontology-instance"));
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/CheckRenderer.java on lines 130..138

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

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(node.getSource() instanceof OClass) {
      iconLabel.setIcon(MainFrame.getIcon("ontology-class"));
    }
    else if(node.getSource() instanceof OInstance) {
      iconLabel.setIcon(MainFrame.getIcon("ontology-instance"));
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/ComboRenderer.java on lines 91..99

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

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 Cell.CELL_TYPE_NUMERIC:
                                            if (DateUtil.isCellDateFormatted(cell)) {
                                                dataTable.get(rowNumber).add(cell.getDateCellValue().toString());
                                            } else {
                                                dataTable.get(rowNumber).add(Double.toString(cell.getNumericCellValue()));
lp-ontology-recommender/src/main/java/eu/learnpad/ontology/kpi/data/ExcelParser.java on lines 113..119

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

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

      else if(anRDFProp instanceof DatatypeProperty) {
        java.util.List<Literal> values =
          anInst.getDatatypePropertyValues((DatatypeProperty)anRDFProp);
        for(int i = 0; i < values.size(); i++) {
          stringValues.add(values.get(i).getValue().toLowerCase());
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/OntologyTreePanel.java on lines 489..495
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology_Tools/src/gate/creole/ontology/ocat/OntologyTreePanel.java on lines 473..480

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

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

      while (iter.hasNext()) {
        Statement stmt = iter.next();
        Resource resource = stmt.getSubject();
        String[] removedResources =
            removePropertyFromOntology(resource.toString(), removeSubTree);
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology/src/gate/creole/ontology/impl/sesame/OntologyServiceImplSesame.java on lines 695..701

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

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

    while (result.hasNext()) {
      String classString = result.nextFirstAsString();
      byte classType = getClassType(classString);
      if (classType == OConstants.ANNONYMOUS_CLASS) {
        continue;
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology/src/gate/creole/ontology/impl/sesame/OntologyServiceImplSesame.java on lines 2724..2731

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

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

    while (result.hasNext()) {
      String classString = result.nextFirstAsString();
      byte classType = getClassType(classString);
      if (classType == OConstants.ANNONYMOUS_CLASS) {
        continue;
lp-ontology-recommender/src/main/resources/gate/plugins/Ontology/src/gate/creole/ontology/impl/sesame/OntologyServiceImplSesame.java on lines 2685..2693

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

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

/**
 *
 */
package eu.learnpad.simulator.uihandler.webserver.msg.userchat.send;

lp-simulation-environment/simulator/src/main/java/eu/learnpad/simulator/uihandler/webserver/msg/userchat/send/ReceiveLeftNotification.java on lines 1..53

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

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

    public synchronized void sendJoinNotif(String recipient, String channel,
            String originalUser) {
        for (ChatSocket s : usersSockets.get(recipient)) {
            try {
                s.getRemote().sendString(
lp-simulation-environment/simulator/src/main/java/eu/learnpad/simulator/uihandler/webserver/ChatServlet.java on lines 177..188

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

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

    public synchronized void sendLeftNotif(String recipient, String channel,
            String originalUser) {
        for (ChatSocket s : usersSockets.get(recipient)) {
            try {
                s.getRemote().sendString(
lp-simulation-environment/simulator/src/main/java/eu/learnpad/simulator/uihandler/webserver/ChatServlet.java on lines 164..175

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

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

/**
 *
 */
package eu.learnpad.simulator.uihandler.webserver.msg.userchat.send;

lp-simulation-environment/simulator/src/main/java/eu/learnpad/simulator/uihandler/webserver/msg/userchat/send/ReceiveJoinNotification.java on lines 1..53

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

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

    @GET
    @Path("/startVerification")
    @Produces(MediaType.TEXT_PLAIN)
    public static String startVerification(@QueryParam("modelId") String modelId, @QueryParam("verificationType") String verificationType){
        String ret = "";
lp-model-verification/lp-verification-component/src/main/java/eu/learnpad/verificationComponent/BridgeImpl.java on lines 169..178
lp-model-verification/verification-component/src/main/java/eu/learnpad/verification/JAXRSService.java on lines 79..88

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

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

    @GET
    @Path("/learnpad/mv/bridge/startsyncverification")
    @Produces(MediaType.TEXT_PLAIN)
    public String startSyncVerification(@QueryParam("modelsetid") String modelSetId, @QueryParam("verificationtype") String verificationType){
        String ret = "";
lp-model-verification/verification-component/src/main/java/eu/learnpad/verification/JAXRSService.java on lines 68..77
lp-model-verification/verification-component/src/main/java/eu/learnpad/verification/JAXRSService.java on lines 79..88

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

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

    @GET
    @Path("/startSyncVerification")
    @Produces(MediaType.TEXT_PLAIN)
    public static synchronized String startSyncVerification(@QueryParam("modelId") String modelId, @QueryParam("verificationType") String verificationType){
        String ret = "";
lp-model-verification/lp-verification-component/src/main/java/eu/learnpad/verificationComponent/BridgeImpl.java on lines 169..178
lp-model-verification/verification-component/src/main/java/eu/learnpad/verification/JAXRSService.java on lines 68..77

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

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

    public Bpmn(String id, Date extractionDate) {
    
        this.id = id;
        this.extractionDate = extractionDate;
        this.idCategory = 0;
lp-simulation-environment/monitoring/src/main/java/eu/learnpad/simulator/mon/coverage/Learner.java on lines 36..42

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

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

    public Learner(String id, int id_role, String name, String surname) {
        this.id = id;
        this.id_role = id_role;
        this.globalScore = 0;
        this.relativeGlobalScore = 0;
lp-simulation-environment/monitoring/src/main/java/eu/learnpad/simulator/mon/coverage/Bpmn.java on lines 13..20

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

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

        initEReference(getClass_Property(), this.getProperty(), null, "property", null, 0, -1, eu.learnpad.transformations.metamodel_corpus.xwiki.Class.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 1681..1681
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1684..1684
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1709..1709
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1710..1710
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1763..1763
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1780..1780
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1783..1783
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1784..1784
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1794..1794
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1798..1798
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1799..1799
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1808..1808
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2388..2388
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2400..2400
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2413..2413
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2460..2460
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2469..2469
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2472..2472
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2475..2475
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2505..2505
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2525..2525
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2528..2528
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2553..2553
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2565..2565
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2574..2574
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2580..2580
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2590..2590

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

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

        initEReference(getSpacesType_Space(), this.getSpace(), null, "space", null, 0, -1, SpacesType.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 1681..1681
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1684..1684
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1709..1709
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1710..1710
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1763..1763
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1780..1780
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1783..1783
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1784..1784
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1794..1794
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1798..1798
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1799..1799
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1808..1808
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2388..2388
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2397..2397
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2400..2400
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2413..2413
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2460..2460
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2469..2469
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2472..2472
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2475..2475
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2505..2505
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2525..2525
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2528..2528
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2553..2553
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2574..2574
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2580..2580
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2590..2590

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

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

        initEReference(getATTRPROFDIRType_ATTRIBUTEPROFILE(), this.getATTRIBUTEPROFILEType(), null, "aTTRIBUTEPROFILE", null, 0, -1, ATTRPROFDIRType.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 1681..1681
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1684..1684
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1710..1710
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1763..1763
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1780..1780
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1783..1783
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1784..1784
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1794..1794
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1798..1798
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1799..1799
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1808..1808
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2388..2388
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2397..2397
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2400..2400
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2413..2413
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2460..2460
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2469..2469
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2472..2472
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2475..2475
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2505..2505
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2525..2525
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2528..2528
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2553..2553
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2565..2565
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2574..2574
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2580..2580
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2590..2590

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

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

        initEReference(getPropertiesType_Property(), this.getProperty(), null, "property", null, 0, -1, PropertiesType.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 1681..1681
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1684..1684
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1709..1709
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1710..1710
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1763..1763
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1780..1780
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1783..1783
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1784..1784
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1794..1794
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1798..1798
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1799..1799
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/ado/impl/AdoPackageImpl.java on lines 1808..1808
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2388..2388
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2397..2397
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2400..2400
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2413..2413
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2460..2460
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2469..2469
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2472..2472
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2475..2475
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2505..2505
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2528..2528
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2553..2553
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2565..2565
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2574..2574
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2580..2580
lp-model-transformer/src/main/java/eu/learnpad/transformations/metamodel_corpus/xwiki/impl/XwikiPackageImpl.java on lines 2590..2590

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

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