This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JSP and the fly likes java bean , jsp page and parameters Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "java bean , jsp page and parameters" Watch "java bean , jsp page and parameters" New topic
Author

java bean , jsp page and parameters

nirjari patel
Ranch Hand

Joined: Apr 23, 2009
Posts: 363
HTML Form
Java Class

JSP PAGE - SavePage.jsp


1 How does the parameters from html form get collected in Savename.jsp ? As there is no request.getParameter() ?

2 How do these parameters het transferred to java bean user ? user java class is called by the useBean, but how is each property assigned a particular value ?

thanks
Sebastian Janisch
Ranch Hand

Joined: Feb 23, 2009
Posts: 1183
If you declare property="*", the container will map all request parameters which names can be matched with a JavaBean Property setter method into the bean.

The idea is simple.

An input field of name email will invoke setEmail(String s) on the bean you use.

If you have input fields that don't have a bean setter, no worries, these are skipped, no exception is thrown.

As for how the container does it... the powerful capabilities of Reflections


JDBCSupport - An easy to use, light-weight JDBC framework -
 
wood burning stoves
 
subject: java bean , jsp page and parameters
 
Similar Threads
The value for the useBean class attribute user.userData is invalid.
Tomcat 4.11 doubt
use of value object ( javabeans )
problem with bean in tomcat
Where to put bean class in Tomcat?