public class HttpServletContainerImpl extends Object implements HttpServletContainer, HttpServletServicer, FilterChain
HttpServletContainer implementation.| Constructor and Description |
|---|
HttpServletContainerImpl(String servletName,
HttpServlet servlet,
Map<String,String> initParameters,
OfficeServletContext officeServletContext,
net.officefloor.frame.api.manage.Office office,
Clock clock,
Locale defaultLocale)
Initiate.
|
| Modifier and Type | Method and Description |
|---|---|
void |
doFilter(ServletRequest request,
ServletResponse response) |
String[] |
getServletMappings()
Obtains the mappings that are handled by this
HttpServletServicer. |
String |
getServletName()
Obtains the name of this
HttpServletServicer. |
void |
include(HttpServletRequest request,
HttpServletResponse response)
Includes the servicing of contained
HttpServlet on the inputs. |
void |
include(OfficeServletContext context,
HttpServletRequest request,
HttpServletResponse response)
Includes the content from this
HttpServlet. |
void |
service(net.officefloor.plugin.socket.server.http.ServerHttpConnection connection,
HttpRequestState attributes,
HttpSession session,
HttpServletSecurity security,
net.officefloor.frame.api.execute.TaskContext<?,?,?> taskContext,
ServicerMapping mapping)
Services the
HttpRequest of the ServerHttpConnection. |
public HttpServletContainerImpl(String servletName, HttpServlet servlet, Map<String,String> initParameters, OfficeServletContext officeServletContext, net.officefloor.frame.api.manage.Office office, Clock clock, Locale defaultLocale) throws ServletException
servletName - Name of the Servlet.servlet - HttpServlet.initParameters - Init parameters for the ServletConfig.officeServletContext - OfficeServletContext.office - Office.clock - Clock.defaultLocale - Default Locale.ServletException - If fails to initialise the HttpServlet.public void service(net.officefloor.plugin.socket.server.http.ServerHttpConnection connection,
HttpRequestState attributes,
HttpSession session,
HttpServletSecurity security,
net.officefloor.frame.api.execute.TaskContext<?,?,?> taskContext,
ServicerMapping mapping)
throws ServletException,
IOException
HttpServletContainerHttpRequest of the ServerHttpConnection.service in interface HttpServletContainerconnection - ServerHttpConnection containing the
HttpRequest to service.attributes - HttpRequestState.session - HttpSession for the HttpRequest.security - HttpServletSecurity. May be null if
anonymous HttpRequest.taskContext - TaskContext to allow access to OfficeFloor
capabilities.mapping - ServicerMapping that mapped the HttpRequest to
the HttpServlet. May be null if not
mapped.ServletException - As per HttpServlet API.IOException - As per HttpServlet API.public void include(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
HttpServletContainerHttpServlet on the inputs.include in interface HttpServletContainerrequest - HttpServletRequest.response - HttpServletResponse.ServletException - As per HttpServlet API.IOException - As per HttpServlet API.public String getServletName()
HttpServletServicer
Obtains the name of this HttpServletServicer.
This will be used to find this HttpServletServicer by name.
getServletName in interface HttpServletServicerHttpServletServicer name.public String[] getServletMappings()
HttpServletServicer
Obtains the mappings that are handled by this HttpServletServicer.
The mappings are of the form:
/some/path.extension: for exact mapping (extension is
optional)/wild/card/*: for path wild card mapping*.extension: for extension mapping
This follows the Servlet specification in regards to mappings.
getServletMappings in interface HttpServletServicerHttpServletServicer.ServicerMapperpublic void include(OfficeServletContext context, HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
HttpServletServicerHttpServlet.include in interface HttpServletServicercontext - OfficeServletContext.request - HttpServletRequest.response - HttpServletResponse.ServletException - As per RequestDispatcher.IOException - As per RequestDispatcher.public void doFilter(ServletRequest request, ServletResponse response) throws IOException, ServletException
doFilter in interface FilterChainIOExceptionServletExceptionCopyright © 2005–2015. All rights reserved.