public class PortMapper extends Object
Constructor and Description |
---|
PortMapper(int port) |
Modifier and Type | Method and Description |
---|---|
void |
addRequestHandler(String host,
String firstPath,
RequestHandler requestHandler)
Register the RequestHandler to accept requests for the given host and
port.
|
RequestHandlerContext |
getRequestHandlerContext(javax.servlet.http.HttpServletRequest request)
Attempts to locate the most strictly matching RequestHandler mapped to
this port.
|
public PortMapper(int port)
port
- which this PortMapper is responsible for handlingpublic void addRequestHandler(String host, String firstPath, RequestHandler requestHandler)
host
- the HTTP 1.1 "Host" header which the RequestHandler should
match. If null, the RequestHandler matches any "Host" header value.firstPath
- the first path of the GET request path which the
RequestHandler should match. This is the first path AFTER the name the
Wayback webapp is deployed under. If null, the RequestHandler matches
all paths.requestHandler
- The RequestHandler to register.public RequestHandlerContext getRequestHandlerContext(javax.servlet.http.HttpServletRequest request)
request
- the HttpServletRequest to be mapped to a RequestHandlerCopyright © 2005–2015 IIPC. All rights reserved.