To those who like to deal with tags,

I have some JSP code that gets stamped allover every day, it requires 
tweaking in each situation, hence it is error prone. We decided to make it 
a tag, but got stuck on two issues:

 how do we scope the 'formBean' var in the JSP page like <jsp:useBean/>

 how do we simulate <jsp:setProperty name='formBean' property='*' />
  now I am sure we can brute force this, by using reflection and 
  iteration, but is there a method already written?

here is my JSP code.

 <jsp:useBean id='formBean' 
class='com.pyerotechnics.customer.ushr.ca15.intranet.tier2.beans.Form_IssueEdit'>
  <%formBean.setPageContext(pageContext);%>
  <jsp:setProperty name='formBean' property='dataSource' value='jdbc/intranetDB' />
  <jsp:setProperty name='formBean' property='*' />
  <%formBean.go();%>
 </jsp:useBean>

here is the intended tag syntax.

 <p:useFormBean 
    id='formBean' 
    class='com.pyerotechnics.customer.ushr.ca15.intranet.tier2.beans.Form_IssueEdit'
    dataSource='jdbc/intranetDB' />

-Jason Pyeron

-- 
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-                                                               -
- Jason Pyeron                   http://www.pyerotechnics.com   -
- Owner & Lead                  Pyerotechnics Development, Inc. -
- +1 410 808 6646 (c)           500 West University Parkway #1S -
- +1 410 467 2266 (f)           Baltimore, Maryland  21210-3253 -
-                                                               -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

This message is for the designated recipient only and may contain 
privileged, proprietary, or otherwise private information. If you
have received it in error, purge the message from your system and 
notify the sender immediately.  Any other use of the email by you 
is prohibited.




--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to