Showing 2,934 of 7,758 total issues

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

  private boolean jj_3R_22() {
    if (jj_3R_29()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

    private String getEncodedHref() {
        final Desktop dt = getDesktop();
        return _auxinf != null && _auxinf.href != null && dt != null ? dt.getExecution().encodeURL(_auxinf.href) : null;
        //if desktop is null, it doesn't belong to any execution
    }
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/Button.java and 2 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/A.java on lines 173..177
zul/src/main/java/org/zkoss/zul/Menuitem.java on lines 264..268

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_40() {
    if (jj_3R_44()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_57() {
    if (jj_3R_59()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

    private String getEncodedHref() {
        final Desktop dt = getDesktop();
        return _auxinf != null && _auxinf.href != null && dt != null ? dt.getExecution().encodeURL(_auxinf.href) : null;
        //if desktop is null, it doesn't belong to any execution
    }
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/A.java and 2 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/Button.java on lines 245..249
zul/src/main/java/org/zkoss/zul/Menuitem.java on lines 264..268

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

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

    protected void updateByClient(String name, Object value) {
        if ("disabled".equals(name))
            setDisabled(value instanceof Boolean ? ((Boolean) value).booleanValue()
                    : "true".equals(Objects.toString(value)));
        else
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/Button.java and 2 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/Checkbox.java on lines 295..301
zul/src/main/java/org/zkoss/zul/Menuitem.java on lines 340..346

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

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

        public void clear() {
            int i2 = _set.size() - 1;
            if (i2 < 0) {
                return;
            }
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/ListModelMap.java and 4 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/ListModelList.java on lines 212..220
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 218..226
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 742..750
zul/src/main/java/org/zkoss/zul/ListModelSet.java on lines 216..224

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_34() {
    if (jj_3R_40()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

        public void clear() {
            int i2 = _col.size() - 1;
            if (i2 < 0) {
                return;
            }
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/ListModelMap.java and 4 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/ListModelList.java on lines 212..220
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 218..226
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 536..544
zul/src/main/java/org/zkoss/zul/ListModelSet.java on lines 216..224

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_42() {
    if (jj_3R_20()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_39() {
    if (jj_3R_38()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_31() {
    if (jj_3R_36()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

    private String getEncodedHref() {
        final Desktop dt = getDesktop();
        return _auxinf != null && _auxinf.href != null && dt != null ? dt.getExecution().encodeURL(_auxinf.href) : null;
        //if desktop is null, it doesn't belong to any execution
    }
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/Menuitem.java and 2 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/A.java on lines 173..177
zul/src/main/java/org/zkoss/zul/Button.java on lines 245..249

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_29() {
    if (jj_3R_34()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_26() {
    if (jj_3R_22()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_51() {
    if (jj_3R_57()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

    protected void updateByClient(String name, Object value) {
        if ("disabled".equals(name))
            setDisabled(value instanceof Boolean ? ((Boolean) value).booleanValue()
                    : "true".equals(Objects.toString(value)));
        else
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/Menuitem.java and 2 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/Button.java on lines 302..308
zul/src/main/java/org/zkoss/zul/Checkbox.java on lines 295..301

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

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

    public void clear() {
        int i2 = _set.size() - 1;
        if (i2 < 0) {
            return;
        }
Severity: Major
Found in zul/src/main/java/org/zkoss/zul/ListModelSet.java and 4 other locations - About 40 mins to fix
zul/src/main/java/org/zkoss/zul/ListModelList.java on lines 212..220
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 218..226
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 536..544
zul/src/main/java/org/zkoss/zul/ListModelMap.java on lines 742..750

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_47() {
    if (jj_3R_51()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2790..2798

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

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

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

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

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

Refactorings

Further Reading

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

  private boolean jj_3R_44() {
    if (jj_3R_47()) return true;
    Token xsp;
    while (true) {
      xsp = jj_scanpos;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 12 other locations - About 40 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2103..2111
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2129..2137
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2168..2176
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2194..2202
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2204..2212
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2214..2222
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2390..2398
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2425..2433
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2480..2488
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2587..2595
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2642..2650
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2706..2714

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

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

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

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

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

Refactorings

Further Reading

Severity
Category
Status
Source
Language