net.trajano.twiff.internal.servlet
Class StringActionResultProcessor

java.lang.Object
  extended by net.trajano.twiff.internal.servlet.StringActionResultProcessor
All Implemented Interfaces:
ActionResultProcessor

public class StringActionResultProcessor
extends Object
implements ActionResultProcessor

Processes action results of strings.

Author:
Archimedes Trajano

Constructor Summary
StringActionResultProcessor(Configuration configuration, WebXmlAdapter webXmlAdapter)
          Constructs the processor.
 
Method Summary
 boolean isResultProcessable(Object result, HttpServletRequest request)
          Returns true if the result is a string.
 String processActionResult(Object result, HttpServletRequest request)
          Processes the action result and returns the URL to redirect to.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringActionResultProcessor

public StringActionResultProcessor(Configuration configuration,
                                   WebXmlAdapter webXmlAdapter)
Constructs the processor.

Parameters:
configuration - the configuration to get the token value.
webXmlAdapter - web.xml adapter
Method Detail

isResultProcessable

public boolean isResultProcessable(Object result,
                                   HttpServletRequest request)
Returns true if the result is a string.

Specified by:
isResultProcessable in interface ActionResultProcessor
Parameters:
result - result of the action.
request - servlet request.
Returns:
true if the result is processable.
See Also:
ActionResultProcessor.isResultProcessable(java.lang.Object, javax.servlet.http.HttpServletRequest)

processActionResult

public String processActionResult(Object result,
                                  HttpServletRequest request)
Description copied from interface: ActionResultProcessor
Processes the action result and returns the URL to redirect to.

Specified by:
processActionResult in interface ActionResultProcessor
Parameters:
result - result of the action.
request - request object.
Returns:
the redirect URL that would be encoded.
See Also:
ActionResultProcessor.processActionResult(java.lang.Object, javax.servlet.http.HttpServletRequest)


Copyright © 2004-2005 trajano.net. All Rights Reserved.