| java.lang.Object org.apache.jasper.JspCompilationContext
JspCompilationContext | public class JspCompilationContext (Code) | | A place holder for various things that are used through out the JSP
engine. This is a per-request/per-context data structure. Some of
the instance variables are set at different points.
Most of the path-related stuff is here - mangling names, versions, dirs,
loading resources and dealing with uris.
author: Anil K. Vijendran author: Harish Prabandham author: Pierre Delisle author: Costin Manolache author: Kin-man Chung |
Constructor Summary | |
public | JspCompilationContext(String jspUri, boolean isErrPage, Options options, ServletContext context, JspServletWrapper jsw, JspRuntimeContext rctxt) | public | JspCompilationContext(String tagfile, TagInfo tagInfo, Options options, ServletContext context, JspServletWrapper jsw, JspRuntimeContext rctxt, URL tagFileJarUrl) |
isErrPage | protected boolean isErrPage(Code) | | |
isPackagedTagFile | protected boolean isPackagedTagFile(Code) | | |
isTagFile | protected boolean isTagFile(Code) | | |
jsw | protected JspServletWrapper jsw(Code) | | |
log | protected org.apache.juli.logging.Log log(Code) | | |
options | protected Options options(Code) | | |
protoTypeMode | protected boolean protoTypeMode(Code) | | |
rctxt | protected JspRuntimeContext rctxt(Code) | | |
removed | protected int removed(Code) | | |
servletJavaFileName | protected String servletJavaFileName(Code) | | |
tagFileJarUrl | protected URL tagFileJarUrl(Code) | | |
writer | protected ServletWriter writer(Code) | | |
JspCompilationContext | public JspCompilationContext(String jspUri, boolean isErrPage, Options options, ServletContext context, JspServletWrapper jsw, JspRuntimeContext rctxt)(Code) | | |
JspCompilationContext | public JspCompilationContext(String tagfile, TagInfo tagInfo, Options options, ServletContext context, JspServletWrapper jsw, JspRuntimeContext rctxt, URL tagFileJarUrl)(Code) | | |
checkOutputDir | public void checkOutputDir()(Code) | | |
createCompiler | public Compiler createCompiler() throws JasperException(Code) | | Create a "Compiler" object based on some init param data. This
is not done yet. Right now we're just hardcoding the actual
compilers that are created.
|
createOutputDir | protected void createOutputDir()(Code) | | |
getClassLoader | public ClassLoader getClassLoader()(Code) | | What class loader to use for loading classes while compiling
this JSP?
|
getClassPath | public String getClassPath()(Code) | | The classpath that is passed off to the Java compiler.
|
getContentType | public String getContentType()(Code) | | Get the content type of this JSP.
Content type includes content type and encoding.
|
getDerivedPackageName | protected String getDerivedPackageName()(Code) | | |
getJavaPath | public String getJavaPath()(Code) | | Path of the Java file relative to the work directory.
|
getJspFile | public String getJspFile()(Code) | | Path of the JSP URI. Note that this is not a file name. This is
the context rooted URI of the JSP file.
|
getOptions | public Options getOptions()(Code) | | Get hold of the Options object for this context.
|
getOutputDir | public String getOutputDir()(Code) | | The output directory to generate code into. The output directory
is make up of the scratch directory, which is provide in Options,
plus the directory derived from the package name.
|
getRealPath | public String getRealPath(String path)(Code) | | Gets the actual path of a URI relative to the context of
the compilation.
|
getResourceAsStream | public java.io.InputStream getResourceAsStream(String res)(Code) | | Gets a resource as a stream, relative to the meanings of this
context's implementation.
a null if the resource cannot be found or represented as an InputStream. |
getRuntimeContext | public JspRuntimeContext getRuntimeContext()(Code) | | |
getServletClassName | public String getServletClassName()(Code) | | Just the class name (does not include package name) of the
generated class.
|
getServletJavaFileName | public String getServletJavaFileName()(Code) | | Full path name of the Java file into which the servlet is being
generated.
|
getServletPackageName | public String getServletPackageName()(Code) | | Package name for the generated class is make up of the base package
name, which is user settable, and the derived package name. The
derived package name directly mirrors the file heirachy of the JSP page.
|
getTagFileJarUrl | public URL getTagFileJarUrl(String tagFile)(Code) | | Returns the tag-file-name-to-JAR-file map of this compilation unit,
which maps tag file names to the JAR files in which the tag files are
packaged.
The map is populated when parsing the tag-file elements of the TLDs
of any imported taglibs.
|
getTagFileJarUrl | public URL getTagFileJarUrl()(Code) | | Returns the JAR file in which the tag file for which this
JspCompilationContext was created is packaged, or null if this
JspCompilationContext does not correspond to a tag file, or if the
corresponding tag file is not packaged in a JAR.
|
getTldLocation | public String[] getTldLocation(String uri) throws JasperException(Code) | | Gets the 'location' of the TLD associated with the given taglib 'uri'.
An array of two Strings: The first element denotes the realpath to the TLD. If the path to the TLD points to a jar file, then thesecond element denotes the name of the TLD entry in the jar file.Returns null if the given uri is not associated with any tag library'exposed' in the web application. |
getWriter | public ServletWriter getWriter()(Code) | | Where is the servlet being generated?
|
incrementRemoved | public void incrementRemoved()(Code) | | |
isErrorPage | public boolean isErrorPage()(Code) | | Are we processing something that has been declared as an
errorpage?
|
isPathSeparator | final protected static boolean isPathSeparator(char c)(Code) | | |
isPrototypeMode | public boolean isPrototypeMode()(Code) | | True if we are compiling a tag file in prototype mode.
ie we only generate codes with class for the tag handler with empty
method bodies.
|
isRemoved | public boolean isRemoved()(Code) | | |
isTagFile | public boolean isTagFile()(Code) | | |
keepGenerated | public boolean keepGenerated()(Code) | | Are we keeping generated code around?
|
makeOutputDir | protected boolean makeOutputDir()(Code) | | |
resolveRelativeUri | public String resolveRelativeUri(String uri)(Code) | | Get the full value of a URI relative to this compilations context
uses current file as the base.
|
setClassPath | public void setClassPath(String classPath)(Code) | | The classpath that is passed off to the Java compiler.
|
setContentType | public void setContentType(String contentType)(Code) | | |
setErrorPage | public void setErrorPage(boolean isErrPage)(Code) | | |
setPrototypeMode | public void setPrototypeMode(boolean pm)(Code) | | |
setServletClassName | public void setServletClassName(String className)(Code) | | |
setServletPackageName | public void setServletPackageName(String servletPackageName)(Code) | | The package name into which the servlet class is generated.
|
setTagFileJarUrl | public void setTagFileJarUrl(String tagFile, URL tagFileURL)(Code) | | |
setWriter | public void setWriter(ServletWriter writer)(Code) | | |
|
|