|
|
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jasper.JspC
Shell for the jspc compiler. Handles all options associated with the command line and creates compilation contexts which it then compiles according to the specified options. This version can process files from a _single_ webapp at once, i.e. a single docbase can be specified. It can be used as a Ant task using:
<taskdef classname="org.apache.jasper.JspC" name="jasper2" > <classpath> <pathelement location="${java.home}/../lib/tools.jar"/> <fileset dir="${ENV.CATALINA_HOME}/server/lib"> <include name="*.jar"/> </fileset> <fileset dir="${ENV.CATALINA_HOME}/common/lib"> <include name="*.jar"/> </fileset> <path refid="myjars"/> </classpath> </taskdef> <jasper2 verbose="0" package="my.package" uriroot="${webapps.dir}/${webapp.name}" webXmlFragment="${build.dir}/generated_web.xml" outputDir="${webapp.dir}/${webapp.name}/WEB-INF/src/my/package" />
Field Summary | |
static int |
ALL_WEBXML
|
static int |
DEFAULT_DIE_LEVEL
|
static java.lang.String |
DEFAULT_IE_CLASS_ID
|
static int |
INC_WEBXML
|
static java.lang.String |
LIST_ERRORS
|
static int |
NO_DIE_LEVEL
|
static int |
NO_WEBXML
|
static java.lang.String |
SHOW_SUCCESS
|
static java.lang.String |
SWITCH_CLASS_NAME
|
static java.lang.String |
SWITCH_COMPILE
|
static java.lang.String |
SWITCH_DIE
|
static java.lang.String |
SWITCH_FILE_WEBAPP
|
static java.lang.String |
SWITCH_FULL_STOP
|
static java.lang.String |
SWITCH_IE_CLASS_ID
|
static java.lang.String |
SWITCH_MAPPED
|
static java.lang.String |
SWITCH_OUTPUT_DIR
|
static java.lang.String |
SWITCH_OUTPUT_SIMPLE_DIR
|
static java.lang.String |
SWITCH_PACKAGE_NAME
|
static java.lang.String |
SWITCH_QUIET
|
static java.lang.String |
SWITCH_URI_BASE
|
static java.lang.String |
SWITCH_URI_ROOT
|
static java.lang.String |
SWITCH_VERBOSE
|
static java.lang.String |
SWITCH_WEBAPP_INC
|
static java.lang.String |
SWITCH_WEBAPP_XML
|
Constructor Summary | |
JspC()
|
Method Summary | |
void |
execute()
|
void |
generateWebMapping(java.lang.String file,
JspCompilationContext clctxt)
|
int |
getCheckInterval()
Background compilation check intervals in seconds |
boolean |
getClassDebugInfo()
Should we include debug information in compiled class? |
java.lang.String |
getClassPath()
What classpath should I use while compiling the servlets generated from JSP files? |
java.lang.String |
getCompiler()
Compiler to use. |
boolean |
getDevelopment()
Is Jasper being used in development mode? |
boolean |
getFork()
boolean flag to tell Ant whether to fork JSP page compilations. |
java.lang.String |
getIeClassId()
Class ID for use in the plugin tag when the browser is IE. |
java.lang.String |
getJavaEncoding()
Java platform encoding to generate the JSP page servlet. |
java.lang.String |
getJspCompilerPath()
|
java.lang.Class |
getJspCompilerPlugin()
|
int |
getJspVerbosityLevel()
|
boolean |
getKeepGenerated()
Are we keeping generated code around? |
boolean |
getMappedFile()
Are we supporting HTML mapped servlets? |
java.lang.Object |
getProtectionDomain()
|
boolean |
getReloading()
JSP reloading check ? |
java.io.File |
getScratchDir()
What is my scratch dir? |
boolean |
getSendErrorToClient()
Should errors be sent to client or thrown into stderr? |
TldLocationsCache |
getTldLocationsCache()
The cache for the location of the TLD's for the various tag libraries 'exposed' by the web application. |
boolean |
isPoolingEnabled()
Returns true if tag handler pooling is enabled, false otherwise. |
static void |
main(java.lang.String[] arg)
|
boolean |
processFile(java.lang.String file)
|
void |
scanFiles(java.io.File base)
Locate all jsp files in the webapp. |
void |
setClassDebugInfo(boolean b)
|
void |
setClassName(java.lang.String p)
Class name of the generated file ( without package ). |
void |
setClassPath(java.lang.String s)
|
void |
setCompile(boolean b)
|
void |
setCompiler(java.lang.String c)
|
static void |
setLog(java.io.PrintStream log)
allows user to set where the log goes other than System.out |
void |
setOutputDir(java.lang.String s)
|
void |
setPackage(java.lang.String p)
|
void |
setUriroot(java.lang.String s)
Base dir for the webapp. |
void |
setValidateXml(boolean b)
|
void |
setVerbose(int level)
|
void |
setWebXmlFragment(java.lang.String s)
File where we generate a web.xml fragment with the class definitions. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String DEFAULT_IE_CLASS_ID
public static final java.lang.String SWITCH_VERBOSE
public static final java.lang.String SWITCH_QUIET
public static final java.lang.String SWITCH_OUTPUT_DIR
public static final java.lang.String SWITCH_OUTPUT_SIMPLE_DIR
public static final java.lang.String SWITCH_IE_CLASS_ID
public static final java.lang.String SWITCH_PACKAGE_NAME
public static final java.lang.String SWITCH_CLASS_NAME
public static final java.lang.String SWITCH_FULL_STOP
public static final java.lang.String SWITCH_COMPILE
public static final java.lang.String SWITCH_URI_BASE
public static final java.lang.String SWITCH_URI_ROOT
public static final java.lang.String SWITCH_FILE_WEBAPP
public static final java.lang.String SWITCH_WEBAPP_INC
public static final java.lang.String SWITCH_WEBAPP_XML
public static final java.lang.String SWITCH_MAPPED
public static final java.lang.String SWITCH_DIE
public static final java.lang.String SHOW_SUCCESS
public static final java.lang.String LIST_ERRORS
public static final int NO_WEBXML
public static final int INC_WEBXML
public static final int ALL_WEBXML
public static final int DEFAULT_DIE_LEVEL
public static final int NO_DIE_LEVEL
Constructor Detail |
public JspC()
Method Detail |
public boolean getKeepGenerated()
Options
getKeepGenerated
in interface Options
public boolean isPoolingEnabled()
Options
isPoolingEnabled
in interface Options
public boolean getMappedFile()
getMappedFile
in interface Options
public java.lang.Object getProtectionDomain()
public boolean getSendErrorToClient()
Options
getSendErrorToClient
in interface Options
public void setClassDebugInfo(boolean b)
public boolean getClassDebugInfo()
Options
getClassDebugInfo
in interface Options
public int getCheckInterval()
getCheckInterval
in interface Options
public boolean getDevelopment()
getDevelopment
in interface Options
public boolean getReloading()
getReloading
in interface Options
public java.lang.String getIeClassId()
Options
getIeClassId
in interface Options
public int getJspVerbosityLevel()
public java.io.File getScratchDir()
Options
getScratchDir
in interface Options
public java.lang.Class getJspCompilerPlugin()
public java.lang.String getJspCompilerPath()
public java.lang.String getCompiler()
getCompiler
in interface Options
public void setCompiler(java.lang.String c)
public TldLocationsCache getTldLocationsCache()
Options
getTldLocationsCache
in interface Options
public java.lang.String getJavaEncoding()
Options
getJavaEncoding
in interface Options
public boolean getFork()
Options
getFork
in interface Options
public java.lang.String getClassPath()
Options
getClassPath
in interface Options
public void setClassPath(java.lang.String s)
public void setUriroot(java.lang.String s)
public void setVerbose(int level)
public void setCompile(boolean b)
public void setValidateXml(boolean b)
public void setOutputDir(java.lang.String s)
public void setPackage(java.lang.String p)
public void setClassName(java.lang.String p)
public void setWebXmlFragment(java.lang.String s)
public void generateWebMapping(java.lang.String file, JspCompilationContext clctxt) throws java.io.IOException
java.io.IOException
public boolean processFile(java.lang.String file) throws JasperException
JasperException
public void scanFiles(java.io.File base)
public void execute() throws JasperException
JasperException
public static void main(java.lang.String[] arg)
public static void setLog(java.io.PrintStream log)
log
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |