O'Reilly logo

MySQL™ and JSP™ Web Applications: Data-Driven Programming Using Tomcat and MySQL by James Turner

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Action

Because there's no validation, control always is handed over to the accountAction class, shown in Listing 16.4.

Listing 16.4. accountAction.java
package com.bfg.struts;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletException;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.action.ActionForward;
import org.apache.struts.util.PropertyUtils;
import com.bfg.customer.Address;
import com.bfg.customer.Customer;
import com.bfg.customer.CreditCard;
import java.io.*;

public class accountAction extends Action {
   public ActionForward perform(ActionMapping mapping, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required