[jsr-314-open] Wrapping Text with a tag - what's the correct behavior?

Dan Allen dan.j.allen at gmail.com
Fri Jun 19 13:18:09 EDT 2009


I had a private conversation while the mailinglist was out of order and I
want to bring the conclusions that were drawn back online.

To restate the problem, how does JSF handle the case when both a value
attribute and body markup are provided for UIOutput components?

1. We need to spec the behavior so there is consistency across
implementations
2. Ajax should not be handled as a special case (consistency across usage
scenarios)
3. If the value attribute is used, and the value is not empty, the body
markup should be ignored.

The following use case was put forth that relies on the unspecified behavior
today:

<h:outputText style="border: 1px solid blue" value="#{escapedText}"
escape="false" rendered="#{renderCondition}"><img src="img/exclmark.gif"
alt="!" /></h:outputText>

It's semantically incorrect to consider both the value and body content.
That would be an attempt to use a shorthand which I don't think should be
supported. The proper thing to do is introduce additional, nested tags.

-Dan

-- 
Dan Allen
Senior Software Engineer, Red Hat | Author of Seam in Action

http://mojavelinux.com
http://mojavelinux.com/seaminaction
http://in.relation.to/Bloggers/Dan

NOTE: While I make a strong effort to keep up with my email on a daily
basis, personal or other work matters can sometimes keep me away
from my email. If you contact me, but don't hear back for more than a week,
it is very likely that I am excessively backlogged or the message was
caught in the spam filters.  Please don't hesitate to resend a message if
you feel that it did not reach my attention.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jsr-314-open-mirror/attachments/20090619/e1e60617/attachment.html 


More information about the jsr-314-open-mirror mailing list