|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.servlet.GenericServlet
javax.servlet.http.HttpServlet
org.apache.myfaces.trinidad.webapp.ResourceServlet
public class ResourceServlet
A Servlet which serves up web application resources (images, style sheets, JavaScript libraries) by delegating to a ResourceLoader. The servlet path at which this servlet is registered is used to lookup the class name of the resource loader implementation. For example, if this servlet is registered with name "resources" and URL pattern "/images/*", then its servlet path is "/images". This is used to construct the class loader lookup for the text file "/META-INF/servlets/resources/images.resources" which contains a single line entry with the class name of the resource loader to use. This technique is very similar to "/META-INF/services" lookup that allows the implementation object to implement an interface in the public API and be used by the public API but reside in a private implementation JAR.
Field Summary | |
---|---|
static String |
DEBUG_INIT_PARAM
Context parameter for activating debug mode, which will disable caching. |
static long |
ONE_YEAR_MILLIS
|
Constructor Summary | |
---|---|
ResourceServlet()
|
Method Summary | |
---|---|
void |
destroy()
Override of Servlet.destroy(); |
protected void |
doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Override of HttpServlet.doGet() |
protected long |
getLastModified(javax.servlet.http.HttpServletRequest request)
Override of HttpServlet.getLastModified() |
protected String |
getResourcePath(javax.servlet.http.HttpServletRequest request)
Returns the resource path from the http servlet request. |
void |
init(javax.servlet.ServletConfig config)
Override of Servlet.init(); |
void |
service(javax.servlet.ServletRequest request,
javax.servlet.ServletResponse response)
|
Methods inherited from class javax.servlet.http.HttpServlet |
---|
doDelete, doHead, doOptions, doPost, doPut, doTrace, service |
Methods inherited from class javax.servlet.GenericServlet |
---|
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEBUG_INIT_PARAM
public static final long ONE_YEAR_MILLIS
Constructor Detail |
---|
public ResourceServlet()
Method Detail |
---|
public void destroy()
destroy
in interface javax.servlet.Servlet
destroy
in class javax.servlet.GenericServlet
public void init(javax.servlet.ServletConfig config) throws javax.servlet.ServletException
init
in interface javax.servlet.Servlet
init
in class javax.servlet.GenericServlet
javax.servlet.ServletException
public void service(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response) throws javax.servlet.ServletException, IOException
service
in interface javax.servlet.Servlet
service
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
doGet
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected long getLastModified(javax.servlet.http.HttpServletRequest request)
getLastModified
in class javax.servlet.http.HttpServlet
protected String getResourcePath(javax.servlet.http.HttpServletRequest request)
request
- the http servlet request
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |