zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java

Summary

Maintainability
F
1 mo
Test Coverage

File BinderImpl.java has 2385 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/* BinderImpl.java

    Purpose:
        
    Description:
Severity: Major
Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 6 days to fix

    BinderImpl has 148 methods (exceeds 20 allowed). Consider refactoring.
    Open

    public class BinderImpl implements Binder, BinderCtrl, Serializable {
        private static final long serialVersionUID = 1463169907348730644L;
    
        private static final Logger _log = LoggerFactory.getLogger(BinderImpl.class);
    
    
    Severity: Major
    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 days to fix

      Method init has a Cognitive Complexity of 51 (exceeds 5 allowed). Consider refactoring.
      Open

          public void init(Component comp, Object viewModel, Map<String, Object> initArgs) {
              if (_init)
                  throw new UiException("binder is already initialized");
              _init = true;
              
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 7 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method addPropertySaveBindings0 has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring.
      Open

          private void addPropertySaveBindings0(Component comp, String attr, String saveExpr, String[] beforeCmds,
                  String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                  Map<String, Object> converterArgs, String validatorExpr, Map<String, Object> validatorArgs) {
              final boolean prompt = isPrompt(beforeCmds, afterCmds);
              final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 7 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method addPropertyLoadBindings0 has a Cognitive Complexity of 46 (exceeds 5 allowed). Consider refactoring.
      Open

          private void addPropertyLoadBindings0(Component comp, String attr, String loadExpr, String[] beforeCmds,
                  String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                  Map<String, Object> converterArgs) {
              final boolean prompt = isPrompt(beforeCmds, afterCmds);
              final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 7 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method getCommandMethod has a Cognitive Complexity of 39 (exceeds 5 allowed). Consider refactoring.
      Open

          private Method getCommandMethod(Class<?> clz, String command, CommandMethodInfoProvider cmdInfo,
                  Map<Class<?>, Map<String, CachedItem<Method>>> cache, int commandParamCount, boolean isGlobal) {
              Map<String, CachedItem<Method>> methods;
              Method matchedMethodWithoutAnno = null;
              CachedItem<Method> method = null;
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 5 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method doValidate has a Cognitive Complexity of 38 (exceeds 5 allowed). Consider refactoring.
      Open

          protected boolean doValidate(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
              final Set<Property> validates = new HashSet<Property>();
              String debugInfo = MessageFormat.format("doValidate "
                      + "comp=[{0}],command=[{1}],evt=[{2}],context=[{3}]", comp, command, evt, ctx);
              try {
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 5 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method doPropertyChange0 has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring.
      Open

          private void doPropertyChange0(Object base, String prop, Set<LoadBinding> bindings) {
              Execution exec = Executions.getCurrent();
              Set<Component> skipCheckChildren = (Set<Component>) exec.getAttribute(HtmlShadowElement.SKIP_DISTRIBUTED_CHILDREN_PROPERTY_CHANGE);
              for (LoadBinding binding : bindings) {
                  //BUG 828, the sub-sequence binding might be removed after the previous loading.
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 5 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method addChildrenLoadBindings0 has a Cognitive Complexity of 34 (exceeds 5 allowed). Consider refactoring.
      Open

          private void addChildrenLoadBindings0(Component comp, String loadExpr, String[] beforeCmds, String[] afterCmds,
                  Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
              final boolean prompt = isPrompt(beforeCmds, afterCmds);
              final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
              if (prompt) {
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 5 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method addFormLoadBindings0 has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring.
      Open

          private void addFormLoadBindings0(Component comp, String formId, String loadExpr, String[] beforeCmds,
                  String[] afterCmds, Map<String, Object> bindingArgs) {
              final boolean prompt = isPrompt(beforeCmds, afterCmds);
              final String attr = formId;
              final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 4 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method initRendererIfAny has a Cognitive Complexity of 31 (exceeds 5 allowed). Consider refactoring.
      Open

          private void initRendererIfAny(Component comp, String attr) {
              final Object installed = comp.getAttribute(BinderCtrl.RENDERER_INSTALLED);
              if (installed != null) { //renderer was set already init
                  return;
              }
      Severity: Minor
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 4 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method addPropertySaveBindings0 has 91 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          private void addPropertySaveBindings0(Component comp, String attr, String saveExpr, String[] beforeCmds,
                  String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                  Map<String, Object> converterArgs, String validatorExpr, Map<String, Object> validatorArgs) {
              final boolean prompt = isPrompt(beforeCmds, afterCmds);
              final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
      Severity: Major
      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 3 hrs to fix

        Method addFormSaveBindings0 has a Cognitive Complexity of 24 (exceeds 5 allowed). Consider refactoring.
        Open

            private void addFormSaveBindings0(Component comp, String formId, String saveExpr, String[] beforeCmds,
                    String[] afterCmds, Map<String, Object> bindingArgs, String validatorExpr,
                    Map<String, Object> validatorArgs) {
                final boolean prompt = isPrompt(beforeCmds, afterCmds);
                if (prompt) {
        Severity: Minor
        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 3 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method getValidator has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
        Open

            public Validator getValidator(String name) {
                checkInit();
                Validator validator = null;
                if (_hasGetValidatorMethod) {
                    Object vm = getViewModel();
        Severity: Minor
        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 3 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method getConverter has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
        Open

            public Converter getConverter(String name) {
                checkInit();
                Converter converter = null;
                if (_hasGetConverterMethod) {
                    Object vm = getViewModel();
        Severity: Minor
        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 3 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method addPropertyLoadBindings0 has 79 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            private void addPropertyLoadBindings0(Component comp, String attr, String loadExpr, String[] beforeCmds,
                    String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                    Map<String, Object> converterArgs) {
                final boolean prompt = isPrompt(beforeCmds, afterCmds);
                final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
        Severity: Major
        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 3 hrs to fix

          Method doValidate has 63 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              protected boolean doValidate(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
                  final Set<Property> validates = new HashSet<Property>();
                  String debugInfo = MessageFormat.format("doValidate "
                          + "comp=[{0}],command=[{1}],evt=[{2}],context=[{3}]", comp, command, evt, ctx);
                  try {
          Severity: Major
          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

            Method getCommandMethod has 62 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                private Method getCommandMethod(Class<?> clz, String command, CommandMethodInfoProvider cmdInfo,
                        Map<Class<?>, Map<String, CachedItem<Method>>> cache, int commandParamCount, boolean isGlobal) {
                    Map<String, CachedItem<Method>> methods;
                    Method matchedMethodWithoutAnno = null;
                    CachedItem<Method> method = null;
            Severity: Major
            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

              Method onEvent0 has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
              Open

                      private void onEvent0(Event event) throws Exception {
                          //command need to be confirmed shall be execute first!
                          //must sort the command sequence?
              
                          //BUG 619, event may come from children of some component, 
              Severity: Minor
              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              Method doExecute has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
              Open

                  protected void doExecute(Component comp, String command, Map<String, Object> commandArgs, BindContext ctx,
                          Set<Property> notifys) {
                      String debugInfo = MessageFormat.format("doExecute "
                              + "comp=[{0}],command=[{1}],notifys=[{2}]", comp, command, notifys);
                      try {
              Severity: Minor
              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              Method addFormAssociatedSaveBinding has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
              Open

                  public void addFormAssociatedSaveBinding(Component associatedComp, String formId, SaveBinding saveBinding,
                          String fieldName) {
                      checkInit();
                      //find the form component by form id and a associated/nested component
                      Component formComp = lookupAssociatedFormComponent(formId, associatedComp);
              Severity: Minor
              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              Method init has 55 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public void init(Component comp, Object viewModel, Map<String, Object> initArgs) {
                      if (_init)
                          throw new UiException("binder is already initialized");
                      _init = true;
                      
              Severity: Major
              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

                Method onEvent0 has 54 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        private void onEvent0(Event event) throws Exception {
                            //command need to be confirmed shall be execute first!
                            //must sort the command sequence?
                
                            //BUG 619, event may come from children of some component, 
                Severity: Major
                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

                  Method storeForm has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
                  Open

                      public void storeForm(Component comp, String id, Form form) {
                          final String oldid = (String) comp.getAttribute(FORM_ID, Component.COMPONENT_SCOPE);
                          //check if a form exist already, allow to store a form with same id again for replacing the form 
                          if (oldid != null && !oldid.equals(id)) {
                              throw new IllegalArgumentException(
                  Severity: Minor
                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Method loadComponentProperties0 has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
                  Open

                      private void loadComponentProperties0(Component comp, boolean loadinit) {
                  
                          final Map<String, List<Binding>> compBindings = _bindings.get(comp);
                          if (compBindings != null) { // if component is not registered in this binder, do nothing.
                              for (String key : compBindings.keySet()) {
                  Severity: Minor
                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 2 hrs to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Method addChildrenLoadBindings0 has 49 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      private void addChildrenLoadBindings0(Component comp, String loadExpr, String[] beforeCmds, String[] afterCmds,
                              Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
                          final boolean prompt = isPrompt(beforeCmds, afterCmds);
                          final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
                          if (prompt) {
                  Severity: Minor
                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                    Method doPropertyChange0 has 48 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        private void doPropertyChange0(Object base, String prop, Set<LoadBinding> bindings) {
                            Execution exec = Executions.getCurrent();
                            Set<Component> skipCheckChildren = (Set<Component>) exec.getAttribute(HtmlShadowElement.SKIP_DISTRIBUTED_CHILDREN_PROPERTY_CHANGE);
                            for (LoadBinding binding : bindings) {
                                //BUG 828, the sub-sequence binding might be removed after the previous loading.
                    Severity: Minor
                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                      Method addFormLoadBindings0 has 47 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          private void addFormLoadBindings0(Component comp, String formId, String loadExpr, String[] beforeCmds,
                                  String[] afterCmds, Map<String, Object> bindingArgs) {
                              final boolean prompt = isPrompt(beforeCmds, afterCmds);
                              final String attr = formId;
                              final BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
                      Severity: Minor
                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                        Method doExecute has 46 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            protected void doExecute(Component comp, String command, Map<String, Object> commandArgs, BindContext ctx,
                                    Set<Property> notifys) {
                                String debugInfo = MessageFormat.format("doExecute "
                                        + "comp=[{0}],command=[{1}],notifys=[{2}]", comp, command, notifys);
                                try {
                        Severity: Minor
                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                          Method addFormSaveBindings0 has 44 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              private void addFormSaveBindings0(Component comp, String formId, String saveExpr, String[] beforeCmds,
                                      String[] afterCmds, Map<String, Object> bindingArgs, String validatorExpr,
                                      Map<String, Object> validatorArgs) {
                                  final boolean prompt = isPrompt(beforeCmds, afterCmds);
                                  if (prompt) {
                          Severity: Minor
                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                            Method initRendererIfAny has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                private void initRendererIfAny(Component comp, String attr) {
                                    final Object installed = comp.getAttribute(BinderCtrl.RENDERER_INSTALLED);
                                    if (installed != null) { //renderer was set already init
                                        return;
                                    }
                            Severity: Minor
                            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                              Method addFormAssociatedSaveBinding has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  public void addFormAssociatedSaveBinding(Component associatedComp, String formId, SaveBinding saveBinding,
                                          String fieldName) {
                                      checkInit();
                                      //find the form component by form id and a associated/nested component
                                      Component formComp = lookupAssociatedFormComponent(formId, associatedComp);
                              Severity: Minor
                              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                Method getValidator has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    public Validator getValidator(String name) {
                                        checkInit();
                                        Validator validator = null;
                                        if (_hasGetValidatorMethod) {
                                            Object vm = getViewModel();
                                Severity: Minor
                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                  Method getConverter has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      public Converter getConverter(String name) {
                                          checkInit();
                                          Converter converter = null;
                                          if (_hasGetConverterMethod) {
                                              Object vm = getViewModel();
                                  Severity: Minor
                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                    Method doCommand has 37 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        private int doCommand(Component comp, CommandBinding commandBinding, String command, Event evt,
                                                Map<String, Object> commandArgs, Set<Property> notifys) {
                                            final String evtnm = evt == null ? null : evt.getName();
                                            String debugInfo = MessageFormat.format("doCommand "
                                                    + "comp=[{0}],command=[{1}],evtnm=[{2}]", comp, command, evtnm);
                                    Severity: Minor
                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                      Method storeForm has 37 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          public void storeForm(Component comp, String id, Form form) {
                                              final String oldid = (String) comp.getAttribute(FORM_ID, Component.COMPONENT_SCOPE);
                                              //check if a form exist already, allow to store a form with same id again for replacing the form 
                                              if (oldid != null && !oldid.equals(id)) {
                                                  throw new IllegalArgumentException(
                                      Severity: Minor
                                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                        Method newSavePropertyBinding has 11 arguments (exceeds 4 allowed). Consider refactoring.
                                        Open

                                            protected SavePropertyBinding newSavePropertyBinding(Component comp, String attr, String saveAttr, String saveExpr,
                                                    ConditionType conditionType, String command, Map<String, Object> bindingArgs, String converterExpr,
                                                    Map<String, Object> converterArgs, String validatorExpr, Map<String, Object> validatorArgs) {
                                        Severity: Major
                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                          Method doGlobalCommandExecute has 34 lines of code (exceeds 25 allowed). Consider refactoring.
                                          Open

                                              private void doGlobalCommandExecute(Component comp, String command, Map<String, Object> commandArgs,
                                                      BindContext ctx, Set<Property> notifys) {
                                                  String debugInfo = MessageFormat.format("doGlobalCommandExecute comp=[{0}],command=[{1}]", comp, command); 
                                                  try {
                                                      if (_log.isDebugEnabled()) {
                                          Severity: Minor
                                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                            Method newLoadPropertyBinding has 10 arguments (exceeds 4 allowed). Consider refactoring.
                                            Open

                                                protected LoadPropertyBinding newLoadPropertyBinding(Component comp, String attr, String loadAttr,
                                                        Class<?> attrType, String loadExpr, ConditionType conditionType, String command,
                                                        Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
                                            Severity: Major
                                            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                              Method addPropertySaveBindings0 has 10 arguments (exceeds 4 allowed). Consider refactoring.
                                              Open

                                                  private void addPropertySaveBindings0(Component comp, String attr, String saveExpr, String[] beforeCmds,
                                                          String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                                                          Map<String, Object> converterArgs, String validatorExpr, Map<String, Object> validatorArgs) {
                                              Severity: Major
                                              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                Method doGlobalCommandExecute has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                                                Open

                                                    private void doGlobalCommandExecute(Component comp, String command, Map<String, Object> commandArgs,
                                                            BindContext ctx, Set<Property> notifys) {
                                                        String debugInfo = MessageFormat.format("doGlobalCommandExecute comp=[{0}],command=[{1}]", comp, command); 
                                                        try {
                                                            if (_log.isDebugEnabled()) {
                                                Severity: Minor
                                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                Cognitive Complexity

                                                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                A method's cognitive complexity is based on a few simple rules:

                                                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                • Code is considered more complex for each "break in the linear flow of the code"
                                                • Code is considered more complex when "flow breaking structures are nested"

                                                Further reading

                                                Method addPropertySaveBindings has 10 arguments (exceeds 4 allowed). Consider refactoring.
                                                Open

                                                    public void addPropertySaveBindings(Component comp, String attr, String saveExpr, String[] beforeCmds,
                                                            String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                                                            Map<String, Object> converterArgs, String validatorExpr, Map<String, Object> validatorArgs) {
                                                Severity: Major
                                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                  Method initMatchMediaValues has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                                                  Open

                                                      private Map<String, Method> initMatchMediaValues(Object viewModel) {
                                                          Map<String, Method> values = new HashMap<>(6);
                                                          for (Method m : BindUtils.getViewModelClass(viewModel).getMethods()) {
                                                              MatchMedia annomm = ViewModelAnnotationResolvers.getAnnotation(m, MatchMedia.class);
                                                              if (annomm != null) {
                                                  Severity: Minor
                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                  Cognitive Complexity

                                                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                  A method's cognitive complexity is based on a few simple rules:

                                                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                  • Code is considered more complex for each "break in the linear flow of the code"
                                                  • Code is considered more complex when "flow breaking structures are nested"

                                                  Further reading

                                                  Method loadComponent0 has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                                                  Open

                                                      protected void loadComponent0(Component comp, boolean loadinit) {
                                                          loadComponentProperties0(comp, loadinit);
                                                  
                                                          final Map<String, List<Binding>> compBindings = _bindings.get(comp);
                                                          if (_activating || compBindings == null || !compBindings.keySet().contains(CHILDREN_ATTR)) {
                                                  Severity: Minor
                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                  Cognitive Complexity

                                                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                  A method's cognitive complexity is based on a few simple rules:

                                                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                  • Code is considered more complex for each "break in the linear flow of the code"
                                                  • Code is considered more complex when "flow breaking structures are nested"

                                                  Further reading

                                                  Method doPropertyChange has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                                                  Open

                                                      private void doPropertyChange(Object base, String prop) {
                                                          String debugInfo = MessageFormat.format("doPropertyChange: base=[{0}],prop=[{1}]", base, prop);
                                                          if (_log.isDebugEnabled()) {
                                                              _log.debug(debugInfo);
                                                          }
                                                  Severity: Minor
                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                  Cognitive Complexity

                                                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                  A method's cognitive complexity is based on a few simple rules:

                                                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                  • Code is considered more complex for each "break in the linear flow of the code"
                                                  • Code is considered more complex when "flow breaking structures are nested"

                                                  Further reading

                                                  Method addPropertyInitBinding0 has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                                                  Open

                                                      private void addPropertyInitBinding0(Component comp, String attr, String initExpr, Map<String, Object> bindingArgs,
                                                              String converterExpr, Map<String, Object> converterArgs) {
                                                  
                                                          final ComponentCtrl compCtrl = (ComponentCtrl) comp;
                                                          final Annotation ann = AnnotationUtil.getSystemAnnotation(compCtrl, attr);
                                                  Severity: Minor
                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                    Method removeBindings0 has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                                    Open

                                                        private void removeBindings0(Component comp) {
                                                            checkInit();
                                                            if (_rootComp == comp) {
                                                                //the binder component was detached, unregister queue
                                                                unsubscribeQueue(_quename, _quescope, _queueListener);
                                                    Severity: Minor
                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                      Method doPropertyChange has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                                      Open

                                                          private void doPropertyChange(Object base, String prop) {
                                                              String debugInfo = MessageFormat.format("doPropertyChange: base=[{0}],prop=[{1}]", base, prop);
                                                              if (_log.isDebugEnabled()) {
                                                                  _log.debug(debugInfo);
                                                              }
                                                      Severity: Minor
                                                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                        Method collectNotifyCommands has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
                                                        Open

                                                            private void collectNotifyCommands(Object vm) {
                                                                Class<?> viewModelClz = BindUtils.getViewModelClass(vm);
                                                                NotifyCommands commands = ViewModelAnnotationResolvers.getAnnotation(viewModelClz, NotifyCommands.class);
                                                                NotifyCommand command = ViewModelAnnotationResolvers.getAnnotation(viewModelClz, NotifyCommand.class);
                                                                if (_notifyCommands != null)
                                                        Severity: Minor
                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                        Cognitive Complexity

                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                        A method's cognitive complexity is based on a few simple rules:

                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                        Further reading

                                                        Method handleNotifyChange has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
                                                        Open

                                                            static void handleNotifyChange(BindContext ctx, Object viewModel,
                                                                                                     Method method, ParamCall parCall,
                                                                                                     Set<Property> notifys) {
                                                                final SmartNotifyChange sannt = ViewModelAnnotationResolvers.getAnnotation(method, SmartNotifyChange.class);
                                                                Object originViewModel = getOriginViewModel(viewModel);
                                                        Severity: Minor
                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                        Cognitive Complexity

                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                        A method's cognitive complexity is based on a few simple rules:

                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                        Further reading

                                                        Method addFormSaveBindings0 has 8 arguments (exceeds 4 allowed). Consider refactoring.
                                                        Open

                                                            private void addFormSaveBindings0(Component comp, String formId, String saveExpr, String[] beforeCmds,
                                                                    String[] afterCmds, Map<String, Object> bindingArgs, String validatorExpr,
                                                                    Map<String, Object> validatorArgs) {
                                                        Severity: Major
                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                          Method newSaveFormBinding has 8 arguments (exceeds 4 allowed). Consider refactoring.
                                                          Open

                                                              protected SaveFormBinding newSaveFormBinding(Component comp, String formId, String saveExpr,
                                                                      ConditionType conditionType, String command, Map<String, Object> bindingArgs, String validatorExpr,
                                                                      Map<String, Object> validatorArgs) {
                                                          Severity: Major
                                                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                            Method addPropertyLoadBindings0 has 8 arguments (exceeds 4 allowed). Consider refactoring.
                                                            Open

                                                                private void addPropertyLoadBindings0(Component comp, String attr, String loadExpr, String[] beforeCmds,
                                                                        String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                                                                        Map<String, Object> converterArgs) {
                                                            Severity: Major
                                                            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                              Method newInitPropertyBinding has 8 arguments (exceeds 4 allowed). Consider refactoring.
                                                              Open

                                                                  protected InitPropertyBinding newInitPropertyBinding(Component comp, String attr, String loadAttr,
                                                                          Class<?> attrType, String initExpr, Map<String, Object> bindingArgs, String converterExpr,
                                                                          Map<String, Object> converterArgs) {
                                                              Severity: Major
                                                              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                                Method addFormSaveBindings has 8 arguments (exceeds 4 allowed). Consider refactoring.
                                                                Open

                                                                    public void addFormSaveBindings(Component comp, String id, String saveExpr, String[] beforeCmds, String[] afterCmds,
                                                                            Map<String, Object> bindingArgs, String validatorExpr, Map<String, Object> validatorArgs) {
                                                                Severity: Major
                                                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                                  Method addPropertyLoadBindings has 8 arguments (exceeds 4 allowed). Consider refactoring.
                                                                  Open

                                                                      public void addPropertyLoadBindings(Component comp, String attr, String loadExpr, String[] beforeCmds,
                                                                              String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                                                                              Map<String, Object> converterArgs) {
                                                                  Severity: Major
                                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 1 hr to fix

                                                                    Method sendCommand has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                                    Open

                                                                        public int sendCommand(String command, Map<String, Object> args) {
                                                                            checkInit();
                                                                            final Set<Property> notifys = new HashSet<Property>();
                                                                            Event evt = null;
                                                                            //ZK-3133
                                                                    Severity: Minor
                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 55 mins to fix

                                                                    Cognitive Complexity

                                                                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                    A method's cognitive complexity is based on a few simple rules:

                                                                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                    • Code is considered more complex for each "break in the linear flow of the code"
                                                                    • Code is considered more complex when "flow breaking structures are nested"

                                                                    Further reading

                                                                    Method removeBindings0 has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                                    Open

                                                                        private void removeBindings0(Component comp) {
                                                                            checkInit();
                                                                            if (_rootComp == comp) {
                                                                                //the binder component was detached, unregister queue
                                                                                unsubscribeQueue(_quename, _quescope, _queueListener);
                                                                    Severity: Minor
                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 55 mins to fix

                                                                    Cognitive Complexity

                                                                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                    A method's cognitive complexity is based on a few simple rules:

                                                                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                    • Code is considered more complex for each "break in the linear flow of the code"
                                                                    • Code is considered more complex when "flow breaking structures are nested"

                                                                    Further reading

                                                                    Method addPropertyInitBinding0 has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                                    Open

                                                                        private void addPropertyInitBinding0(Component comp, String attr, String initExpr, Map<String, Object> bindingArgs,
                                                                                String converterExpr, Map<String, Object> converterArgs) {
                                                                    
                                                                            final ComponentCtrl compCtrl = (ComponentCtrl) comp;
                                                                            final Annotation ann = AnnotationUtil.getSystemAnnotation(compCtrl, attr);
                                                                    Severity: Minor
                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 55 mins to fix

                                                                    Cognitive Complexity

                                                                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                    A method's cognitive complexity is based on a few simple rules:

                                                                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                    • Code is considered more complex for each "break in the linear flow of the code"
                                                                    • Code is considered more complex when "flow breaking structures are nested"

                                                                    Further reading

                                                                    Method newLoadChildrenBinding has 7 arguments (exceeds 4 allowed). Consider refactoring.
                                                                    Open

                                                                        protected LoadChildrenBinding newLoadChildrenBinding(Component comp, String loadExpr, ConditionType conditionType,
                                                                                String command, Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
                                                                    Severity: Major
                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 50 mins to fix

                                                                      Method addChildrenLoadBindings has 7 arguments (exceeds 4 allowed). Consider refactoring.
                                                                      Open

                                                                          public void addChildrenLoadBindings(Component comp, String loadExpr, String[] beforeCmds, String[] afterCmds,
                                                                                  Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
                                                                      Severity: Major
                                                                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 50 mins to fix

                                                                        Method addChildrenLoadBindings0 has 7 arguments (exceeds 4 allowed). Consider refactoring.
                                                                        Open

                                                                            private void addChildrenLoadBindings0(Component comp, String loadExpr, String[] beforeCmds, String[] afterCmds,
                                                                                    Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
                                                                        Severity: Major
                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 50 mins to fix

                                                                          Avoid deeply nested control flow statements.
                                                                          Open

                                                                                                          if (wve != null) {
                                                                                                              Component c = wve.getComponent();
                                                                                                              if (c == null)
                                                                                                                  c = wvc;
                                                                                                              Clients.wrongValue(c, wve.getMessage());
                                                                          Severity: Major
                                                                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                            Avoid deeply nested control flow statements.
                                                                            Open

                                                                                                    if (renderer instanceof TemplateRendererCtrl) {
                                                                                                        ((TemplateRendererCtrl) renderer).setAttributeName(attr);
                                                                                                    }
                                                                            Severity: Major
                                                                            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                              Method addFormLoadBindings has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                              Open

                                                                                  public void addFormLoadBindings(Component comp, String id, String loadExpr, String[] beforeCmds, String[] afterCmds,
                                                                                          Map<String, Object> bindingArgs) {
                                                                              Severity: Minor
                                                                              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                Method doCommand has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                Open

                                                                                    private int doCommand(Component comp, CommandBinding commandBinding, String command, Event evt,
                                                                                            Map<String, Object> commandArgs, Set<Property> notifys) {
                                                                                Severity: Minor
                                                                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                  Method addPropertyInitBinding0 has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                  Open

                                                                                      private void addPropertyInitBinding0(Component comp, String attr, String initExpr, Map<String, Object> bindingArgs,
                                                                                              String converterExpr, Map<String, Object> converterArgs) {
                                                                                  Severity: Minor
                                                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                    Method addPropertyInitBinding has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                    Open

                                                                                        public void addPropertyInitBinding(Component comp, String attr, String initExpr, Map<String, Object> initArgs,
                                                                                                String converterExpr, Map<String, Object> converterArgs) {
                                                                                    Severity: Minor
                                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                      Avoid deeply nested control flow statements.
                                                                                      Open

                                                                                                              if (matchMedias != null && args.size() != 0) {
                                                                                                                  if (!matchMedias[0].isEmpty()) {
                                                                                                                      for (String s : matchMedias) {
                                                                                                                          if (!_matchMediaValues.containsKey(s))
                                                                                                                              continue;
                                                                                      Severity: Major
                                                                                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                        Method addFormLoadBindings0 has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                        Open

                                                                                            private void addFormLoadBindings0(Component comp, String formId, String loadExpr, String[] beforeCmds,
                                                                                                    String[] afterCmds, Map<String, Object> bindingArgs) {
                                                                                        Severity: Minor
                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                          Method getLoadPromptBindings has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                                                          Open

                                                                                              public List<Binding> getLoadPromptBindings(Component comp, String attr) {
                                                                                                  checkInit();
                                                                                                  final List<Binding> bindings = new ArrayList<Binding>();
                                                                                                  final BindingKey bkey = getBindingKey(comp, attr);
                                                                                                  final List<LoadPropertyBinding> loadBindings = _propertyBindingHandler.getLoadPromptBindings(bkey);
                                                                                          Severity: Minor
                                                                                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                          Cognitive Complexity

                                                                                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                                          A method's cognitive complexity is based on a few simple rules:

                                                                                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                                          • Code is considered more complex for each "break in the linear flow of the code"
                                                                                          • Code is considered more complex when "flow breaking structures are nested"

                                                                                          Further reading

                                                                                          Method newLoadFormBinding has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                          Open

                                                                                              protected LoadFormBinding newLoadFormBinding(Component comp, String formId, String loadExpr,
                                                                                                      ConditionType conditionType, String command, Map<String, Object> bindingArgs) {
                                                                                          Severity: Minor
                                                                                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                            Method getCommandMethod has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                            Open

                                                                                                private Method getCommandMethod(Class<?> clz, String command, CommandMethodInfoProvider cmdInfo,
                                                                                                        Map<Class<?>, Map<String, CachedItem<Method>>> cache, int commandParamCount, boolean isGlobal) {
                                                                                            Severity: Minor
                                                                                            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                              Avoid deeply nested control flow statements.
                                                                                              Open

                                                                                                                      if ("ZKMatchMedia".equals(name)) {
                                                                                                                          matchMedias = value.trim().split(",");
                                                                                                                      } else if ("ZKClientInfo".equals(name)) {
                                                                                                                          args.put(BinderCtrl.CLIENT_INFO, JSONValue.parse(value));
                                                                                                                      }
                                                                                              Severity: Major
                                                                                              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 45 mins to fix

                                                                                                Method postGlobalCommand has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                Open

                                                                                                    private void postGlobalCommand(Component comp, CommandBinding commandBinding, String command, Event evt,
                                                                                                            Map<String, Object> args) {
                                                                                                Severity: Minor
                                                                                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                  Method addChildrenInitBinding has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                  Open

                                                                                                      public void addChildrenInitBinding(Component comp, String initExpr, Map<String, Object> initArgs,
                                                                                                              String converterExpr, Map<String, Object> converterArgs) {
                                                                                                  Severity: Minor
                                                                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                    Method addChildrenInitBinding0 has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                    Open

                                                                                                        private void addChildrenInitBinding0(Component comp, String initExpr, Map<String, Object> bindingArgs,
                                                                                                                String converterExpr, Map<String, Object> converterArgs) {
                                                                                                    Severity: Minor
                                                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                      Method newInitChildrenBinding has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                      Open

                                                                                                          protected InitChildrenBinding newInitChildrenBinding(Component comp, String initExpr,
                                                                                                                  Map<String, Object> bindingArgs, String converterExpr, Map<String, Object> converterArgs) {
                                                                                                      Severity: Minor
                                                                                                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                        Method doSaveAfter has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                        Open

                                                                                                            protected void doSaveAfter(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
                                                                                                        Severity: Minor
                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                          Method doExecute has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                          Open

                                                                                                              protected void doExecute(Component comp, String command, Map<String, Object> commandArgs, BindContext ctx,
                                                                                                                      Set<Property> notifys) {
                                                                                                          Severity: Minor
                                                                                                          Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                            Method handleNotifyChange has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                            Open

                                                                                                                static void handleNotifyChange(BindContext ctx, Object viewModel,
                                                                                                                                                         Method method, ParamCall parCall,
                                                                                                                                                         Set<Property> notifys) {
                                                                                                            Severity: Minor
                                                                                                            Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                              Method doSaveBefore has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                              Open

                                                                                                                  protected void doSaveBefore(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
                                                                                                              Severity: Minor
                                                                                                              Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                                Method doGlobalCommand has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                                Open

                                                                                                                    private void doGlobalCommand(Component comp, String command, Event evt, Map<String, Object> commandArgs,
                                                                                                                            Set<Property> notifys) {
                                                                                                                Severity: Minor
                                                                                                                Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                                  Method doValidate has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                                  Open

                                                                                                                      protected boolean doValidate(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
                                                                                                                  Severity: Minor
                                                                                                                  Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                                    Method newTemplateResolverImpl has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                                    Open

                                                                                                                        private TemplateResolver newTemplateResolverImpl(BinderImpl binderImpl, Component comp, String attr,
                                                                                                                                String templateExpr, Map<String, Object> templateArgs) {
                                                                                                                    Severity: Minor
                                                                                                                    Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                                      Method doGlobalCommandExecute has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                                                      Open

                                                                                                                          private void doGlobalCommandExecute(Component comp, String command, Map<String, Object> commandArgs,
                                                                                                                                  BindContext ctx, Set<Property> notifys) {
                                                                                                                      Severity: Minor
                                                                                                                      Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                                        Method addPropertySaveBindings has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                                                                                                        Open

                                                                                                                            public void addPropertySaveBindings(Component comp, String attr, String saveExpr, String[] beforeCmds,
                                                                                                                                    String[] afterCmds, Map<String, Object> bindingArgs, String converterExpr,
                                                                                                                                    Map<String, Object> converterArgs, String validatorExpr, Map<String, Object> validatorArgs) {
                                                                                                                                checkInit();
                                                                                                                                if (saveExpr == null) {
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 35 mins to fix

                                                                                                                        Cognitive Complexity

                                                                                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                                                                        A method's cognitive complexity is based on a few simple rules:

                                                                                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                                                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                                                                                        Further reading

                                                                                                                        Method removeBindings has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                                                                                                                        Open

                                                                                                                            public void removeBindings(Component comp, String key) {
                                                                                                                                checkInit();
                                                                                                                                removeEventCommandListenerIfExists(comp, key); //_listenerMap; //comp+evtnm -> eventlistener
                                                                                                                                
                                                                                                                                final BindingKey bkey = getBindingKey(comp, key);
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 25 mins to fix

                                                                                                                        Cognitive Complexity

                                                                                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                                                                        A method's cognitive complexity is based on a few simple rules:

                                                                                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                                                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                                                                                        Further reading

                                                                                                                        Method doCommand has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                                                                                                                        Open

                                                                                                                            private int doCommand(Component comp, CommandBinding commandBinding, String command, Event evt,
                                                                                                                                    Map<String, Object> commandArgs, Set<Property> notifys) {
                                                                                                                                final String evtnm = evt == null ? null : evt.getName();
                                                                                                                                String debugInfo = MessageFormat.format("doCommand "
                                                                                                                                        + "comp=[{0}],command=[{1}],evtnm=[{2}]", comp, command, evtnm);
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 25 mins to fix

                                                                                                                        Cognitive Complexity

                                                                                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                                                                        A method's cognitive complexity is based on a few simple rules:

                                                                                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                                                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                                                                                        Further reading

                                                                                                                        Method getTracker has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                                                                                                                        Open

                                                                                                                            @SuppressWarnings("unchecked")
                                                                                                                            public Tracker getTracker() {
                                                                                                                                if (_tracker == null) {
                                                                                                                                    String clznm = Library.getProperty("org.zkoss.bind.Tracker.class");
                                                                                                                                    if (clznm != null) {
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 25 mins to fix

                                                                                                                        Cognitive Complexity

                                                                                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                                                                        A method's cognitive complexity is based on a few simple rules:

                                                                                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                                                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                                                                                        Further reading

                                                                                                                        Method getRenderer has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                                                                                                                        Open

                                                                                                                            protected Object getRenderer(String name) {
                                                                                                                                Object renderer = RENDERERS.get(name);
                                                                                                                                if (renderer == null && name.indexOf('.') > 0) { //might be a class path
                                                                                                                                    try {
                                                                                                                                        renderer = Classes.newInstanceByThread(name);
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java - About 25 mins to fix

                                                                                                                        Cognitive Complexity

                                                                                                                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                                                                                                        A method's cognitive complexity is based on a few simple rules:

                                                                                                                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                                                                                                        • Code is considered more complex for each "break in the linear flow of the code"
                                                                                                                        • Code is considered more complex when "flow breaking structures are nested"

                                                                                                                        Further reading

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

                                                                                                                            public Validator getValidator(String name) {
                                                                                                                                checkInit();
                                                                                                                                Validator validator = null;
                                                                                                                                if (_hasGetValidatorMethod) {
                                                                                                                                    Object vm = getViewModel();
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 4 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 595..634

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                            public Converter getConverter(String name) {
                                                                                                                                checkInit();
                                                                                                                                Converter converter = null;
                                                                                                                                if (_hasGetConverterMethod) {
                                                                                                                                    Object vm = getViewModel();
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 4 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 637..676

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

                                                                                                                        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 (beforeCmds != null && beforeCmds.length > 0) {
                                                                                                                                        for (String cmd : beforeCmds) {
                                                                                                                                            final SavePropertyBinding binding = newSavePropertyBinding(comp, attr, saveRep, saveExpr,
                                                                                                                                                    ConditionType.BEFORE_COMMAND, cmd, bindingArgs, converterExpr, converterArgs, validatorExpr,
                                                                                                                                                    validatorArgs);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1375..1393

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

                                                                                                                        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 (afterCmds != null && afterCmds.length > 0) {
                                                                                                                                        for (String cmd : afterCmds) {
                                                                                                                                            final SavePropertyBinding binding = newSavePropertyBinding(comp, attr, saveRep, saveExpr,
                                                                                                                                                    ConditionType.AFTER_COMMAND, cmd, bindingArgs, converterExpr, converterArgs, validatorExpr,
                                                                                                                                                    validatorArgs);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1356..1374

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

                                                                                                                        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 (beforeCmds != null && beforeCmds.length > 0) {
                                                                                                                                        for (String cmd : beforeCmds) {
                                                                                                                                            LoadPropertyBinding binding = newLoadPropertyBinding(comp, attr, loadRep, attrType, loadExpr,
                                                                                                                                                    ConditionType.BEFORE_COMMAND, cmd, bindingArgs, converterExpr, converterArgs);
                                                                                                                                            addBinding(comp, attr, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1277..1293

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

                                                                                                                        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 (afterCmds != null && afterCmds.length > 0) {
                                                                                                                                        for (String cmd : afterCmds) {
                                                                                                                                            LoadPropertyBinding binding = newLoadPropertyBinding(comp, attr, loadRep, attrType, loadExpr,
                                                                                                                                                    ConditionType.AFTER_COMMAND, cmd, bindingArgs, converterExpr, converterArgs);
                                                                                                                                            addBinding(comp, attr, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1260..1276

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

                                                                                                                        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 (beforeCmds != null && beforeCmds.length > 0) {
                                                                                                                                    for (String cmd : beforeCmds) {
                                                                                                                                        final SaveFormBinding binding = newSaveFormBinding(comp, formId, saveExpr, ConditionType.BEFORE_COMMAND,
                                                                                                                                                cmd, bindingArgs, validatorExpr, validatorArgs);
                                                                                                                                        addBinding(comp, formId, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 917..933

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

                                                                                                                        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 (afterCmds != null && afterCmds.length > 0) {
                                                                                                                                    for (String cmd : afterCmds) {
                                                                                                                                        final SaveFormBinding binding = newSaveFormBinding(comp, formId, saveExpr, ConditionType.AFTER_COMMAND,
                                                                                                                                                cmd, bindingArgs, validatorExpr, validatorArgs);
                                                                                                                                        addBinding(comp, formId, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 900..916

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

                                                                                                                        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 (afterCmds != null && afterCmds.length > 0) {
                                                                                                                                        for (String cmd : afterCmds) {
                                                                                                                                            LoadChildrenBindingImpl binding = new LoadChildrenBindingImpl(this, comp, loadExpr,
                                                                                                                                                    ConditionType.AFTER_COMMAND, cmd, bindingArgs, converterExpr, converterArgs);
                                                                                                                                            addBinding(comp, CHILDREN_ATTR, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1466..1482

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

                                                                                                                        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 (beforeCmds != null && beforeCmds.length > 0) {
                                                                                                                                        for (String cmd : beforeCmds) {
                                                                                                                                            LoadChildrenBindingImpl binding = new LoadChildrenBindingImpl(this, comp, loadExpr,
                                                                                                                                                    ConditionType.BEFORE_COMMAND, cmd, bindingArgs, converterExpr, converterArgs);
                                                                                                                                            addBinding(comp, CHILDREN_ATTR, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1483..1499

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

                                                                                                                        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 (beforeCmds != null && beforeCmds.length > 0) {
                                                                                                                                        for (String cmd : beforeCmds) {
                                                                                                                                            final LoadFormBinding binding = newLoadFormBinding(comp, formId, loadExpr,
                                                                                                                                                    ConditionType.BEFORE_COMMAND, cmd, bindingArgs);
                                                                                                                                            addBinding(comp, attr, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 871..887

                                                                                                                        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

                                                                                                                                    if (afterCmds != null && afterCmds.length > 0) {
                                                                                                                                        for (String cmd : afterCmds) {
                                                                                                                                            final LoadFormBinding binding = newLoadFormBinding(comp, formId, loadExpr,
                                                                                                                                                    ConditionType.AFTER_COMMAND, cmd, bindingArgs);
                                                                                                                                            addBinding(comp, attr, binding);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 2 hrs to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 854..870

                                                                                                                        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

                                                                                                                            protected void doSaveAfter(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
                                                                                                                                String debugInfo = MessageFormat.format("doSaveAfter "
                                                                                                                                        + "comp=[{0}],command=[{1}],evt=[{2}],notifys=[{3}]", comp, command, evt, notifys);
                                                                                                                                if (_log.isDebugEnabled()) {
                                                                                                                                    _log.debug(debugInfo);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2240..2255

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

                                                                                                                        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

                                                                                                                            protected void doSaveBefore(Component comp, String command, Event evt, BindContext ctx, Set<Property> notifys) {
                                                                                                                                String debugInfo = MessageFormat.format("doSaveBefore "
                                                                                                                                        + "comp=[{0}],command=[{1}],evt=[{2}],notifys=[{3}]", comp, command, evt, notifys);
                                                                                                                                if (_log.isDebugEnabled()) {
                                                                                                                                    _log.debug(debugInfo);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2257..2273

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

                                                                                                                        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

                                                                                                                            protected void doLoadAfter(Component comp, String command, BindContext ctx) {
                                                                                                                                String debugInfo = MessageFormat.format("doLoadAfter comp=[{0}],command=[{1}]", comp, command);
                                                                                                                                if (_log.isDebugEnabled()) {
                                                                                                                                    _log.debug(debugInfo);
                                                                                                                                }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2275..2290

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

                                                                                                                        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

                                                                                                                            protected void doLoadBefore(Component comp, String command, BindContext ctx) {
                                                                                                                                String debugInfo = MessageFormat.format("doLoadBefore comp=[{0}],command=[{1}]", comp, command);
                                                                                                                                if (_log.isDebugEnabled()) {
                                                                                                                                    _log.debug(debugInfo);
                                                                                                                                }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2292..2308

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                            public void addGlobalCommandBinding(Component comp, String evtnm, String commandExpr, Map<String, Object> args) {
                                                                                                                                checkInit();
                                                                                                                                final CommandBinding binding = newCommandBinding(comp, evtnm, commandExpr, args);
                                                                                                                                addBinding(comp, evtnm, binding);
                                                                                                                                registerCommandEventListener(comp, evtnm, binding, true);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1538..1549

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                            public void addCommandBinding(Component comp, String evtnm, String commandExpr, Map<String, Object> args) {
                                                                                                                                checkInit();
                                                                                                                                final CommandBinding binding = newCommandBinding(comp, evtnm, commandExpr, args);
                                                                                                                                addBinding(comp, evtnm, binding);
                                                                                                                                registerCommandEventListener(comp, evtnm, binding, false);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1551..1562

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                    if (method != null) {
                                                                                                                        
                                                                                                                                        BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
                                                                                                                                        if (collector != null) {
                                                                                                                                            collector.addInfo(new CommandInfo(CommandInfo.EXECUTE, comp, null, null, command, commandArgs,
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1898..1911

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                    if (method != null) {
                                                                                                                        
                                                                                                                                        BindingExecutionInfoCollector collector = getBindingExecutionInfoCollector();
                                                                                                                                        if (collector != null) {
                                                                                                                                            collector.addInfo(new CommandInfo(CommandInfo.EXECUTE_GLOBAL, comp, null, null, command,
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2125..2138

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

                                                                                                                        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

                                                                                                                            private static final CommandMethodInfoProvider _commandMethodInfoProvider = new CommandMethodInfoProvider() {
                                                                                                                                public String getAnnotationName() {
                                                                                                                                    return Command.class.getSimpleName();
                                                                                                                                }
                                                                                                                        
                                                                                                                        
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 200..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 76.

                                                                                                                        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

                                                                                                                            private static final CommandMethodInfoProvider _globalCommandMethodInfoProvider = new CommandMethodInfoProvider() {
                                                                                                                                public String getAnnotationName() {
                                                                                                                                    return GlobalCommand.class.getSimpleName();
                                                                                                                                }
                                                                                                                        
                                                                                                                        
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 182..199

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                            public BindingAnnotationInfoChecker getBindingAnnotationInfoChecker() {
                                                                                                                                DebuggerFactory factory = DebuggerFactory.getInstance();
                                                                                                                                if (factory == null) return null;
                                                                                                                                // ZK-5048: setViewModelClass for MVVM DebuggerFactory to log via SLF4J
                                                                                                                                BindingAnnotationInfoChecker checker = factory.getAnnotationInfoChecker();
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2861..2871

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                            public BindingExecutionInfoCollector getBindingExecutionInfoCollector() {
                                                                                                                                DebuggerFactory factory = DebuggerFactory.getInstance();
                                                                                                                                if (factory == null) return null;
                                                                                                                                // ZK-5048: setViewModelClass for MVVM DebuggerFactory to log via SLF4J
                                                                                                                                BindingExecutionInfoCollector collector = factory.getExecutionInfoCollector();
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2873..2883

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

                                                                                                                        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

                                                                                                                            private String getSystemValidator(Component comp, String attr) {
                                                                                                                                final ComponentCtrl compCtrl = (ComponentCtrl) comp;
                                                                                                                                final Annotation ann = AnnotationUtil.getSystemAnnotation(compCtrl, attr);
                                                                                                                                if (ann != null) {
                                                                                                                                    final Map<String, String[]> attrs = ann.getAttributes(); //(tag, tagExpr)
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1048..1056

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

                                                                                                                        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

                                                                                                                            private String getSystemConverter(Component comp, String attr) {
                                                                                                                                final ComponentCtrl compCtrl = (ComponentCtrl) comp;
                                                                                                                                final Annotation ann = AnnotationUtil.getSystemAnnotation(compCtrl, attr);
                                                                                                                                if (ann != null) {
                                                                                                                                    final Map<String, String[]> attrs = ann.getAttributes(); //(tag, tagExpr)
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 1 hr to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1058..1066

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

                                                                                                                        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

                                                                                                                                    try {
                                                                                                                                        if (_log.isDebugEnabled()) {
                                                                                                                                            _log.debug(debugInfo);
                                                                                                                                        }
                                                                                                                                        doPrePhase(Phase.LOAD_BINDING, ctx);
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 3 other locations - About 50 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/ChildrenBindingHandler.java on lines 92..102
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/FormBindingHandler.java on lines 109..119
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/PropertyBindingHandler.java on lines 110..120

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

                                                                                                                            public void addSaveFormFieldName(Form form, String fieldName) {
                                                                                                                                Set<String> fields = initSaveFormMap().get(form);
                                                                                                                                if (fields == null) {
                                                                                                                                    fields = new HashSet<String>(16);
                                                                                                                                    _saveFormFields.put(form, fields);
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 45 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2916..2924

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                            public void addSaveFormFieldName(Form form, Set<String> fieldNames) {
                                                                                                                                Set<String> fields = initSaveFormMap().get(form);
                                                                                                                                if (fields == null) {
                                                                                                                                    fields = new HashSet<String>(16);
                                                                                                                                    _saveFormFields.put(form, fields);
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 45 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2907..2914

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

                                                                                                                        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

                                                                                                                                    for (String key : compBindings.keySet()) {
                                                                                                                                        final BindingKey bkey = getBindingKey(comp, key);
                                                                                                                                        if (loadinit) {
                                                                                                                                            _formBindingHandler.doInit(comp, bkey);
                                                                                                                                        }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 2 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2593..2599
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2600..2607

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

                                                                                                                        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

                                                                                                                                    for (String key : compBindings.keySet()) {
                                                                                                                                        final BindingKey bkey = getBindingKey(comp, key);
                                                                                                                                        if (loadinit) {
                                                                                                                                            _propertyBindingHandler.doInit(comp, bkey);
                                                                                                                                        }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 2 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2586..2592
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2600..2607

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

                                                                                                                        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

                                                                                                                                    for (String key : compBindings.keySet()) {
                                                                                                                                        final BindingKey bkey = getBindingKey(comp, key);
                                                                                                                                        if (loadinit) {
                                                                                                                                            _childrenBindingHandler.doInit(comp, bkey);
                                                                                                                                        }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 2 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2586..2592
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 2593..2599

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

                                                                                                                        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

                                                                                                                                if (Strings.isBlank(converterExpr)) {
                                                                                                                                    converterExpr = getSystemConverter(comp, attr);
                                                                                                                                    if (converterExpr != null) {
                                                                                                                                        converterExpr = "'" + converterExpr + "'";
                                                                                                                                    }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 3 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 949..954
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 990..995
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 996..1001

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

                                                                                                                        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

                                                                                                                                if (Strings.isBlank(converterExpr)) {
                                                                                                                                    converterExpr = getSystemConverter(comp, attr);
                                                                                                                                    if (converterExpr != null) {
                                                                                                                                        converterExpr = "'" + converterExpr + "'";
                                                                                                                                    }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 3 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 969..974
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 990..995
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 996..1001

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

                                                                                                                        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

                                                                                                                                if (Strings.isBlank(converterExpr)) {
                                                                                                                                    converterExpr = getSystemConverter(comp, attr);
                                                                                                                                    if (converterExpr != null) {
                                                                                                                                        converterExpr = "'" + converterExpr + "'";
                                                                                                                                    }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 3 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 949..954
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 969..974
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 996..1001

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

                                                                                                                        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 (evtnm == null) {
                                                                                                                                    //no trigger event, since the value never change of component, so both prompt and command are useless
                                                                                                                                    if (BinderUtil.hasContext() && BinderUtil.getContext().isIgnoreAccessCreationWarn()) {
                                                                                                                                        return;
                                                                                                                                    }
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1313..1320

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

                                                                                                                        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

                                                                                                                                if (Strings.isBlank(validatorExpr)) {
                                                                                                                                    validatorExpr = getSystemValidator(comp, attr);
                                                                                                                                    if (validatorExpr != null) {
                                                                                                                                        validatorExpr = "'" + validatorExpr + "'";
                                                                                                                                    }
                                                                                                                        Severity: Major
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 3 other locations - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 949..954
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 969..974
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 990..995

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

                                                                                                                        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 (!"both".equals(rw) && !"save".equals(rw)) { //load only, skip
                                                                                                                                        if (BinderUtil.hasContext() && BinderUtil.getContext().isIgnoreAccessCreationWarn()) {
                                                                                                                                            return;
                                                                                                                                        }
                                                                                                                                        _log.warn(MiscUtil.formatLocationMessage(
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 40 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1325..1333

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                        if (binding instanceof PropertyBinding) {
                                                                                                                                            attr = ((PropertyBinding) binding).getFieldName();
                                                                                                                                        } else if (binding instanceof FormBinding) {
                                                                                                                                            attr = ((FormBinding) binding).getFormId();
                                                                                                                                        } else {
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 35 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/validator/AbstractValidator.java on lines 100..106

                                                                                                                        Duplicated Code

                                                                                                                        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                                                                                                                        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                                                                                                                        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                                                                                                                        Tuning

                                                                                                                        This issue has a mass of 46.

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                    if (type != null) {
                                                                                                                                        try {
                                                                                                                                            attrType = Classes.forNameByThread(type);
                                                                                                                                        } catch (ClassNotFoundException e) {
                                                                                                                                            throw UiException.Aide.wrap(e, e.getMessage());
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 35 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1019..1025

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                    if (type != null) {
                                                                                                                                        try {
                                                                                                                                            attrType = Classes.forNameByThread(type);
                                                                                                                                        } catch (ClassNotFoundException e) {
                                                                                                                                            throw UiException.Aide.wrap(e, e.getMessage());
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 35 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1224..1230

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                if (validatorExpr != null) {
                                                                                                                                    BindingKey bkey = getBindingKey(comp, formId);
                                                                                                                                    if (!_hasValidators.contains(bkey)) {
                                                                                                                                        _hasValidators.add(bkey);
                                                                                                                                    }
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 30 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 1396..1401

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

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

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

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

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

                                                                                                                        Refactorings

                                                                                                                        Further Reading

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

                                                                                                                                if (validatorExpr != null) {
                                                                                                                                    BindingKey bkey = getBindingKey(comp, attr);
                                                                                                                                    if (!_hasValidators.contains(bkey)) {
                                                                                                                                        _hasValidators.add(bkey);
                                                                                                                                    }
                                                                                                                        Severity: Minor
                                                                                                                        Found in zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java and 1 other location - About 30 mins to fix
                                                                                                                        zkbind/src/main/java/org/zkoss/bind/impl/BinderImpl.java on lines 934..939

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

                                                                                                                        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