You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by bu...@apache.org on 2003/12/20 02:09:40 UTC

DO NOT REPLY [Bug 25671] New: - Populating attribute values from beans

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25671>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25671

Populating attribute values from beans

           Summary: Populating attribute values from beans
           Product: Struts
           Version: 1.1 Final
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Enhancement
          Priority: Other
         Component: Standard Actions
        AssignedTo: struts-dev@jakarta.apache.org
        ReportedBy: robert.hablutzel@libertymutual.com


Consider a highly variable JSP, where some or all of the characteristics of a 
particular HTML element are variable. In this case, there will be a number of 
attributes whose values are expressed as a runtime expression, rather than 
directly:

   <html:text name="<%= bean.getName() %>"
              property="<%= bean.getProperty() %>"
              value="<%= bean.getValue() %>"
              onchange="<%= bean.getOnchange() %> />

and so forth.

I'm proposing adding a new attribute which specifies the attribute values 
through a standard Java bean. The attribute names would be matched to bean 
properties, and any matching non-null values would be used as the attribute 
value. Attribute values not specified in the bean or on the tag would default. 
It's somewhat arbitrary whether attributes specified both in the tag and the 
bean would be taken from the bean or tag, but that should be specified.

The proposed enhancement would allow the above to be written:

    <html:text propertyBean="bean"/>

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-dev-help@jakarta.apache.org