org.apache.tools.ant.taskdefs.optional.javacc
public class JavaCC extends Task
Field Summary | |
---|---|
protected static String[] | ARCHIVE_LOCATIONS |
protected static int[] | ARCHIVE_LOCATIONS_VS_MAJOR_VERSION |
protected static String | COM_JAVACC_CLASS |
protected static String | COM_JJDOC_CLASS |
protected static String | COM_JJTREE_CLASS |
protected static String | COM_PACKAGE |
protected static String | ORG_JAVACC_CLASS |
protected static String | ORG_JJDOC_CLASS |
protected static String | ORG_JJTREE_CLASS |
protected static String | ORG_PACKAGE_3_0 |
protected static String | ORG_PACKAGE_3_1 |
protected static int | TASKDEF_TYPE_JAVACC |
protected static int | TASKDEF_TYPE_JJDOC |
protected static int | TASKDEF_TYPE_JJTREE |
Constructor Summary | |
---|---|
JavaCC()
Constructor |
Method Summary | |
---|---|
void | execute()
Run the task. |
protected static File | getArchiveFile(File home)
Helper method to retrieve the path used to store the JavaCC.zip
or javacc.jar which is different from versions.
|
protected static String | getMainClass(File home, int type)
Helper method to retrieve main class which is different from versions. |
protected static String | getMainClass(Path path, int type)
Helper method to retrieve main class which is different from versions. |
protected static int | getMajorVersionNumber(File home)
Helper method to determine the major version number of JavaCC.
|
void | setBuildparser(boolean buildParser)
Sets the BUILD_PARSER grammar option. |
void | setBuildtokenmanager(boolean buildTokenManager)
Sets the BUILD_TOKEN_MANAGER grammar option. |
void | setCachetokens(boolean cacheTokens)
Sets the CACHE_TOKENS grammar option. |
void | setChoiceambiguitycheck(int choiceAmbiguityCheck)
Sets the CHOICE_AMBIGUITY_CHECK grammar option. |
void | setCommontokenaction(boolean commonTokenAction)
Sets the COMMON_TOKEN_ACTION grammar option. |
void | setDebuglookahead(boolean debugLookahead)
Sets the DEBUG_LOOKAHEAD grammar option. |
void | setDebugparser(boolean debugParser)
Sets the DEBUG_PARSER grammar option. |
void | setDebugtokenmanager(boolean debugTokenManager)
Sets the DEBUG_TOKEN_MANAGER grammar option. |
void | setErrorreporting(boolean errorReporting)
Sets the ERROR_REPORTING grammar option. |
void | setForcelacheck(boolean forceLACheck)
Sets the FORCE_LA_CHECK grammar option. |
void | setIgnorecase(boolean ignoreCase)
Sets the IGNORE_CASE grammar option. |
void | setJavacchome(File javaccHome)
The directory containing the JavaCC distribution. |
void | setJavaunicodeescape(boolean javaUnicodeEscape)
Sets the JAVA_UNICODE_ESCAPE grammar option. |
void | setJDKversion(String jdkVersion)
Sets the JDK_VERSION option. |
void | setKeeplinecolumn(boolean keepLineColumn)
Sets the KEEP_LINE_COLUMN grammar option. |
void | setLookahead(int lookahead)
Sets the LOOKAHEAD grammar option. |
void | setMaxmemory(String max)
Corresponds -Xmx.
|
void | setOptimizetokenmanager(boolean optimizeTokenManager)
Sets the OPTIMIZE_TOKEN_MANAGER grammar option. |
void | setOtherambiguityCheck(int otherAmbiguityCheck)
Sets the OTHER_AMBIGUITY_CHECK grammar option. |
void | setOutputdirectory(File outputDirectory)
The directory to write the generated files to.
|
void | setSanitycheck(boolean sanityCheck)
Sets the SANITY_CHECK grammar option. |
void | setStatic(boolean staticParser)
Sets the STATIC grammar option. |
void | setTarget(File targetFile)
The grammar file to process. |
void | setUnicodeinput(boolean unicodeInput)
Sets the UNICODE_INPUT grammar option. |
void | setUsercharstream(boolean userCharStream)
Sets the USER_CHAR_STREAM grammar option. |
void | setUsertokenmanager(boolean userTokenManager)
Sets the USER_TOKEN_MANAGER grammar option. |
Throws: BuildException on error.
Parameters: home the javacc home path directory.
Returns: the file object pointing to the JavaCC archive.
Throws: BuildException thrown if the home directory is invalid or if the archive could not be found despite attempts to do so.
Parameters: home the javacc home path directory. type the taskdef.
Returns: the main class for the taskdef.
Throws: BuildException thrown if the home directory is invalid or if the archive could not be found despite attempts to do so.
Parameters: path classpath to search in. type the taskdef.
Returns: the main class for the taskdef.
Throws: BuildException thrown if the home directory is invalid or if the archive could not be found despite attempts to do so.
Since: Ant 1.7
Parameters: home the javacc home path directory.
Returns: a the major version number
Throws: BuildException thrown if the home directory is invalid or if the archive could not be found despite attempts to do so.
Parameters: buildParser a boolean
value.
Parameters: buildTokenManager a boolean
value.
Parameters: cacheTokens a boolean
value.
Parameters: choiceAmbiguityCheck an int
value.
Parameters: commonTokenAction a boolean
value.
Parameters: debugLookahead a boolean
value.
Parameters: debugParser a boolean
value.
Parameters: debugTokenManager a boolean
value.
Parameters: errorReporting a boolean
value.
Parameters: forceLACheck a boolean
value.
Parameters: ignoreCase a boolean
value.
Parameters: javaccHome the directory.
Parameters: javaUnicodeEscape a boolean
value.
Parameters: jdkVersion the version to use.
Since: Ant1.7
Parameters: keepLineColumn a boolean
value.
Parameters: lookahead an int
value.
Parameters: max max memory parameter.
Since: Ant 1.8.3
Parameters: optimizeTokenManager a boolean
value.
Parameters: otherAmbiguityCheck an int
value.
Parameters: outputDirectory the output directory.
Parameters: sanityCheck a boolean
value.
Parameters: staticParser a boolean
value.
Parameters: targetFile the grammar file.
Parameters: unicodeInput a boolean
value.
Parameters: userCharStream a boolean
value.
Parameters: userTokenManager a boolean
value.