public final class CompileAll extends HttpServlet
jsp_precompile=true
therby compiling all JSP files into servlets.
This code is based on code written by Réal Gagnon: http://www.rgagnon.com/javadetails/java-0414.html
Modifier and Type | Field and Description |
---|---|
private static Comparator<String> |
pathComparator |
private static long |
serialVersionUID |
Constructor and Description |
---|
CompileAll() |
Modifier and Type | Method and Description |
---|---|
private boolean |
compile(String dir,
HttpServletRequest request,
HttpServletResponse response)
Compile all files found in dir, recursively entering subdirectories.
|
void |
doGet(HttpServletRequest request,
HttpServletResponse response) |
void |
doPost(HttpServletRequest request,
HttpServletResponse response) |
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log
private static final long serialVersionUID
private static final Comparator<String> pathComparator
public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException
doGet
in class HttpServlet
IOException
ServletException
public void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException
doPost
in class HttpServlet
IOException
ServletException
private boolean compile(String dir, HttpServletRequest request, HttpServletResponse response) throws IOException
dir
- The starting directoryIOException