org.nanocontainer.nanowar.struts
Class PicoTilesRequestProcessor

java.lang.Object
  extended by org.apache.struts.action.RequestProcessor
      extended by org.apache.struts.tiles.TilesRequestProcessor
          extended by org.nanocontainer.nanowar.struts.PicoTilesRequestProcessor

public class PicoTilesRequestProcessor
extends org.apache.struts.tiles.TilesRequestProcessor

Uses Pico to produce Actions and inject dependencies into them. Use this class if you are using the Tiles library. If not, you can use the org.nanocontainer.nanowar.sample.struts.PicoRequestProcessor instead.

Author:
Stephen Molitor
See Also:
ActionFactory, org.nanocontainer.nanowar.sample.struts.PicoRequestProcessor

Field Summary
 
Fields inherited from class org.apache.struts.tiles.TilesRequestProcessor
definitionsFactory, log
 
Fields inherited from class org.apache.struts.action.RequestProcessor
actions, INCLUDE_PATH_INFO, INCLUDE_SERVLET_PATH, moduleConfig, servlet
 
Constructor Summary
PicoTilesRequestProcessor()
           
 
Method Summary
protected  org.apache.struts.action.Action processActionCreate(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, org.apache.struts.action.ActionMapping mapping)
          Creates or retrieves the action instance.
 
Methods inherited from class org.apache.struts.tiles.TilesRequestProcessor
doForward, getDefinitionsFactory, init, initDefinitionsMapping, internalModuleRelativeForward, internalModuleRelativeInclude, processForwardConfig, processTilesDefinition, processTilesDefinition
 
Methods inherited from class org.apache.struts.action.RequestProcessor
destroy, doInclude, getInternal, getServletContext, process, processActionForm, processActionPerform, processCachedMessages, processContent, processException, processForward, processInclude, processLocale, processMapping, processMultipart, processNoCache, processPath, processPopulate, processPreprocess, processRoles, processValidate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PicoTilesRequestProcessor

public PicoTilesRequestProcessor()
Method Detail

processActionCreate

protected org.apache.struts.action.Action processActionCreate(javax.servlet.http.HttpServletRequest request,
                                                              javax.servlet.http.HttpServletResponse response,
                                                              org.apache.struts.action.ActionMapping mapping)
                                                       throws IOException
Creates or retrieves the action instance. The action is retrieved from the actions Pico container, using the mapping path as the component key. If no such action exists, a new one will be instantiated and placed in the actions container, thus injecting its dependencies.

Overrides:
processActionCreate in class org.apache.struts.action.RequestProcessor
Parameters:
request - the HTTP request object.
response - the HTTP response object.
mapping - the action mapping.
Returns:
the action instance.
Throws:
IOException


Copyright © 2003-2009 Codehaus. All Rights Reserved.