com.jcorporate.expresso.core.controller
Class DefaultForm
java.lang.Object
org.apache.struts.action.ActionForm
com.jcorporate.expresso.core.controller.DefaultForm
- All Implemented Interfaces:
- Serializable, StateForm
- Direct Known Subclasses:
- ControllerForm
- public class DefaultForm
- extends org.apache.struts.action.ActionForm
- implements Serializable, StateForm
*
This class is a bridge between Expresso's Controller system and the Struts
Action Form. It is automatically utilized by Expresso and you don't have
to directly deal with it.
- Since:
- Expresso 4.0
- Author:
- Michael Nash
- See Also:
- Serialized Form
|
Field Summary |
protected int |
page
|
protected org.apache.commons.validator.ValidatorResults |
validatorResults
|
| Fields inherited from class org.apache.struts.action.ActionForm |
multipartRequestHandler, servlet |
| Methods inherited from class org.apache.struts.action.ActionForm |
getMultipartRequestHandler, getServlet, getServletWrapper, reset, reset, setMultipartRequestHandler, setServlet |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
page
protected int page
validatorResults
protected org.apache.commons.validator.ValidatorResults validatorResults
DefaultForm
public DefaultForm()
validate
public org.apache.struts.action.ActionErrors validate(org.apache.struts.action.ActionMapping mapping,
ServletRequest request)
saveForm
public void saveForm(ControllerRequest req)
throws ControllerException
- Throws:
ControllerException
restoreForm
public void restoreForm(ControllerRequest req)
throws ControllerException
- Throws:
ControllerException
getFields
public Hashtable getFields()
clear
public void clear()
setAttribute
public void setAttribute(String fieldName,
Object newValue)
setField
public void setField(String fieldName,
String fieldValue)
throws ControllerException
- Throws:
ControllerException
setUsingHashtableParameters
public void setUsingHashtableParameters(Hashtable parameters)
throws ControllerException
- Throws:
ControllerException
getAttribute
public Object getAttribute(String fieldName)
throws ControllerException
- Returns the attribute that has been set for a particular field OR
null if it doesn't exist.
- Throws:
ControllerException - if fieldName is blank.
getAttributes
public Hashtable getAttributes()
- Returns the attributes Hashtable.
getField
public String getField(String fieldName)
throws ControllerException
- Throws:
ControllerException
validate
public org.apache.struts.action.ActionErrors validate(org.apache.struts.action.ActionMapping mapping,
HttpServletRequest request)
validate
public ErrorCollection validate(ControllerRequest request)
- Specified by:
validate in interface StateForm
initValidator
public org.apache.commons.validator.Validator initValidator(String key,
Object bean,
ServletContext application,
HttpServletRequest request,
org.apache.struts.action.ActionErrors errors,
int page)
Please see www.jcorporate.com for information about new Expresso releases.