myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Werner Punz (JIRA)" <...@myfaces.apache.org>
Subject [jira] Issue Comment Edited: (TOMAHAWK-1449) [myfaces-example-simple-1.1.9] displayValueOnly attribute demo fails with exception
Date Mon, 19 Oct 2009 19:43:00 GMT

    [ https://issues.apache.org/jira/browse/TOMAHAWK-1449?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12767322#action_12767322
] 

Werner Punz edited comment on TOMAHAWK-1449 at 10/19/09 7:41 PM:
-----------------------------------------------------------------

Ok another issue here our renderer calls a utils class which does following:
        //Try to find out by value binding
        ValueBinding vb = component.getValueBinding("value");
        if (vb == null) return null;
                         
        Class valueType = vb.getType(facesContext);
        if (valueType == null) return null;

        if (List.class.isAssignableFrom(valueType)) {

Well the main problem here simply is that mojarra gives back an object for the type
the return value itself however is a list in mojarras case, I assume we have to add
a check on the value if a check on the type fails here!


      was (Author: werpu):
    Ok another issue here our renderer calls a utils class which does following:
        //Try to find out by value binding
        ValueBinding vb = component.getValueBinding("value");
        if (vb == null) return null;
                         
        Class valueType = vb.getType(facesContext);
        if (valueType == null) return null;

        if (List.class.isAssignableFrom(valueType)) {

Well the main problem here simply is that mojarra gives back an object which itself is a weak
reference
the return value itself however is a list in mojarras case, I assume we have to add
a check on the value if a check on the type fails here!

  
> [myfaces-example-simple-1.1.9] displayValueOnly attribute demo fails with exception
> -----------------------------------------------------------------------------------
>
>                 Key: TOMAHAWK-1449
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-1449
>             Project: MyFaces Tomahawk
>          Issue Type: Bug
>    Affects Versions: 1.1.9
>         Environment: Mojarra 1.2_14-SNAPSHOT
> Mojarra 2.0.0-SNAPSHOT
> Mac OS 10.5.6
> JDK 1.6.0
>            Reporter: Ryan Lubke
>
> When activating the demo, the following exception is raised (w/ stacktrace):
> ValueBinding for UISelectMany : {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId:
/displayValueOnly.jsp][Class: javax.faces.component.html.HtmlForm,Id: form][Class: javax.faces.component.html.HtmlPanelGrid,Id:
firstGrid][Class: org.apache.myfaces.component.html.ext.HtmlSelectManyCheckbox,Id: selectManyCheckbox]}
must be of type List or Array
> java.lang.IllegalArgumentException: ValueBinding for UISelectMany : {Component-Path :
[Class: javax.faces.component.UIViewRoot,ViewId: /displayValueOnly.jsp][Class: javax.faces.component.html.HtmlForm,Id:
form][Class: javax.faces.component.html.HtmlPanelGrid,Id: firstGrid][Class: org.apache.myfaces.component.html.ext.HtmlSelectManyCheckbox,Id:
selectManyCheckbox]} must be of type List or Array
> 	at org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.findUISelectManyConverter(RendererUtils.java:375)
> 	at org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRendererUtils.findUISelectManyConverterFailsafe(HtmlRendererUtils.java:362)
> 	at org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRendererUtils.renderDisplayValueOnlyForSelects(HtmlRendererUtils.java:650)
> 	at org.apache.myfaces.renderkit.html.ext.HtmlCheckboxRenderer.encodeEnd(HtmlCheckboxRenderer.java:90)
> 	at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:861)
> 	at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:244)
> 	at com.sun.faces.renderkit.html_basic.GridRenderer.renderRow(GridRenderer.java:180)
> 	at com.sun.faces.renderkit.html_basic.GridRenderer.encodeChildren(GridRenderer.java:127)
> 	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:837)
> 	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:930)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message