|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.struts.action.ActionForm com.softslate.commerce.customer.core.BaseForm
public class BaseForm
Extends the Struts ActionForm
class to provide base
functionality for form classes in the system. Provides several properties
common to most of the Web requests the application receives, to help action
classes communicate with the rest of the application.
Within the action classes of the Struts layer, this BaseForm
will be passed from method to method so that each of these properties can be
accessed easily.
Field Summary | |
---|---|
private BusinessObjectFactory |
businessObjectFactory
The application's business object factory. |
private org.apache.struts.action.ActionErrors |
errors
An ActionErrors object that stores any errors that will be
displayed to the current user within the response. |
private FormUtils |
formUtils
|
(package private) static org.apache.commons.logging.Log |
log
|
private org.apache.struts.action.ActionMapping |
mapping
The mapping corresponding to the current action of the request. |
private org.apache.struts.action.ActionMessages |
messages
An ActionMessages object that can be used to store
messages that will be displayed to the user within the response. |
private javax.servlet.http.HttpServletRequest |
request
The current HttpServletRequest object pertaining to the
submission to this BaseForm . |
private static long |
serialVersionUID
|
private Settings |
settings
This request's settings, as loaded from the sscSetting
database table. |
private User |
user
The current user making the request for this BaseForm . |
Fields inherited from class org.apache.struts.action.ActionForm |
---|
multipartRequestHandler, servlet |
Constructor Summary | |
---|---|
BaseForm()
|
Method Summary | |
---|---|
FormUtils |
formUtils()
|
BusinessObjectFactory |
getBusinessObjectFactory()
|
org.apache.struts.action.ActionErrors |
getErrors()
|
org.apache.struts.action.ActionMapping |
getMapping()
|
java.lang.String |
getMessage(java.lang.String module,
java.lang.String key,
java.lang.Object[] args)
Look up and return a message from a given bundle among the Struts MessageResources objects in the application scope. |
org.apache.struts.action.ActionMessages |
getMessages()
|
javax.servlet.http.HttpServletRequest |
getRequest()
|
Settings |
getSettings()
|
User |
getUser()
|
void |
initializeProperties(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request)
Initializes all the properties of this BaseForm by copying
the objects from the request, session, and application scopes. |
void |
setBusinessObjectFactory(BusinessObjectFactory businessObjectFactory)
|
void |
setErrors(org.apache.struts.action.ActionErrors errors)
|
void |
setMapping(org.apache.struts.action.ActionMapping mapping)
|
void |
setMessages(org.apache.struts.action.ActionMessages messages)
|
void |
setRequest(javax.servlet.http.HttpServletRequest request)
|
void |
setSettings(Settings settings)
|
void |
setUser(User user)
|
Methods inherited from class org.apache.struts.action.ActionForm |
---|
getMultipartRequestHandler, getServlet, getServletWrapper, reset, reset, setMultipartRequestHandler, setServlet, validate, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final long serialVersionUID
static org.apache.commons.logging.Log log
private javax.servlet.http.HttpServletRequest request
HttpServletRequest
object pertaining to the
submission to this BaseForm
.
private org.apache.struts.action.ActionMessages messages
ActionMessages
object that can be used to store
messages that will be displayed to the user within the response.
private org.apache.struts.action.ActionErrors errors
ActionErrors
object that stores any errors that will be
displayed to the current user within the response.
private org.apache.struts.action.ActionMapping mapping
private Settings settings
sscSetting
database table.
private User user
BaseForm
.
This object lives in the user's session across requests, but can be
passed throughout the Struts layer through this property.
private BusinessObjectFactory businessObjectFactory
private FormUtils formUtils
Constructor Detail |
---|
public BaseForm()
Method Detail |
---|
public javax.servlet.http.HttpServletRequest getRequest()
public void setRequest(javax.servlet.http.HttpServletRequest request)
public org.apache.struts.action.ActionMessages getMessages()
public void setMessages(org.apache.struts.action.ActionMessages messages)
public org.apache.struts.action.ActionErrors getErrors()
public void setErrors(org.apache.struts.action.ActionErrors errors)
public org.apache.struts.action.ActionMapping getMapping()
public void setMapping(org.apache.struts.action.ActionMapping mapping)
public Settings getSettings()
public void setSettings(Settings settings)
public User getUser()
public void setUser(User user)
public BusinessObjectFactory getBusinessObjectFactory()
public void setBusinessObjectFactory(BusinessObjectFactory businessObjectFactory)
public void initializeProperties(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)
BaseForm
by copying
the objects from the request, session, and application scopes. Called by
action classes and within the validate
method of this
BaseForm
.
mapping
- The mapping corresponding to the current action of the
request.request
- The HttpServletRequest
object for this request.public java.lang.String getMessage(java.lang.String module, java.lang.String key, java.lang.Object[] args)
MessageResources
objects in the application scope.
module
- Name of the servlet context attribute for the message
resources bundle.key
- Message key to be looked up and returned.args
- Replacement parameters for this message.
null
if the message can't
be found.public FormUtils formUtils()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |