Uploaded image for project: 'MyFaces Core'
  1. MyFaces Core
  2. MYFACES-1828

code that allow perform custom tasks before and after set binding in 1.2 does not work

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.2.0, 1.2.2
    • 1.2.3
    • None
    • None

    Description

      In myfaces 1.1, it was possible to have a method on the component like this

      public void handleBindings()

      { makeAliases(getFacesContext()); RestoreStateUtils.recursivelyHandleComponentReferencesAndSetValid(getFacesContext(), this, true); removeAliases(getFacesContext()); }

      This is called from RestoreView state to handle the bindings properly. In myfaces 1.2, architectural changes (creation on RestoreViewSupport interface) replaced the original code with this:

      public void processComponentBinding(FacesContext facesContext, UIComponent component)
      {
      ValueExpression binding = component.getValueExpression("binding");
      if (binding != null)

      { binding.setValue(facesContext.getELContext(), component); }

      for (Iterator<UIComponent> iter = component.getFacetsAndChildren(); iter.hasNext()

      { processComponentBinding(facesContext, iter.next()); }

      }

      Some changes are necessary on RestoreStateUtils.recursivelyHandleComponentReferencesAndSetValid (not set UIInput components valid = true) to make this work as 1.1 with the advantage of aliasBean component can work like 1.1.

      Attachments

        Activity

          People

            lu4242 Leonardo Uribe
            lu4242 Leonardo Uribe
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: