Tuscany Core

org.apache.tuscany.core.webapp
Interface ServletHost


public interface ServletHost

Service interface implemented by host environments that allow Servlets to be registered.

This interface allows an SCA system component to register a servlet to handle inbound requests.

Version:
$Rev$ $Date$

Method Summary
 javax.servlet.Servlet getMapping(java.lang.String mapping)
          Deprecated. 
 void registerMapping(java.lang.String mapping, javax.servlet.Servlet servlet)
          Register a mapping for an instance of a Servlet.
 void unregisterMapping(java.lang.String mapping)
          Unregister a servlet mapping.
 

Method Detail

registerMapping

void registerMapping(java.lang.String mapping,
                     javax.servlet.Servlet servlet)
Register a mapping for an instance of a Servlet. This requests that the servlet container direct all requests to the designated mapping to the supplied Servlet instance.

Parameters:
mapping - the uri-mapping for the Servlet
servlet - the Servlet that should be invoked

unregisterMapping

void unregisterMapping(java.lang.String mapping)
Unregister a servlet mapping. This directs the servlet contain not to direct any more requests to a previously registered Servlet.

Parameters:
mapping - the uri-mapping for the Servlet

getMapping

@Deprecated
javax.servlet.Servlet getMapping(java.lang.String mapping)
Deprecated. 

Get the servlet instance registered for the mapping.

Parameters:
mapping - the uri-mapping for the Servlet
Returns:
the Servelt for the mapping or null if there is no Servlet registered for the mapping

Tuscany Core

-