com.interface21.web.servlet.mvc.multiaction
Interface MethodNameResolver

All Known Implementing Classes:
InternalPathMethodNameResolver, ParameterMethodNameResolver, PropertiesMethodNameResolver

public interface MethodNameResolver

Interface that parameterizes the MultiActionController class using the Strategy GoF Design pattern, allowing the mapping from incoming request to handler method name to be varied without affecting other application code.
Illustrates how delegation can be more flexible than subclassing.

Author:
Rod Johnson

Method Summary
 java.lang.String getHandlerMethodName(javax.servlet.http.HttpServletRequest request)
          Return a method name that can handle this request.
 

Method Detail

getHandlerMethodName

public java.lang.String getHandlerMethodName(javax.servlet.http.HttpServletRequest request)
                                      throws NoSuchRequestHandlingMethodException
Return a method name that can handle this request. Such mappings are typically, but not necessarily, based on URL.
Returns:
a method name that can handle this request. Never returns null; throws exception
Throws:
NoSuchRequestHandlingMethodException - if no method can be found for this URL


Rod Johnson and Spring contributors 2001-2003.