workcraft/workcraft

View on GitHub
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java

Summary

Maintainability
F
1 wk
Test Coverage

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

        for (VisualControlRegister rPredNode : dfs.getRPreset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getControlRegisterStg(rPredNode);
            Connection connection = dfs.getConnection(rPredNode, node);
            if ((connection instanceof VisualControlConnection)
                    && ((VisualControlConnection) connection).getReferencedConnection().isInverting()) {
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1030..1046

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

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 (VisualControlRegister rPredNode : dfs.getRPreset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getControlRegisterStg(rPredNode);
            Connection connection = dfs.getConnection(rPredNode, node);
            if ((connection instanceof VisualControlConnection)
                    && ((VisualControlConnection) connection).getReferencedConnection().isInverting()) {
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1114..1130

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

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

        for (VisualPopRegister rSuccNode : dfs.getRPostset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPopRegisterStg(rSuccNode);
            Connection connection = dfs.getConnection(node, rSuccNode);
            if ((connection instanceof VisualControlConnection)
                    && ((VisualControlConnection) connection).getReferencedConnection().isInverting()) {
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 964..978

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

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

        for (VisualPushRegister rSuccNode : dfs.getRPostset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPushRegisterStg(rSuccNode);
            Connection connection = dfs.getConnection(node, rSuccNode);
            if ((connection instanceof VisualControlConnection)
                    && ((VisualControlConnection) connection).getReferencedConnection().isInverting()) {
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 979..993

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

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

        if (highLevelNode instanceof VisualLogic) {
            nodeStg = getLogicStg((VisualLogic) highLevelNode);
        } else if (highLevelNode instanceof VisualRegister) {
            nodeStg = getRegisterStg((VisualRegister) highLevelNode);
        } else if (highLevelNode instanceof VisualCounterflowLogic) {
workcraft/XmasPlugin/src/org/workcraft/plugins/xmas/stg/XmasToStgConverter.java on lines 1247..1261

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

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

        for (Node predNode : preset) {
            if (fMR == null || andSync) {
                fMR = stg.createVisualSignalTransition(falseSignalName, type, SignalTransition.Direction.PLUS, container);
                fMR.setTokenColorGenerator(tokenColorGenerator);
                createConsumingArc(fM0, fMR, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 809..821

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

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

        for (Node predNode : preset) {
            if (tMR == null || orSync) {
                tMR = stg.createVisualSignalTransition(trueSignalName, type, SignalTransition.Direction.PLUS, container);
                tMR.setTokenColorGenerator(tokenColorGenerator);
                createConsumingArc(tM0, tMR, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 853..865

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

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

            if (bwCR == null || node.getReferencedComponent().isBackwardEarlyEvaluation()) {
                bwCR = stg.createVisualSignalTransition(signalName, type, SignalTransition.Direction.PLUS, container);
                bwCR.setTokenColorGenerator(postsetTokenColorGenerator);
                createConsumingArc(bwC0, bwCR, false);
                createProducingArc(bwCR, bwC1, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 210..217

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

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

            if (cR == null || node.getReferencedComponent().isEarlyEvaluation()) {
                cR = stg.createVisualSignalTransition(signalName, type, SignalTransition.Direction.PLUS, container);

                cR.setTokenColorGenerator(tokenColorGenerator);
                createConsumingArc(c0, cR, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 510..516

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

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

        for (VisualPopRegister rPredNode : dfs.getRPreset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPopRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.m1, nodeStg.tMRs.values(), true);
            createReadArcs(rPredNodeStg.m1, nodeStg.fMRs.values(), true);
            createReadArc(rPredNodeStg.m0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualPopRegister rPredNode : dfs.getRPreset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPopRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.m1, nodeStg.tMRs.values(), true);
            createReadArcs(rPredNodeStg.m1, nodeStg.fMRs.values(), true);
            createReadArc(rPredNodeStg.m0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053

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

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

        for (VisualControlRegister rSuccNode : dfs.getRPostset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getControlRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArc(rSuccNodeStg.m1, nodeStg.fMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 950..956
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 957..963
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1142..1148
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1156..1162
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1163..1169

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

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

        for (VisualPushRegister rPredNode : dfs.getRPreset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPushRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.tM1, nodeStg.tMRs.values(), true);
            createReadArcs(rPredNodeStg.tM1, nodeStg.fMRs.values(), true);
            createReadArc(rPredNodeStg.tM0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualRegister rSuccNode : dfs.getRPostset(node, VisualRegister.class)) {
            RegisterStg rSuccNodeStg = getRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArc(rSuccNodeStg.m1, nodeStg.fMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 957..963
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1142..1148
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1149..1155
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1156..1162
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1163..1169

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

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

        for (VisualPopRegister rSuccNode : dfs.getRPostset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPopRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.tM1, nodeStg.tMF, false);
            createReadArc(rSuccNodeStg.tM1, nodeStg.fMF, false);
            createReadArcs(rSuccNodeStg.tM0, nodeStg.tMRs.values(), false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 950..956
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 957..963
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1142..1148
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1149..1155
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1156..1162

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

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

        for (VisualRegister rPredNode : dfs.getRPreset(node, VisualRegister.class)) {
            RegisterStg rPredNodeStg = getRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.m1, nodeStg.tMRs.values(), true);
            createReadArcs(rPredNodeStg.m1, nodeStg.fMRs.values(), true);
            createReadArc(rPredNodeStg.m0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualControlRegister rSuccNode : dfs.getRPostset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getControlRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArc(rSuccNodeStg.m1, nodeStg.fMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 950..956
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1142..1148
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1149..1155
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1156..1162
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1163..1169

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

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

        for (VisualRegister rSuccNode : dfs.getRPostset(node, VisualRegister.class)) {
            RegisterStg rSuccNodeStg = getRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArc(rSuccNodeStg.m1, nodeStg.fMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 950..956
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 957..963
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1149..1155
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1156..1162
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1163..1169

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

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

        for (VisualLogic predNode : dfs.getPreset(node, VisualLogic.class)) {
            LogicStg predNodeStg = getLogicStg(predNode);
            createReadArcs(predNodeStg.c1, nodeStg.tMRs.values(), true);
            createReadArcs(predNodeStg.c1, nodeStg.fMRs.values(), true);
            createReadArc(predNodeStg.c0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualPushRegister rPredNode : dfs.getRPreset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPushRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.tM1, nodeStg.tMRs.values(), true);
            createReadArcs(rPredNodeStg.tM1, nodeStg.fMRs.values(), true);
            createReadArc(rPredNodeStg.tM0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualLogic predNode : dfs.getPreset(node, VisualLogic.class)) {
            LogicStg predNodeStg = getLogicStg(predNode);
            createReadArcs(predNodeStg.c1, nodeStg.tMRs.values(), true);
            createReadArcs(predNodeStg.c1, nodeStg.fMRs.values(), true);
            createReadArc(predNodeStg.c0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1023..1029
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualPushRegister rSuccNode : dfs.getRPostset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPushRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArc(rSuccNodeStg.m1, nodeStg.fMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 950..956
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 957..963
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1142..1148
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1149..1155
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1163..1169

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

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

        for (VisualRegister rPredNode : dfs.getRPreset(node, VisualRegister.class)) {
            RegisterStg rPredNodeStg = getRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.m1, nodeStg.tMRs.values(), true);
            createReadArcs(rPredNodeStg.m1, nodeStg.fMRs.values(), true);
            createReadArc(rPredNodeStg.m0, nodeStg.tMF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 892..898
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 900..906
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 935..941
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 942..948
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1015..1021
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1047..1053
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1054..1060

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

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

        for (VisualCounterflowRegister rPredNode : dfs.getRPreset(node, VisualCounterflowRegister.class)) {
            CounterflowRegisterStg rPredNodeStg = getCounterflowRegisterStg(rPredNode);
            createReadArc(rPredNodeStg.orM1, nodeStg.mR, true);
            createReadArc(rPredNodeStg.orM0, nodeStg.mF, false);
            createReadArc(rPredNodeStg.andM1, nodeStg.mF, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 671..677
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 678..684
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 686..692
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 693..699

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

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

        for (VisualCounterflowLogic succNode : dfs.getPostset(node, VisualCounterflowLogic.class)) {
            CounterflowLogicStg succNodeStg = getCounterflowLogicStg(succNode);
            createReadArc(succNodeStg.bwC1, nodeStg.orMRbw, true);
            createReadArc(succNodeStg.bwC0, nodeStg.orMFbw, false);
            createReadArc(succNodeStg.bwC1, nodeStg.andMR, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 342..348
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 671..677
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 678..684
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 686..692

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

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

        for (VisualRegister succNode : dfs.getPostset(node, VisualRegister.class)) {
            RegisterStg succNodeStg = getRegisterStg(succNode);
            createReadArc(succNodeStg.m1, nodeStg.orMRbw, true);
            createReadArc(succNodeStg.m1, nodeStg.andMR, false);
            createReadArc(succNodeStg.m0, nodeStg.orMFbw, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 342..348
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 671..677
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 686..692
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 693..699

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

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

        for (VisualCounterflowLogic predNode : dfs.getPreset(node, VisualCounterflowLogic.class)) {
            CounterflowLogicStg predNodeStg = getCounterflowLogicStg(predNode);
            createReadArc(predNodeStg.fwC1, nodeStg.orMRfw, true);
            createReadArc(predNodeStg.fwC0, nodeStg.orMFfw, false);
            createReadArc(predNodeStg.fwC1, nodeStg.andMR, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 342..348
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 671..677
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 678..684
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 693..699

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

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

        for (VisualRegister predNode : dfs.getPreset(node, VisualRegister.class)) {
            RegisterStg predNodeStg = getRegisterStg(predNode);
            createReadArc(predNodeStg.m1, nodeStg.orMRfw, true);
            createReadArc(predNodeStg.m1, nodeStg.andMR, false);
            createReadArc(predNodeStg.m0, nodeStg.orMFfw, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 342..348
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 678..684
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 686..692
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 693..699

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

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

            if (cF == null) {
                cF = stg.createVisualSignalTransition(signalName, type, SignalTransition.Direction.MINUS, container);

                createConsumingArc(c1, cF, false);
                createProducingArc(cF, c0, false);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 518..523

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

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

            if (bwCF == null) {
                bwCF = stg.createVisualSignalTransition(signalName, type, SignalTransition.Direction.MINUS, container);
                createConsumingArc(bwC1, bwCF, false);
                createProducingArc(bwCF, bwC0, false);
                setPosition(bwCF, x - 2.0, y + 2.0 - dy);
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 219..225

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

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

        for (VisualCounterflowLogic predNode : dfs.getPostset(node, VisualCounterflowLogic.class)) {
            CounterflowLogicStg predNodeStg = getCounterflowLogicStg(predNode);
            createReadArc(predNodeStg.bwC1, nodeStg.bwCRs.get(predNode), false);
            createReadArc(predNodeStg.bwC0, nodeStg.bwCFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualControlRegister predNode : dfs.getPreset(node, VisualControlRegister.class)) {
            BinaryRegisterStg predNodeStg = getControlRegisterStg(predNode);
            createReadArc(predNodeStg.m1, nodeStg.cRs.get(predNode), true);
            createReadArc(predNodeStg.m0, nodeStg.cFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualPushRegister predNode : dfs.getPreset(node, VisualPushRegister.class)) {
            BinaryRegisterStg predNodeStg = getPushRegisterStg(predNode);
            createReadArc(predNodeStg.tM1, nodeStg.cRs.get(predNode), true);
            createReadArc(predNodeStg.tM0, nodeStg.cFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualLogic predNode : dfs.getPreset(node, VisualLogic.class)) {
            LogicStg predNodeStg = getLogicStg(predNode);
            createReadArc(predNodeStg.c1, nodeStg.cRs.get(predNode), true);
            createReadArc(predNodeStg.c0, nodeStg.cFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualRegister predNode : dfs.getPreset(node, VisualRegister.class)) {
            RegisterStg predNodeStg = getRegisterStg(predNode);
            createReadArc(predNodeStg.m1, nodeStg.cRs.get(predNode), true);
            createReadArc(predNodeStg.m0, nodeStg.cFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualCounterflowLogic predNode : dfs.getPreset(node, VisualCounterflowLogic.class)) {
            CounterflowLogicStg predNodeStg = getCounterflowLogicStg(predNode);
            createReadArc(predNodeStg.fwC1, nodeStg.fwCRs.get(predNode), true);
            createReadArc(predNodeStg.fwC0, nodeStg.fwCFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualCounterflowRegister predNode : dfs.getPostset(node, VisualCounterflowRegister.class)) {
            CounterflowRegisterStg predNodeStg = getCounterflowRegisterStg(predNode);
            createReadArc(predNodeStg.orM1, nodeStg.bwCRs.get(predNode), false);
            createReadArc(predNodeStg.orM0, nodeStg.bwCFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550

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

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

        for (VisualPopRegister predNode : dfs.getPreset(node, VisualPopRegister.class)) {
            BinaryRegisterStg predNodeStg = getPopRegisterStg(predNode);
            createReadArc(predNodeStg.m1, nodeStg.cRs.get(predNode), true);
            createReadArc(predNodeStg.m0, nodeStg.cFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 540..544
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualCounterflowRegister predNode : dfs.getPreset(node, VisualCounterflowRegister.class)) {
            CounterflowRegisterStg predNodeStg = getCounterflowRegisterStg(predNode);
            createReadArc(predNodeStg.orM1, nodeStg.fwCRs.get(predNode), true);
            createReadArc(predNodeStg.orM0, nodeStg.fwCFs.get(predNode), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 235..239
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 240..244
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 245..249
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 250..254
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 255..259
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 535..539
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 546..550
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 551..555

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

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

        for (VisualLogic predNode : dfs.getPreset(node, VisualLogic.class)) {
            LogicStg predNodeStg = getLogicStg(predNode);
            createReadArcs(predNodeStg.c1, nodeStg.tMRs.values(), true);
            createReadArc(predNodeStg.c0, nodeStg.tMF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1109..1113
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1131..1135
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1136..1140

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

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

        for (VisualPopRegister rPredNode : dfs.getRPreset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPopRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.m1, nodeStg.tMRs.values(), true);
            createReadArc(rPredNodeStg.m0, nodeStg.tMF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1103..1107
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1109..1113
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1131..1135

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

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

        for (VisualPushRegister rPredNode : dfs.getRPreset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPushRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.tM1, nodeStg.tMRs.values(), true);
            createReadArc(rPredNodeStg.tM0, nodeStg.tMF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1103..1107
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1109..1113
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1136..1140

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

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

        for (VisualPopRegister rSuccNode : dfs.getRPostset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPopRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.tM1, nodeStg.tMF, false); // pop tM1 in R-postset is read only by tMF
            createReadArcs(rSuccNodeStg.tM0, nodeStg.tMRs.values(), false); // pop tM0 in R-postset is read only by tMR
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1062..1066
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1067..1071
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1072..1076

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

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

        for (VisualControlRegister rSuccNode : dfs.getRPostset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getControlRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1062..1066
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1072..1076
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1077..1081

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

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

        for (VisualRegister rPredNode : dfs.getRPreset(node, VisualRegister.class)) {
            RegisterStg rPredNodeStg = getRegisterStg(rPredNode);
            createReadArcs(rPredNodeStg.m1, nodeStg.tMRs.values(), true);
            createReadArc(rPredNodeStg.m0, nodeStg.tMF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1103..1107
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1131..1135
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1136..1140

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

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

        for (VisualPushRegister rSuccNode : dfs.getRPostset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPushRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false);
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1062..1066
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1067..1071
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1077..1081

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

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

        for (VisualRegister rSuccNode : dfs.getRPostset(node, VisualRegister.class)) {
            RegisterStg rSuccNodeStg = getRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.tMF, false); // register m1 in R-postset is read only by tMF
            createReadArcs(rSuccNodeStg.m0, nodeStg.tMRs.values(), false); // register m0 in R-postset is read only by tMR
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1067..1071
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1072..1076
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 1077..1081

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

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

        for (VisualCounterflowRegister rSuccNode : dfs.getRPostset(node, VisualCounterflowRegister.class)) {
            CounterflowRegisterStg rSuccNodeStg = getCounterflowRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.andM1, nodeStg.mF, false);
            createReadArc(rSuccNodeStg.andM0, nodeStg.mR, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualPushRegister rSuccNode : dfs.getRPostset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPushRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.mF, false);
            createReadArc(rSuccNodeStg.m0, nodeStg.mR, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualLogic predNode : dfs.getPreset(node, VisualLogic.class)) {
            LogicStg predNodeStg = getLogicStg(predNode);
            createReadArc(predNodeStg.c1, nodeStg.mR, true);
            createReadArc(predNodeStg.c0, nodeStg.mF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualPushRegister rPredNode : dfs.getRPreset(node, VisualPushRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPushRegisterStg(rPredNode);
            createReadArc(rPredNodeStg.tM1, nodeStg.mR, true);
            createReadArc(rPredNodeStg.tM0, nodeStg.mF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualRegister rPredNode : dfs.getRPreset(node, VisualRegister.class)) {
            RegisterStg rPredNodeStg = getRegisterStg(rPredNode);
            createReadArc(rPredNodeStg.m1, nodeStg.mR, true);
            createReadArc(rPredNodeStg.m0, nodeStg.mF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualControlRegister rPredNode : dfs.getRPreset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getControlRegisterStg(rPredNode);
            createReadArc(rPredNodeStg.m1, nodeStg.mR, true);
            createReadArc(rPredNodeStg.m0, nodeStg.mF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualControlRegister rSuccNode : dfs.getRPostset(node, VisualControlRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getControlRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.mF, false);
            createReadArc(rSuccNodeStg.m0, nodeStg.mR, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualPopRegister rPredNode : dfs.getRPreset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rPredNodeStg = getPopRegisterStg(rPredNode);
            createReadArc(rPredNodeStg.m1, nodeStg.mR, true);
            createReadArc(rPredNodeStg.m0, nodeStg.mF, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualRegister rSuccNode : dfs.getRPostset(node, VisualRegister.class)) {
            RegisterStg rSuccNodeStg = getRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.m1, nodeStg.mF, false);
            createReadArc(rSuccNodeStg.m0, nodeStg.mR, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualPopRegister rSuccNode : dfs.getRPostset(node, VisualPopRegister.class)) {
            BinaryRegisterStg rSuccNodeStg = getPopRegisterStg(rSuccNode);
            createReadArc(rSuccNodeStg.tM1, nodeStg.mF, false);
            createReadArc(rSuccNodeStg.tM0, nodeStg.mR, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualCounterflowRegister predNode : dfs.getPreset(node, VisualCounterflowRegister.class)) {
            CounterflowRegisterStg predNodeStg = getCounterflowRegisterStg(predNode);
            createReadArc(predNodeStg.orM1, nodeStg.orMRfw, true);
            createReadArc(predNodeStg.orM0, nodeStg.orMFfw, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 706..710

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

        for (VisualCounterflowRegister succNode : dfs.getPostset(node, VisualCounterflowRegister.class)) {
            CounterflowRegisterStg succNodeStg = getCounterflowRegisterStg(succNode);
            createReadArc(succNodeStg.orM1, nodeStg.orMRbw, true);
            createReadArc(succNodeStg.orM0, nodeStg.orMFbw, false);
        }
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 331..335
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 337..341
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 349..353
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 354..358
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 359..363
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 365..369
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 370..374
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 375..379
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 380..384
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 385..389
workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/stg/DfsToStgConverter.java on lines 701..705

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

There are no issues that match your filters.

Category
Status