When a user clicks the Submit button on an HTML form built with Struts, the data from that form is populated into a Java bean called a form bean.
A form bean has properties that match up with all the fields on the form. When the form is submitted, the bean properties are automatically populated. In addition, form beans provide support for automatic data validation and resetting of the bean property values. Listing 3.3 presents the file HelloForm.java, it’s the form bean that’s used to process the form data in our hello.jsp file.
package ch03.hello; import javax.servlet.http.HttpServletRequest; import org.apache.struts.action.ActionError; ...