| javax.servlet.http.HttpServlet org.mortbay.jetty.servlet.DefaultServlet
DefaultServlet | public class DefaultServlet extends HttpServlet implements ResourceFactory(Code) | | The default servlet.
This servlet, normally mapped to /, provides the handling for static
content, OPTION and TRACE methods for the context.
The following initParameters are supported:
acceptRanges If true, range requests and responses are
supported
dirAllowed If true, directory listings are returned if no
welcome file is found. Else 403 Forbidden.
redirectWelcome If true, welcome files are redirected rather than
forwarded to.
gzip If set to true, then static content will be served as
gzip content encoded if a matching resource is
found ending with ".gz"
resourceBase Set to replace the context resource base
relativeResourceBase
Set with a pathname relative to the base of the
servlet context root. Useful for only serving static content out
of only specific subdirectories.
aliases If True, aliases of resources are allowed (eg. symbolic
links and caps variations). May bypass security constraints.
maxCacheSize The maximum total size of the cache or 0 for no cache.
maxCachedFileSize The maximum size of a file to cache
maxCachedFiles The maximum number of files to cache
useFileMappedBuffer
If set to true, it will use mapped file buffer to serve static content
when using NIO connector. Setting this value to false means that
a direct buffer will be used instead of a mapped file buffer.
By default, this is set to true.
The MOVE method is allowed if PUT and DELETE are allowed
author: Greg Wilkins (gregw) author: Nigel Canonizado |
Method Summary | |
public void | destroy() | protected void | doGet(HttpServletRequest request, HttpServletResponse response) | protected void | doPost(HttpServletRequest request, HttpServletResponse response) | public Resource | getResource(String pathInContext) get Resource to serve.
Map a path to a resource. | public void | init() | protected boolean | passConditionalHeaders(HttpServletRequest request, HttpServletResponse response, Resource resource, HttpContent content) | protected void | sendData(HttpServletRequest request, HttpServletResponse response, boolean include, Resource resource, HttpContent content, Enumeration reqRanges) | protected void | sendDirectory(HttpServletRequest request, HttpServletResponse response, Resource resource, boolean parent) | protected void | writeHeaders(HttpServletResponse response, HttpContent content, long count) |
destroy | public void destroy()(Code) | | |
getResource | public Resource getResource(String pathInContext)(Code) | | get Resource to serve.
Map a path to a resource. The default implementation calls
HttpContext.getResource but derived servlets may provide
their own mapping.
Parameters: pathInContext - The path to find a resource for. The resource to serve. |
Methods inherited from javax.servlet.http.HttpServlet | protected void doDelete(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected void doHead(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected void doOptions(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected void doPut(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected void doTrace(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) protected long getLastModified(HttpServletRequest req)(Code)(Java Doc) protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException(Code)(Java Doc) public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException(Code)(Java Doc)
|
|
|