org.formproc.servlet
Class HttpForm

java.lang.Object
  |
  +--org.formproc.Form
        |
        +--org.formproc.servlet.HttpForm

public class HttpForm
extends Form

Extension of the Form class which adds a method for easily handling HTTP form requests.

Author:
Anthony Eden

Field Summary
 
Fields inherited from class org.formproc.Form
validationResults
 
Constructor Summary
HttpForm()
          Construct a new HttpForm.
HttpForm(java.lang.String name, java.lang.Object target)
          Construct a new HttpForm with the given form name and target object.
 
Method Summary
 FormResult process(javax.servlet.http.HttpServletRequest request)
          Process the given HttpServletRequest.
 FormResult process(javax.servlet.http.HttpServletRequest request, java.util.Locale locale)
          Process the given HttpServletRequest.
 
Methods inherited from class org.formproc.Form
configure, convert, getErrorMessage, getErrorMessage, getFormConfiguration, getMessage, getMessage, getName, getTarget, getWriteMethod, process, process, process, process, process, setName, setTarget, store, validate, validateGroups
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpForm

public HttpForm()
Construct a new HttpForm.


HttpForm

public HttpForm(java.lang.String name,
                java.lang.Object target)
Construct a new HttpForm with the given form name and target object.

Parameters:
name - The form name
target - The target object
Method Detail

process

public FormResult process(javax.servlet.http.HttpServletRequest request)
                   throws java.lang.Exception
Process the given HttpServletRequest. The value of Locale.getDefault() is used to process the form fields.

Parameters:
request - An HttpServletRequest object
Returns:
The FormResult object
Throws:
java.lang.Exception - Any exception

process

public FormResult process(javax.servlet.http.HttpServletRequest request,
                          java.util.Locale locale)
                   throws java.lang.Exception
Process the given HttpServletRequest.

Parameters:
request - An HttpServletRequest object
locale - The Locale
Returns:
The FormResult object
Throws:
java.lang.Exception - Any exception


Copyright (c) 2001-2003 Anthony Eden. All Rights Reserved.