myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matthias Wronka (JIRA)" <...@myfaces.apache.org>
Subject [jira] Created: (TOBAGO-410) attribute-tag causes ClassCastException
Date Thu, 24 May 2007 06:23:16 GMT
attribute-tag causes ClassCastException
---------------------------------------

                 Key: TOBAGO-410
                 URL: https://issues.apache.org/jira/browse/TOBAGO-410
             Project: MyFaces Tobago
          Issue Type: Bug
          Components: Core
            Reporter: Matthias Wronka
             Fix For: 1.0.11, 1.0.12


We use the tc:attribute-Tag to assign styles to components such as

<tc:panel>
	<tc:attribute name="styleClass" value="tobago-panel-default my-style" />
...

or using Java Code:

       ivPanel = (UIPanel) ComponentUtil.createComponent(facesContext, UIPanel.COMPONENT_TYPE,
"Panel");
       Map lvAttr = ivPanel.getAttributes();
       lvAttr.put("styleClass", "tobago-panel-default my-style");

In the current snapshots this causes a ClassCastException:

java.lang.ClassCastException
	at org.apache.myfaces.tobago.renderkit.html.StyleClasses.ensureStyleClasses(StyleClasses.java:64)
	at org.apache.myfaces.tobago.renderkit.html.HtmlRendererUtil.createCssClass(HtmlRendererUtil.java:115)
	at org.apache.myfaces.tobago.renderkit.html.HtmlRendererUtil.prepareRender(HtmlRendererUtil.java:90)
	at org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.DefaultLayoutRenderer.prepareRender(DefaultLayoutRenderer.java:40)
	at org.apache.myfaces.tobago.renderkit.RenderUtil.encode(RenderUtil.java:73)
	at org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.GridLayoutRenderer.encodeChildrenOfComponent(GridLayoutRenderer.java:364)
	at org.apache.myfaces.tobago.component.UILayout.encodeChildrenOfComponent(UILayout.java:71)
	at org.apache.myfaces.tobago.component.UIGridLayout.encodeChildrenOfComponent(UIGridLayout.java:277)
	at org.apache.myfaces.tobago.component.UIPanelBase.encodeChildren(UIPanelBase.java:43)
	at org.apache.myfaces.tobago.renderkit.RenderUtil.encode(RenderUtil.java:77)
	at org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.DefaultLayoutRenderer.encodeChildrenOfComponent(DefaultLayoutRenderer.java:47)
	at org.apache.myfaces.tobago.component.UILayout.encodeChildrenOfComponent(UILayout.java:71)
	at org.apache.myfaces.tobago.component.UIPanelBase.encodeChildren(UIPanelBase.java:43)
	at org.apache.myfaces.tobago.renderkit.RenderUtil.encode(RenderUtil.java:77)

As this feature worked fine with version 1.0.10 we would appreciate a transition period, in
which the styles are still assigned but a warning is logged. Currently our applications cannot
use these snapshots.

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