|
Anyframe Web | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.struts.action.Action
org.springframework.web.struts.ActionSupport
anyframe.web.struts.action.AbstractActionSupport
anyframe.web.struts.action.DefaultDispatchActionSupport
anyframe.web.struts.action.AbstractDispatchAction
public abstract class AbstractDispatchAction
Class expanding the anyframe.web.struts.action.DefaultDispatchActionSupport.
Provides additional functionalities other than DefaultDispatchActionSupport functionalities.
The AbstractDispatchAction doesn't define the form in struts-config.xml the Struts's Form object. It allows for the usage of direct mapping in the server side value object user inputed value transmitted from the presentation layer.
We need to implement the getValueObject method and create the VO object for mapping in the inherited Action Class for the AbstractDispatchAction in order to map the value in the value object. The VO object implements the anyframe.common.ValueObject.
| Field Summary | |
|---|---|
org.apache.commons.logging.Log |
log
|
protected java.util.HashMap |
methods
The set of Method objects we have introspected for this class, keyed by method name. |
protected java.lang.Class[] |
types
The set of argument type classes for the reflected method call. |
| Fields inherited from class anyframe.web.struts.action.DefaultDispatchActionSupport |
|---|
clazz, messages |
| Fields inherited from class org.apache.struts.action.Action |
|---|
servlet |
| Constructor Summary | |
|---|---|
AbstractDispatchAction()
|
|
| Method Summary | |
|---|---|
protected org.apache.struts.action.ActionForward |
dispatchMethod(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.lang.String name)
Dispatch to the specified method. |
org.apache.commons.logging.Log |
getLogger()
get Logger |
protected java.lang.reflect.Method |
getMethod(java.lang.String name)
get method |
protected java.lang.Object |
getService(java.lang.String name)
Returns using the bean name for the bean registered in WebApplicationContext. |
abstract anyframe.common.ValueObject |
getValueObject()
Returns by creating the instance of the VO class used on the Server side. |
protected void |
onInit()
Anyframe Core Delegation Util Method to get Logger |
org.apache.struts.action.ActionForward |
process(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Overrides the process method of anyframe.web.struts.action.DefaultDispatchActionSupport. |
protected ValidatorError |
validate(javax.servlet.http.HttpServletRequest request,
anyframe.common.ValueObject vo,
java.lang.String validationKey)
Does the VO's validation check. |
protected ValidatorError |
validate(javax.servlet.http.HttpServletRequest request,
anyframe.common.ValueObject vo,
java.lang.String validationKey,
int page)
Does the validation check of VO. |
| Methods inherited from class anyframe.web.struts.action.DefaultDispatchActionSupport |
|---|
cancelled, getMethodName, unspecified |
| Methods inherited from class anyframe.web.struts.action.AbstractActionSupport |
|---|
execute, postProcess, preProcess, processCheckedException, processFinally, processInvalidTokenException, processUnCheckedException |
| Methods inherited from class org.springframework.web.struts.ActionSupport |
|---|
getMessageSourceAccessor, getServletContext, getTempDir, getWebApplicationContext, initWebApplicationContext, onDestroy, setServlet |
| Methods inherited from class org.apache.struts.action.Action |
|---|
addErrors, addMessages, execute, generateToken, getErrors, getLocale, getMessages, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, resetToken, saveErrors, saveErrors, saveMessages, saveMessages, saveToken, setLocale |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public org.apache.commons.logging.Log log
protected java.util.HashMap methods
protected java.lang.Class[] types
| Constructor Detail |
|---|
public AbstractDispatchAction()
| Method Detail |
|---|
protected void onInit()
Anyframe Core Delegation Util Method to get Logger
onInit in class org.springframework.web.struts.ActionSupportprotected java.lang.Object getService(java.lang.String name)
getService in class DefaultDispatchActionSupportname - The bean name registered in ApplicationContext.
public org.apache.struts.action.ActionForward process(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws java.lang.Exception
If a specific request is requested, the process method is called with respect to the action mapping defined in the struts-config.xml. In the case the action class inheritting the AbstractionDispatchAction is defined as the mapping type, the process method is called and it again calls the appropriate method using the method's name info.
process in class DefaultDispatchActionSupportmapping - The ActionMapping used to select this instanceform - The optional ActionForm bean for this request (if any)request - The HTTP request we are processingresponse - The HTTP response we are creating
null if the response has been completed.
java.lang.Exception - if an exception occurs
protected java.lang.reflect.Method getMethod(java.lang.String name)
throws java.lang.NoSuchMethodException
getMethod in class DefaultDispatchActionSupportname - method name
java.lang.NoSuchMethodException - if no such method can be found
protected org.apache.struts.action.ActionForward dispatchMethod(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.lang.String name)
throws java.lang.Exception
dispatchMethod in class DefaultDispatchActionSupportjava.lang.Exceptionpublic org.apache.commons.logging.Log getLogger()
getLogger in class DefaultDispatchActionSupportpublic abstract anyframe.common.ValueObject getValueObject()
protected ValidatorError validate(javax.servlet.http.HttpServletRequest request,
anyframe.common.ValueObject vo,
java.lang.String validationKey)
throws java.lang.Exception
request - The HTTP request we are processingvo - The VO mapping the user transmitted valuevalidationKey - The form name defining the validation.xml
java.lang.Exception
protected ValidatorError validate(javax.servlet.http.HttpServletRequest request,
anyframe.common.ValueObject vo,
java.lang.String validationKey,
int page)
throws java.lang.Exception
request - The HTTP request we are processingvo - The VO mapping the user transmitted value.validationKey - The form name defined in validation.xml.page - The page for setting in the Validator.
java.lang.Exception
|
Anyframe Web | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||