ICEfaces-EE
  1. ICEfaces-EE
  2. IPCK-362

TreeTable Composite Component error with MyFaces

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: EE-3.0.0.BETA
    • Fix Version/s: EE-3.0.0.GA
    • Component/s: Facelet Components
    • Labels:
      None
    • Environment:
      n/a

      Description

      The TreeTable and DragAndDropTreeTable render correctly with MyFaces 2.1.6 although any interaction with the TreeTable results in the following:

      <?xml version="1.0" encoding="utf-8"?><partial-response><error><error-name>java.lang.UnsupportedOperationException</error-name><error-message><![CDATA[this method is here only to maintain binary compatibility w/ the RI]]></error-message></error><changes><extension aceCallbackParam="validationFailed">{"validationFailed":false}</extension></changes></partial-response>

        Issue Links

          Activity

          Hide
          Philip Breau added a comment -

          correct behaviour after using the <h:dataTable> tag, although styling is broken

          Show
          Philip Breau added a comment - correct behaviour after using the <h:dataTable> tag, although styling is broken
          Hide
          Philip Breau added a comment -

          The TreeTable uses an array of colours and the corresponding depth level to colour the cell backgrounds according to depth. This appears to be working on the first column (see above image), but not the other columns. The only difference is that the 1st column is declared in the template body, and the other columns are passed through as a unnamed ui:insert.

          Show
          Philip Breau added a comment - The TreeTable uses an array of colours and the corresponding depth level to colour the cell backgrounds according to depth. This appears to be working on the first column (see above image), but not the other columns. The only difference is that the 1st column is declared in the template body, and the other columns are passed through as a unnamed ui:insert.
          Hide
          Deryk Sinotte added a comment -

          I also see the client error when clicking on a row expansion icon and I also see the same problem in the Easy Expandable Table example:

          <error-name>java.lang.UnsupportedOperationException</error-name><error-message><![CDATA[this method is here only to maintain binary compatibility w/ the RI]]>

          Looking in the MyFaces code, I find this aligns with Phillips observation about the setDataModel() method of UIData:

          protected void setDataModel(DataModel dataModel)

          { throw new UnsupportedOperationException("this method is here only to maintain binary compatibility w/ the RI"); }

          The only place I could find that call being used was in org.icefaces.impl.component.UISeriesBase:

          public void broadcast(FacesEvent event)
          throws AbortProcessingException {

          if (!(event instanceof RowEvent))

          { super.broadcast(event); return; }

          FacesContext context = FacesContext.getCurrentInstance();
          // Set up the correct context and fire our wrapped event
          RowEvent revent = (RowEvent) event;
          if (isNestedWithinUIData())

          { setDataModel(null); <--NOT IMPLMENTED IN MYFACES }

          ...

          but the broadcast method is used fairly extensively. So we either need to override setDataModel in the appropriate place in our class hierarch or catch/log the exception.

          Show
          Deryk Sinotte added a comment - I also see the client error when clicking on a row expansion icon and I also see the same problem in the Easy Expandable Table example: <error-name>java.lang.UnsupportedOperationException</error-name><error-message><![CDATA [this method is here only to maintain binary compatibility w/ the RI] ]> Looking in the MyFaces code, I find this aligns with Phillips observation about the setDataModel() method of UIData: protected void setDataModel(DataModel dataModel) { throw new UnsupportedOperationException("this method is here only to maintain binary compatibility w/ the RI"); } The only place I could find that call being used was in org.icefaces.impl.component.UISeriesBase: public void broadcast(FacesEvent event) throws AbortProcessingException { if (!(event instanceof RowEvent)) { super.broadcast(event); return; } FacesContext context = FacesContext.getCurrentInstance(); // Set up the correct context and fire our wrapped event RowEvent revent = (RowEvent) event; if (isNestedWithinUIData()) { setDataModel(null); <--NOT IMPLMENTED IN MYFACES } ... but the broadcast method is used fairly extensively. So we either need to override setDataModel in the appropriate place in our class hierarch or catch/log the exception.
          Hide
          Philip Breau added a comment -

          First issues are fixed. UnsupportedOperation is no longer occurring. But now the following message appears after clicking on a tree node:

          No navigation case match for viewId /demo.xhtml, action #

          {row.toggleRow}

          and outcome

          Show
          Philip Breau added a comment - First issues are fixed. UnsupportedOperation is no longer occurring. But now the following message appears after clicking on a tree node: No navigation case match for viewId /demo.xhtml, action # {row.toggleRow} and outcome
          Hide
          Philip Breau added a comment -

          30667 3/4/12 2:12 PM 2 philip.breau IPCK-362 TreeTable issues with MyFaces - change action to actionListener on tree table node toggle method to avoid action outcome not found message

          Show
          Philip Breau added a comment - 30667 3/4/12 2:12 PM 2 philip.breau IPCK-362 TreeTable issues with MyFaces - change action to actionListener on tree table node toggle method to avoid action outcome not found message

            People

            • Assignee:
              Philip Breau
              Reporter:
              Philip Breau
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: