import javax.servlet.http.HttpServletRequest;
import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;

import java.sql.Timestamp;


public final class CustomerForm extends ActionForm
{

    /**
     * The maintenance action we are performing (Create or Edit).
     */
    private String action;
    
    private Integer customerId;
    private String title;
    private String firstName;
    private String lastName;
    private String email;

    public CustomerForm()
    {
        action = "Create";
        
        customerId = null;
        title = null;
        firstName = null;
        lastName = null;
        email = null;
    }

    /**
     * Return the maintenance action.
     */
    public String getAction()
    {
    return (this.action);
    }

    /**
     * Set the maintenance action.
     *
     * @param action The new maintenance action.
     */
    public void setAction(String action)
    {
        this.action = action;
    }

    
    /**
     * Return the customerId.
     */
    public Integer getCustomerId()
    {
    return customerId;
    }

    /**
     * Set the customerId.
     *
     * @param customerId The new customerId
     */
    public void setCustomerId(Integer customerId)
    {
        this.customerId = customerId;
    }
    
    /**
     * Return the title.
     */
    public String getTitle()
    {
    return title;
    }

    /**
     * Set the title.
     *
     * @param title The new title
     */
    public void setTitle(String title)
    {
        this.title = title;
    }
    
    /**
     * Return the firstName.
     */
    public String getFirstName()
    {
    return firstName;
    }

    /**
     * Set the firstName.
     *
     * @param firstName The new firstName
     */
    public void setFirstName(String firstName)
    {
        this.firstName = firstName;
    }
    
    /**
     * Return the lastName.
     */
    public String getLastName()
    {
    return lastName;
    }

    /**
     * Set the lastName.
     *
     * @param lastName The new lastName
     */
    public void setLastName(String lastName)
    {
        this.lastName = lastName;
    }
    
    /**
     * Return the email.
     */
    public String getEmail()
    {
    return email;
    }

    /**
     * Set the email.
     *
     * @param email The new email
     */
    public void setEmail(String email)
    {
        this.email = email;
    }
    

    /**
     * Reset all properties to their default values.
     *
     * @param mapping The mapping used to select this instance
     * @param request The servlet request we are processing
     */
    public void reset(ActionMapping mapping, HttpServletRequest request)
    {
        action = "Create";
        
        customerId = null;
        title = null;
        firstName = null;
        lastName = null;
        email = null;
    }

    /**
     * Validate the properties that have been set from this HTTP request,
     * and return an <code>ActionErrors</code> object that encapsulates any
     * validation errors that have been found.  If no errors are found, return
     * <code>null</code> or an <code>ActionErrors</code> object with no
     * recorded error messages.
     *
     * @param mapping The mapping used to select this instance
     * @param request The servlet request we are processing
     */
    public ActionErrors validate(ActionMapping mapping,
                                 HttpServletRequest request)
    {
        ActionErrors errors = new ActionErrors();
        return errors;
    }

}