org.apache.jasper.servlet

Class JspServletWrapper


public class JspServletWrapper
extends java.lang.Object

The JSP engine (a.k.a Jasper). The servlet container is responsible for providing a URLClassLoader for the web application context Jasper is being used in. Jasper will try get the Tomcat ServletContext attribute for its ServletContext class loader, if that fails, it uses the parent class loader. In either case, it must be a URLClassLoader.

Authors:
Anil K. Vijendran
Harish Prabandham
Remy Maucherat
Kin-man Chung
Glenn Nielsen

Constructor Summary

JspServletWrapper(ServletContext servletContext, Options options, String tagFilePath, TagInfo tagInfo, JspRuntimeContext rctxt, URL tagFileJarUrl)

Method Summary

int
decTripCount()
void
destroy()
java.util.List
getDependants()
Get a list of files that the current page has source dependency on.
JspCompilationContext
getJspEngineContext()
Servlet
getServlet()
ServletContext
getServletContext()
int
incTripCount()
boolean
isTagFile()
Class
loadTagFile()
Compile (if needed) and load a tag file
Class
loadTagFilePrototype()
Compile and load a prototype for the Tag file.
void
service(HttpServletRequest request, HttpServletResponse response, boolean precompile)
void
setCompilationException(JasperException je)
Sets the compilation exception for this JspServletWrapper.
void
setReload(boolean reload)
void
setServletClassLastModifiedTime(long lastModified)
Sets the last-modified time of the servlet class file associated with this JspServletWrapper.

Constructor Details

JspServletWrapper

public JspServletWrapper(ServletContext servletContext,
                         Options options,
                         String tagFilePath,
                         TagInfo tagInfo,
                         JspRuntimeContext rctxt,
                         URL tagFileJarUrl)
            throws JasperException

Method Details

decTripCount

public int decTripCount()


destroy

public void destroy()


getDependants

public java.util.List getDependants()
Get a list of files that the current page has source dependency on.


getJspEngineContext

public JspCompilationContext getJspEngineContext()


getServlet

public Servlet getServlet()
            throws ServletException,
                   IOException,
                   FileNotFoundException


getServletContext

public ServletContext getServletContext()


incTripCount

public int incTripCount()


isTagFile

public boolean isTagFile()


loadTagFile

public Class loadTagFile()
            throws JasperException
Compile (if needed) and load a tag file


loadTagFilePrototype

public Class loadTagFilePrototype()
            throws JasperException
Compile and load a prototype for the Tag file. This is needed when compiling tag files with circular dependencies. A prototpe (skeleton) with no dependencies on other other tag files is generated and compiled.


service

public void service(HttpServletRequest request,
                    HttpServletResponse response,
                    boolean precompile)
            throws ServletException,
                   IOException,
                   FileNotFoundException


setCompilationException

public void setCompilationException(JasperException je)
Sets the compilation exception for this JspServletWrapper.

Parameters:
je - The compilation exception


setReload

public void setReload(boolean reload)


setServletClassLastModifiedTime

public void setServletClassLastModifiedTime(long lastModified)
Sets the last-modified time of the servlet class file associated with this JspServletWrapper.

Parameters:
lastModified - Last-modified time of servlet class


Copyright B) 2000 Apache Software Foundation. All Rights Reserved.