Home » apache-tomcat-6.0.26-src » org.apache » jasper » compiler » [javadoc | source]
org.apache.jasper.compiler
abstract public class: Compiler [javadoc | source]
java.lang.Object
   org.apache.jasper.compiler.Compiler

Direct Known Subclasses:
    JspCompiler, AntCompiler, JDTCompiler, JCICompiler

Main JSP compiler class. This class uses Ant for compiling.
Field Summary
protected  Log log     
protected  JspCompilationContext ctxt     
protected  ErrorDispatcher errDispatcher     
protected  PageInfo pageInfo     
protected  JspServletWrapper jsw     
protected  TagFileProcessor tfp     
protected  Options options     
protected  Nodes pageNodes     
Method from org.apache.jasper.compiler.Compiler Summary:
compile,   compile,   compile,   generateClass,   generateJava,   getCompilationContext,   getErrorDispatcher,   getPageInfo,   getPageNodes,   init,   isOutDated,   isOutDated,   removeGeneratedClassFiles,   removeGeneratedFiles
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.jasper.compiler.Compiler Detail:
 public  void compile() throws FileNotFoundException, JasperException, Exception 
    Compile the jsp file from the current engine context
 public  void compile(boolean compileClass) throws FileNotFoundException, JasperException, Exception 
    Compile the jsp file from the current engine context. As an side- effect, tag files that are referenced by this page are also compiled.
 public  void compile(boolean compileClass,
    boolean jspcMode) throws FileNotFoundException, JasperException, Exception 
    Compile the jsp file from the current engine context. As an side- effect, tag files that are referenced by this page are also compiled.
 abstract protected  void generateClass(String[] smap) throws FileNotFoundException, JasperException, Exception
    Compile the servlet from .java file to .class file
 protected String[] generateJava() throws Exception 
    Compile the jsp file into equivalent servlet in .java file
 public JspCompilationContext getCompilationContext() 
 public ErrorDispatcher getErrorDispatcher() 
    Gets the error dispatcher.
 public PageInfo getPageInfo() 
    Gets the info about the page under compilation
 public Nodes getPageNodes() 

    Retrieves the parsed nodes of the JSP page, if they are available. May return null. Used in development mode for generating detailed error messages. http://issues.apache.org/bugzilla/show_bug.cgi?id=37062.

 public  void init(JspCompilationContext ctxt,
    JspServletWrapper jsw) 
 public boolean isOutDated() 
    This is a protected method intended to be overridden by subclasses of Compiler. This is used by the compile method to do all the compilation.
 public boolean isOutDated(boolean checkClass) 
    Determine if a compilation is necessary by checking the time stamp of the JSP page with that of the corresponding .class or .java file. If the page has dependencies, the check is also extended to its dependeants, and so on. This method can by overidden by a subclasses of Compiler.
 public  void removeGeneratedClassFiles() 
 public  void removeGeneratedFiles() 
    Remove generated files