com.softslate.commerce.customer.core
Class CustomerRequestProcessor

java.lang.Object
  extended byorg.apache.struts.action.RequestProcessor
      extended byorg.apache.struts.tiles.TilesRequestProcessor
          extended bycom.softslate.commerce.customer.core.BaseRequestProcessor
              extended bycom.softslate.commerce.customer.core.CheckRequestProcessor
                  extended bycom.softslate.commerce.customer.core.CustomerRequestProcessor

public class CustomerRequestProcessor
extends CheckRequestProcessor

Subclass of TilesRequestProcessor that negotiates each application request.

Author:
David Tobey

Field Summary
(package private) static org.apache.commons.logging.Log log
           
 
Fields inherited from class com.softslate.commerce.customer.core.BaseRequestProcessor
errorPath, installerSettingsLocation, systemLayoutDirectory
 
Fields inherited from class org.apache.struts.tiles.TilesRequestProcessor
definitionsFactory
 
Fields inherited from class org.apache.struts.action.RequestProcessor
actions, INCLUDE_PATH_INFO, INCLUDE_SERVLET_PATH, moduleConfig, servlet
 
Constructor Summary
CustomerRequestProcessor()
           
 
Method Summary
 boolean npcOnCustomerPreRequestEnd(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Performs custom processing at the end of each call to processPreProcess.
protected  boolean processPreprocess(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Runs initializations and other necessary routines before every request into the system.
 
Methods inherited from class com.softslate.commerce.customer.core.CheckRequestProcessor
npcOnPreRequestEnd
 
Methods inherited from class com.softslate.commerce.customer.core.BaseRequestProcessor
alterURI, doForward, getExceptionAsString, npcOnPreRequestBegin, npcOnPreRequestEnd, processException
 
Methods inherited from class org.apache.struts.tiles.TilesRequestProcessor
getDefinitionsFactory, init, initDefinitionsMapping, internalModuleRelativeForward, internalModuleRelativeInclude, processForwardConfig, processTilesDefinition
 
Methods inherited from class org.apache.struts.action.RequestProcessor
destroy, doInclude, getInternal, getServletContext, log, log, process, processActionCreate, processActionForm, processActionPerform, processCachedMessages, processContent, processForward, processInclude, processLocale, processMapping, processMultipart, processNoCache, processPath, processPopulate, processRoles, processValidate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

static org.apache.commons.logging.Log log
Constructor Detail

CustomerRequestProcessor

public CustomerRequestProcessor()
Method Detail

processPreprocess

protected boolean processPreprocess(javax.servlet.http.HttpServletRequest request,
                                    javax.servlet.http.HttpServletResponse response)
Runs initializations and other necessary routines before every request into the system.

Here are the steps this method takes for each request:

  1. Initializes the request's htmlHeadTitle attribute to the "storeName" setting from the database. This attribute may be modified later by an action class or by LayoutAction.
  2. Sets the session scope's currentLayout attribute to the "layout" request parameter, if it is present, or to the "defaultLayout" setting from the database, if it is not present.
  3. Calls npcOnPreRequestEnd(), which can be overridden by a subclass to provide customizations.

Overrides:
processPreprocess in class BaseRequestProcessor
Parameters:
request - The servlet request we are processing.
response - The servlet response we are creating.

npcOnCustomerPreRequestEnd

public boolean npcOnCustomerPreRequestEnd(javax.servlet.http.HttpServletRequest request,
                                          javax.servlet.http.HttpServletResponse response)
Performs custom processing at the end of each call to processPreProcess. Intended to be overridden by subclasses for customizations. This method should return false to signal processPreProcess to return false itself.

Returns:
true if the processing was successful, false if processing should stop.


Copyright © SoftSlate, Inc. 2003–2005