atg.search.query.config
Class SearchConfigurationRedirectProcessor

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.search.query.config.SearchConfigurationRedirectProcessor
All Implemented Interfaces:
atg.naming.AbsoluteNameable, NameContextBindingListener, NameContextElement, atg.naming.NameContextParentable, NameResolver, AdminableService, atg.nucleus.Configured, ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, VariableArgumentApplicationLogging, ComponentNameResolver, Service, ServiceListener, SearchRedirectProcessor, java.util.EventListener

public class SearchConfigurationRedirectProcessor
extends GenericService
implements SearchRedirectProcessor

This class implements the search redirect processor interface to allow it to be called from the search QueryFormHandler. It will process search results to handle search configuration redirection rule URLs. It also provides support for the search testing feature and can report on URL's without allowing actual page redirection.


Field Summary
static java.lang.String CLASS_VERSION
          Class version string
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
SearchConfigurationRedirectProcessor()
           
 
Method Summary
 java.lang.String getRedirect(SearchResponse pSearchResponse)
          Gets the first redirect rule url returned in the search results.
 boolean handleAutoRedirect(SearchResponse pSearchResponse, DynamoHttpServletRequest pDynamoRequest, java.lang.Object pCallback)
          Called from search form handler to check the search results for redirection rule URL's.
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static final java.lang.String CLASS_VERSION
Class version string

See Also:
Constant Field Values
Constructor Detail

SearchConfigurationRedirectProcessor

public SearchConfigurationRedirectProcessor()
Method Detail

handleAutoRedirect

public boolean handleAutoRedirect(SearchResponse pSearchResponse,
                                  DynamoHttpServletRequest pDynamoRequest,
                                  java.lang.Object pCallback)
                           throws atg.search.client.SearchClientException
Called from search form handler to check the search results for redirection rule URL's. Returns false if any are found.

Specified by:
handleAutoRedirect in interface SearchRedirectProcessor
Parameters:
pSearchRequest - SearchRequest object containing the query parameters to populate.
pDynamoRequest - DynamoHttpServletRequest object for the current request.
pCallback - Callback object to the form handler that called this method.
Returns:
true if redirection urls are found in the results else returns false
Throws:
atg.search.client.SearchClientException

getRedirect

public java.lang.String getRedirect(SearchResponse pSearchResponse)
Gets the first redirect rule url returned in the search results. Gets the url from: response.queryAction.queryActionItemList.queryActionItem.actionArgs(0)

Specified by:
getRedirect in interface SearchRedirectProcessor
Parameters:
pSearchResponse - SearchResponse for the search results.
Returns:
String url of first redirection rule in search results or null if none found.