Showing 2,934 of 7,758 total issues

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

    static public class Option {
        String name;

        public Option(String name) {
            this.name = name;
zktest/src/main/java/org/zkoss/zktest/bind/advance/BindingParamVM.java on lines 54..68
zktest/src/main/java/org/zkoss/zktest/bind/basic/CollectionIndexDefaultComposer.java on lines 41..54
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComboboxModelSelectionVM.java on lines 61..75
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComponentSwitch.java on lines 32..47
zktest/src/main/java/org/zkoss/zktest/bind/basic/ImmutableVM.java on lines 118..133
zktest/src/main/java/org/zkoss/zktest/bind/basic/SelectboxModelSelectionVM.java on lines 60..74
zktest/src/main/java/org/zkoss/zktest/bind/comp/BiglistboxVM.java on lines 137..149
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00892ChildBindingUnderListbox.java on lines 44..58
zktest/src/main/java/org/zkoss/zktest/bind/issue/B01299RefNPE.java on lines 91..102
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel1.java on lines 66..80
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel2.java on lines 58..72
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00843SelectboxSelectedItem.java on lines 78..92
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00901ReferenceBinding.java on lines 90..107
zktest/src/main/java/org/zkoss/zktest/test2/B70_ZK_2463_Column.java on lines 3..17
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2763_VM.java on lines 24..37
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2880ViewModel.java on lines 57..71
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_3611VM.java on lines 34..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4832VM.java on lines 43..57
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4845VM.java on lines 31..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4892VM.java on lines 135..150
zktest/src/main/java/org/zkoss/zktest/test2/F85_ZK_3684VM.java on lines 31..47
zktest/src/main/java/org/zkoss/zktest/test2/F90_ZK_4392BeanModel.java on lines 67..80

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

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

    public static class Address {
        String street;
        public Address(String street){
            this.street = street;
        }
zktest/src/main/java/org/zkoss/zktest/bind/advance/BindingParamVM.java on lines 54..68
zktest/src/main/java/org/zkoss/zktest/bind/basic/CollectionIndexDefaultComposer.java on lines 41..54
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComboboxModelSelectionVM.java on lines 61..75
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComponentSwitch.java on lines 32..47
zktest/src/main/java/org/zkoss/zktest/bind/basic/ImmutableVM.java on lines 118..133
zktest/src/main/java/org/zkoss/zktest/bind/basic/SelectboxModelSelectionVM.java on lines 60..74
zktest/src/main/java/org/zkoss/zktest/bind/comp/BiglistboxVM.java on lines 137..149
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00821SelectedIndex.java on lines 76..90
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00892ChildBindingUnderListbox.java on lines 44..58
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel1.java on lines 66..80
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel2.java on lines 58..72
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00843SelectboxSelectedItem.java on lines 78..92
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00901ReferenceBinding.java on lines 90..107
zktest/src/main/java/org/zkoss/zktest/test2/B70_ZK_2463_Column.java on lines 3..17
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2763_VM.java on lines 24..37
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2880ViewModel.java on lines 57..71
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_3611VM.java on lines 34..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4832VM.java on lines 43..57
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4845VM.java on lines 31..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4892VM.java on lines 135..150
zktest/src/main/java/org/zkoss/zktest/test2/F85_ZK_3684VM.java on lines 31..47
zktest/src/main/java/org/zkoss/zktest/test2/F90_ZK_4392BeanModel.java on lines 67..80

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

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

    static public class Item {
        String name;
        
        public Item(String name) {
            this.name = name;
zktest/src/main/java/org/zkoss/zktest/bind/advance/BindingParamVM.java on lines 54..68
zktest/src/main/java/org/zkoss/zktest/bind/basic/CollectionIndexDefaultComposer.java on lines 41..54
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComboboxModelSelectionVM.java on lines 61..75
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComponentSwitch.java on lines 32..47
zktest/src/main/java/org/zkoss/zktest/bind/basic/ImmutableVM.java on lines 118..133
zktest/src/main/java/org/zkoss/zktest/bind/comp/BiglistboxVM.java on lines 137..149
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00821SelectedIndex.java on lines 76..90
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00892ChildBindingUnderListbox.java on lines 44..58
zktest/src/main/java/org/zkoss/zktest/bind/issue/B01299RefNPE.java on lines 91..102
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel1.java on lines 66..80
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel2.java on lines 58..72
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00843SelectboxSelectedItem.java on lines 78..92
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00901ReferenceBinding.java on lines 90..107
zktest/src/main/java/org/zkoss/zktest/test2/B70_ZK_2463_Column.java on lines 3..17
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2763_VM.java on lines 24..37
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2880ViewModel.java on lines 57..71
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_3611VM.java on lines 34..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4832VM.java on lines 43..57
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4845VM.java on lines 31..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4892VM.java on lines 135..150
zktest/src/main/java/org/zkoss/zktest/test2/F85_ZK_3684VM.java on lines 31..47
zktest/src/main/java/org/zkoss/zktest/test2/F90_ZK_4392BeanModel.java on lines 67..80

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

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

    static public class Item {
        String name;

        public Item(String name) {
            this.name = name;
zktest/src/main/java/org/zkoss/zktest/bind/advance/BindingParamVM.java on lines 54..68
zktest/src/main/java/org/zkoss/zktest/bind/basic/CollectionIndexDefaultComposer.java on lines 41..54
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComboboxModelSelectionVM.java on lines 61..75
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComponentSwitch.java on lines 32..47
zktest/src/main/java/org/zkoss/zktest/bind/basic/ImmutableVM.java on lines 118..133
zktest/src/main/java/org/zkoss/zktest/bind/basic/SelectboxModelSelectionVM.java on lines 60..74
zktest/src/main/java/org/zkoss/zktest/bind/comp/BiglistboxVM.java on lines 137..149
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00821SelectedIndex.java on lines 76..90
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00892ChildBindingUnderListbox.java on lines 44..58
zktest/src/main/java/org/zkoss/zktest/bind/issue/B01299RefNPE.java on lines 91..102
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel2.java on lines 58..72
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00843SelectboxSelectedItem.java on lines 78..92
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00901ReferenceBinding.java on lines 90..107
zktest/src/main/java/org/zkoss/zktest/test2/B70_ZK_2463_Column.java on lines 3..17
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2763_VM.java on lines 24..37
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2880ViewModel.java on lines 57..71
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_3611VM.java on lines 34..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4832VM.java on lines 43..57
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4845VM.java on lines 31..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4892VM.java on lines 135..150
zktest/src/main/java/org/zkoss/zktest/test2/F85_ZK_3684VM.java on lines 31..47
zktest/src/main/java/org/zkoss/zktest/test2/F90_ZK_4392BeanModel.java on lines 67..80

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

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

    public static class User {
        private String name;

        public User(String name) {
            this.name = name;
zktest/src/main/java/org/zkoss/zktest/bind/advance/BindingParamVM.java on lines 54..68
zktest/src/main/java/org/zkoss/zktest/bind/basic/CollectionIndexDefaultComposer.java on lines 41..54
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComboboxModelSelectionVM.java on lines 61..75
zktest/src/main/java/org/zkoss/zktest/bind/basic/ComponentSwitch.java on lines 32..47
zktest/src/main/java/org/zkoss/zktest/bind/basic/ImmutableVM.java on lines 118..133
zktest/src/main/java/org/zkoss/zktest/bind/basic/SelectboxModelSelectionVM.java on lines 60..74
zktest/src/main/java/org/zkoss/zktest/bind/comp/BiglistboxVM.java on lines 137..149
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00821SelectedIndex.java on lines 76..90
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00892ChildBindingUnderListbox.java on lines 44..58
zktest/src/main/java/org/zkoss/zktest/bind/issue/B01299RefNPE.java on lines 91..102
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel1.java on lines 66..80
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00823RadiogroupModel2.java on lines 58..72
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00843SelectboxSelectedItem.java on lines 78..92
zktest/src/main/java/org/zkoss/zktest/bind/issue/F00901ReferenceBinding.java on lines 90..107
zktest/src/main/java/org/zkoss/zktest/test2/B70_ZK_2463_Column.java on lines 3..17
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2763_VM.java on lines 24..37
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_2880ViewModel.java on lines 57..71
zktest/src/main/java/org/zkoss/zktest/test2/B80_ZK_3611VM.java on lines 34..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4832VM.java on lines 43..57
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4845VM.java on lines 31..45
zktest/src/main/java/org/zkoss/zktest/test2/B96_ZK_4892VM.java on lines 135..150
zktest/src/main/java/org/zkoss/zktest/test2/F85_ZK_3684VM.java on lines 31..47

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

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

  private boolean jj_3R_58() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3R_61()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2347..2355
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2410..2418
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2440..2448
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2465..2473
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2632..2640
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2810..2818

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

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

  private boolean jj_3R_75() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3R_78()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2347..2355
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2410..2418
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2465..2473
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2612..2620
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2632..2640
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2810..2818

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

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

  private boolean jj_3R_71() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3R_73()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2347..2355
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2410..2418
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2440..2448
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2612..2620
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2632..2640
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2810..2818

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

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

  private boolean jj_3R_92() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3R_100()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2347..2355
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2410..2418
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2440..2448
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2465..2473
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2612..2620
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2810..2818

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

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

  private boolean jj_3R_20() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3_2()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2347..2355
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2440..2448
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2465..2473
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2612..2620
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2632..2640
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2810..2818

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

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

    @Command @NotifyChange({"selected","sortedName"})
    public void select(){
        selected = new HashSet<Food>();
        selected.add((Food)groupsModel.getChild(0,0));
        selected.add((Food)groupsModel.getChild(1,1));
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00807GroupModelListboxMultiple.java on lines 65..70

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

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

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

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

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

Refactorings

Further Reading

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

    public void resetBuffer() {
        if (_writer instanceof StringWriter) {
            ((StringWriter) _writer).getBuffer().setLength(0);
        } else if (_stream instanceof ByteArrayOutputStream) {
            ((ByteArrayOutputStream) _stream).reset();
Severity: Minor
Found in zweb/src/main/java/org/zkoss/web/servlet/BufferedResponse.java and 1 other location - About 35 mins to fix
zweb/src/main/java/org/zkoss/web/servlet/http/HttpBufferedResponse.java on lines 135..141

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

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

  private boolean jj_3R_27() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3R_32()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2410..2418
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2440..2448
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2465..2473
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2612..2620
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2632..2640
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2810..2818

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

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

  private boolean jj_3R_45() {
    Token xsp;
    xsp = jj_scanpos;
    if (jj_3R_49()) {
    jj_scanpos = xsp;
Severity: Major
Found in zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java and 6 other locations - About 35 mins to fix
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2347..2355
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2410..2418
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2440..2448
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2465..2473
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2612..2620
zel/src/main/java/org/zkoss/zel/impl/parser/ELParser.java on lines 2632..2640

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

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

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

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

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

Refactorings

Further Reading

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

    public void resetBuffer() {
        if (_writer instanceof StringWriter) {
            ((StringWriter) _writer).getBuffer().setLength(0);
        } else if (_stream instanceof ByteArrayOutputStream) {
            ((ByteArrayOutputStream) _stream).reset();
zweb/src/main/java/org/zkoss/web/servlet/BufferedResponse.java on lines 138..144

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

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

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

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

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

Refactorings

Further Reading

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

    public static int getInt(Map<String, Object> data, String key, int defVal, boolean silent) {
        if (silent)
            try {
                return getInt(data, key, defVal);
            } catch (Throwable ex) {
Severity: Minor
Found in zk/src/main/java/org/zkoss/zk/au/AuRequests.java and 2 other locations - About 35 mins to fix
zk/src/main/java/org/zkoss/zk/au/AuRequests.java on lines 140..148
zk/src/main/java/org/zkoss/zk/au/AuRequests.java on lines 165..173

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

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

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

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

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

Refactorings

Further Reading

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

    protected void smartUpdate(String name, Object value) { //make it accessible in this package
        Listbox box = getListbox();
        if (isVisible() || box == null || !box.inSelectMold())
            super.smartUpdate(name, value);
    }
Severity: Minor
Found in zul/src/main/java/org/zkoss/zul/Listitem.java and 2 other locations - About 35 mins to fix
zul/src/main/java/org/zkoss/zul/Listitem.java on lines 299..303
zul/src/main/java/org/zkoss/zul/Listitem.java on lines 305..309

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

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

    @Command @NotifyChange({"selected","sortedName"})
    public void select(){
        selected = new HashSet<Food>();
        selected.add((Food)groupsModel.getChild(0,0));
        selected.add((Food)groupsModel.getChild(1,1));
zktest/src/main/java/org/zkoss/zktest/bind/issue/B00967GroupModelListboxMultiple.java on lines 55..60

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

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

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

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

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

Refactorings

Further Reading

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

    public static Component[] createComponentsDirectly(WebApp wapp, Reader reader, String extension, Map<?, ?> arg)
            throws IOException {
        final CCInfo cci = beforeCC(wapp);
        try {
            return cci.exec.createComponentsDirectly(reader, extension, arg);
Severity: Minor
Found in zk/src/main/java/org/zkoss/zk/ui/Executions.java and 2 other locations - About 35 mins to fix
zk/src/main/java/org/zkoss/zk/ui/Executions.java on lines 410..417
zk/src/main/java/org/zkoss/zk/ui/Executions.java on lines 453..460

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

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

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

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

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

Refactorings

Further Reading

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

    public static double getDouble(Map<String, Object> data, String key, long defVal, boolean silent) {
        if (silent)
            try {
                return getDouble(data, key, defVal);
            } catch (Throwable ex) {
Severity: Minor
Found in zk/src/main/java/org/zkoss/zk/au/AuRequests.java and 2 other locations - About 35 mins to fix
zk/src/main/java/org/zkoss/zk/au/AuRequests.java on lines 116..124
zk/src/main/java/org/zkoss/zk/au/AuRequests.java on lines 140..148

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

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