@Deprecated public abstract class ComponentControllerSupport extends org.apache.struts.tiles.ControllerSupport
Derives from the Tiles ControllerSupport class rather than
implementing the Tiles Controller interface
in order to be compatible with Struts 1.1 and 1.2. Implements both Struts 1.1's
perform and Struts 1.2's execute method accordingly.
WebApplicationObjectSupport| Constructor and Description |
|---|
ComponentControllerSupport()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
doPerform(org.apache.struts.tiles.ComponentContext componentContext,
HttpServletRequest request,
HttpServletResponse response)
Deprecated.
Perform the preparation for the component, allowing for any Exception to be thrown.
|
void |
execute(org.apache.struts.tiles.ComponentContext componentContext,
HttpServletRequest request,
HttpServletResponse response,
ServletContext servletContext)
Deprecated.
This implementation delegates to
doPerform,
lazy-initializing the application context reference if necessary. |
protected org.springframework.context.ApplicationContext |
getApplicationContext()
Deprecated.
Return the current Spring ApplicationContext.
|
protected org.springframework.context.support.MessageSourceAccessor |
getMessageSourceAccessor()
Deprecated.
Return a MessageSourceAccessor for the application context
used by this object, for easy message access.
|
protected ServletContext |
getServletContext()
Deprecated.
Return the current ServletContext.
|
protected File |
getTempDir()
Deprecated.
Return the temporary directory for the current web application,
as provided by the servlet container.
|
protected org.springframework.web.context.WebApplicationContext |
getWebApplicationContext()
Deprecated.
Return the current Spring WebApplicationContext.
|
protected void |
initApplicationContext()
Deprecated.
Subclasses can override this for custom initialization behavior.
|
void |
perform(org.apache.struts.tiles.ComponentContext componentContext,
HttpServletRequest request,
HttpServletResponse response,
ServletContext servletContext)
Deprecated.
This implementation delegates to
execute,
converting non-Servlet/IO Exceptions to ServletException. |
public final void perform(org.apache.struts.tiles.ComponentContext componentContext,
HttpServletRequest request,
HttpServletResponse response,
ServletContext servletContext)
throws ServletException,
IOException
execute,
converting non-Servlet/IO Exceptions to ServletException.
This is the only execution method available in Struts 1.1.
perform in interface org.apache.struts.tiles.Controllerperform in class org.apache.struts.tiles.ControllerSupportServletExceptionIOExceptionexecute(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, javax.servlet.ServletContext)public final void execute(org.apache.struts.tiles.ComponentContext componentContext,
HttpServletRequest request,
HttpServletResponse response,
ServletContext servletContext)
throws Exception
doPerform,
lazy-initializing the application context reference if necessary.
This is the preferred execution method in Struts 1.2.
When running with Struts 1.1, it will be called by perform.
execute in interface org.apache.struts.tiles.Controllerexecute in class org.apache.struts.tiles.ControllerSupportExceptionperform(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, javax.servlet.ServletContext),
doPerform(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)protected void initApplicationContext()
throws org.springframework.beans.BeansException
org.springframework.context.ApplicationContextException - in case of initialization errorsorg.springframework.beans.BeansException - if thrown by application context methodsprotected final org.springframework.context.ApplicationContext getApplicationContext()
protected final org.springframework.web.context.WebApplicationContext getWebApplicationContext()
protected final org.springframework.context.support.MessageSourceAccessor getMessageSourceAccessor()
protected final ServletContext getServletContext()
protected final File getTempDir()
protected abstract void doPerform(org.apache.struts.tiles.ComponentContext componentContext,
HttpServletRequest request,
HttpServletResponse response)
throws Exception
This method will be called both in the Struts 1.1 and Struts 1.2 case,
by perform or execute, respectively.
componentContext - current Tiles component contextrequest - current HTTP requestresponse - current HTTP responseException - in case of errorsController.perform(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, javax.servlet.ServletContext),
getServletContext(),
getWebApplicationContext(),
perform(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, javax.servlet.ServletContext),
execute(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, javax.servlet.ServletContext)