public class StaticContentHandler extends ResourceHandler
| Modifier and Type | Field and Description |
|---|---|
static int |
SERVER_DELAY |
| Constructor and Description |
|---|
StaticContentHandler(String debugURL,
boolean proxyInjectionMode) |
| Modifier and Type | Method and Description |
|---|---|
void |
addStaticContent(ResourceLocator locator) |
protected void |
callSuperHandle(String pathInContext,
String pathParams,
HttpRequest httpRequest,
HttpResponse httpResponse) |
protected Resource |
getResource(String pathInContext)
get Resource to serve.
|
static boolean |
getSlowResources() |
void |
handle(String pathInContext,
String pathParams,
HttpRequest httpRequest,
HttpResponse httpResponse)
Handle a request.
|
void |
sendData(HttpRequest request,
HttpResponse response,
String pathInContext,
Resource resource,
boolean writeHeaders) |
static void |
setSlowResources(boolean slowResources) |
getAllowedMethods, getAllowedString, getMinGzipLength, getRedirectWelcome, handleGet, isAcceptRanges, isDirAllowed, isMethodAllowed, setAcceptRanges, setAllowedMethods, setDirAllowed, setMinGzipLength, setRedirectWelcome, start, stop, writeHeadersgetHttpContext, getName, handleTrace, initialize, isStarted, setName, toStringpublic static final int SERVER_DELAY
public StaticContentHandler(String debugURL, boolean proxyInjectionMode)
public void handle(String pathInContext, String pathParams, HttpRequest httpRequest, HttpResponse httpResponse) throws IOException
HttpHandlerhandle in interface HttpHandlerhandle in class ResourceHandlerpathInContext - The context pathpathParams - Path parameters such as encoded Session IDhttpRequest - The HttpRequest requesthttpResponse - The HttpResponse responseIOExceptionprotected void callSuperHandle(String pathInContext, String pathParams, HttpRequest httpRequest, HttpResponse httpResponse) throws IOException
IOExceptionprotected Resource getResource(String pathInContext) throws IOException
ResourceHandlergetResource in class ResourceHandlerpathInContext - The path to find a resource for.IOExceptionpublic void addStaticContent(ResourceLocator locator)
public void sendData(HttpRequest request, HttpResponse response, String pathInContext, Resource resource, boolean writeHeaders) throws IOException
sendData in class ResourceHandlerIOExceptionpublic static void setSlowResources(boolean slowResources)
public static boolean getSlowResources()
Copyright © 2013. All rights reserved.