org.springframework.web.context.support
Class HttpRequestHandlerServlet

java.lang.Object
  extended by HttpServlet
      extended by org.springframework.web.context.support.HttpRequestHandlerServlet

public class HttpRequestHandlerServlet
extends HttpServlet

Simple HttpServlet that delegates to an HttpRequestHandler bean defined in Spring's root web application context. The target bean name must match the HttpRequestHandlerServlet servlet-name as defined in web.xml.

This can for example be used to expose a single Spring remote exporter, such as HttpInvokerServiceExporter or HessianServiceExporter, per HttpRequestHandlerServlet definition. This is a minimal alternative to defining remote exporters as beans in a DispatcherServlet context (with advanced mapping and interception facilities being available there).

Since:
2.0
Author:
Juergen Hoeller
See Also:
HttpRequestHandler, DispatcherServlet

Field Summary
private  HttpRequestHandler target
           
 
Constructor Summary
HttpRequestHandlerServlet()
           
 
Method Summary
 void init()
           
protected  void service(HttpServletRequest request, HttpServletResponse response)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

target

private HttpRequestHandler target
Constructor Detail

HttpRequestHandlerServlet

public HttpRequestHandlerServlet()
Method Detail

init

public void init()
          throws ServletException
Throws:
ServletException

service

protected void service(HttpServletRequest request,
                       HttpServletResponse response)
                throws ServletException,
                       java.io.IOException
Throws:
ServletException
java.io.IOException