[jboss-user] [JBoss Seam] - Re: how to conditionally render a row of dataTable

matt.drees do-not-reply at jboss.com
Sun Aug 19 15:06:15 EDT 2007


Rick Hightower wrote a couple good articles on Facelets, and the second gives a good example on using functions.  I found it helpful.

He goes for the programmatic approach of defining a facelets tag library; some people prefer defining their library in xml.  I like the programmatic approach better; it seems create less duplication.

http://www.ibm.com/developerworks/java/library/j-facelets2.html

As far as creating some kind of annotation-driven framework for conditional rendering, I'm sure you could do it.  Instead of using el functions, I'd guess you would be better off creating a component that marks its children rendered or not rendered, depending on their value-bindings.  You could get some direction on how to do this by looking at Seam's components for model validation (ModelValidator and UIValidateAll, as well as Hibernate Validator code).  But who knows; maybe that'd be harder to do.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4075579#4075579

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4075579



More information about the jboss-user mailing list