Package rife.bld.extension
Class Antlr4Operation
java.lang.Object
rife.bld.operations.AbstractOperation<Antlr4Operation>
rife.bld.extension.Antlr4Operation
Generates Java sources from ANTLR grammars.
- Since:
- 1.0
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionRetrieves the list of arguments that will be used for the antlr operation.Provides additional arguments for the antlr operation.Provides additional arguments for the antlr operation.depend()Generate file dependencies.voidexecute()Performs the antlr operation.grammarEncoding(String encoding) Provides grammar file encoding; e.g., euc-jp.Retrieves the location of grammars and tokens files.libDirectory(File directory) Provides the location of grammars and tokens files.libDirectory(String directory) Provides the location of grammars and tokens files.libDirectory(Path directory) Provides the location of grammars and tokens files.listener()Generate parse tree listener (default).Show exception details when available for errors and warnings.Specify output style for messages in antlr, gnu, vs2005.Don't generate parse tree listener.Don't generate parse tree visitor (default).Retrieves the output directory where all output is generated.outputDirectory(File directory) Provides the output directory where all output is generated.outputDirectory(String directory) Provides the output directory where all output is generated.outputDirectory(Path directory) Provides the output directory where all output is generated.Specify a package/namespace for the generated codeRetrieves the list of source directories that will be used for the antlr operation.sourceDirectories(File... directories) Provides the source directories that will be used for the antlr operation.sourceDirectories(String... directories) Provides the source directories that will be used for the antlr operation.sourceDirectories(Path... directories) Provides the source directories that will be used for the antlr operation.sourceDirectories(List<File> directories) Provides the source directories that will be used for the antlr operation.sourceDirectoriesPaths(List<Path> directories) Provides the source directories that will be used for the antlr operation.sourceDirectoriesStrings(List<String> directories) Provides the source directories that will be used for the antlr operation.Retrieves the list of source files that will be used for the antlr operation.sourceFiles(File... files) Provides the source files that will be used for the antlr operation.sourceFiles(String... files) Provides the source files that will be used for the antlr operation.sourceFiles(Path... files) Provides the source files that will be used for the antlr operation.sourceFiles(List<File> files) Provides the source files that will be used for the antlr operation.sourceFilesPaths(List<Path> files) Provides the source files that will be used for the antlr operation.sourceFilesStrings(List<String> files) Provides the source files that will be used for the antlr operation.visitor()Generate parse tree visitor.Methods inherited from class rife.bld.operations.AbstractOperationexecuteOnce, executeOnce, silent, silent
- 
Constructor Details- 
Antlr4Operationpublic Antlr4Operation()
 
- 
- 
Method Details- 
executePerforms the antlr operation.- Specified by:
- executein class- rife.bld.operations.AbstractOperation<Antlr4Operation>
- Throws:
- Exception
- Since:
- 1.0
 
- 
argumentsProvides additional arguments for the antlr operation.The following additional arguments are supported: -atngenerate rule augmented transition network diagrams -D<option>=valueset/override a grammar-level option -Werrortreat warnings as errors" -XdbgSTlaunch StringTemplate visualizer on generated code -XdbgSTWaitwait for STViz to close before continuing -Xforce-atnuse the ATN simulator for all predictions -Xlogdump lots of logging info to antlr-timestamp.log -Xexact-output-dirall output goes into -o dir regardless of paths/package - Parameters:
- arguments- the additional arguments
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
argumentsProvides additional arguments for the antlr operation.See arguments(String...)for details.- Parameters:
- arguments- the additional arguments
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
sourceDirectoriesProvides the source directories that will be used for the antlr operation.- Parameters:
- directories- the source directories
- Returns:
- this operation instance
- Since:
- 1.0
- See Also:
 
- 
sourceDirectoriesProvides the source directories that will be used for the antlr operation.- Parameters:
- directories- the source directories
- Returns:
- this operation instance
- Since:
- 1.4
- See Also:
 
- 
sourceDirectoriesProvides the source directories that will be used for the antlr operation.- Parameters:
- directories- the source directories
- Returns:
- this operation instance
- Since:
- 1.4
- See Also:
 
- 
sourceDirectoriesProvides the source directories that will be used for the antlr operation.- Parameters:
- directories- the source directories
- Returns:
- this operation instance
- Since:
- 1.0
- See Also:
 
- 
sourceDirectoriesPathsProvides the source directories that will be used for the antlr operation.- Parameters:
- directories- the source directories
- Returns:
- this operation instance
- Since:
- 1.0
- See Also:
 
- 
sourceDirectoriesStringsProvides the source directories that will be used for the antlr operation.- Parameters:
- directories- the source directories
- Returns:
- this operation instance
- Since:
- 1.0
- See Also:
 
- 
sourceFilesProvides the source files that will be used for the antlr operation.- Parameters:
- files- the source files
- Returns:
- this operation instance
- Since:
- 1.0
- See Also:
 
- 
sourceFilesProvides the source files that will be used for the antlr operation.- Parameters:
- files- the source files
- Returns:
- this operation instance
- Since:
- 1.4
- See Also:
 
- 
sourceFilesProvides the source files that will be used for the antlr operation.- Parameters:
- files- the source files
- Returns:
- this operation instance
- Since:
- 1.4
- See Also:
 
- 
sourceFilesProvides the source files that will be used for the antlr operation.- Parameters:
- files- the source files
- Returns:
- this operation instance
- Since:
- 1.0
- See Also:
 
- 
sourceFilesPathsProvides the source files that will be used for the antlr operation.- Parameters:
- files- the source files
- Returns:
- this operation instance
- Since:
- 1.4
- See Also:
 
- 
sourceFilesStringsProvides the source files that will be used for the antlr operation.- Parameters:
- files- the source files
- Returns:
- this operation instance
- Since:
- 1.4
- See Also:
 
- 
outputDirectoryProvides the output directory where all output is generated.- Parameters:
- directory- the output directory
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
outputDirectoryProvides the output directory where all output is generated.- Parameters:
- directory- the output directory
- Returns:
- this operation instance
- Since:
- 1.4
 
- 
outputDirectoryProvides the output directory where all output is generated.- Parameters:
- directory- the output directory
- Returns:
- this operation instance
- Since:
- 1.4
 
- 
libDirectoryProvides the location of grammars and tokens files.- Parameters:
- directory- the lib directory
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
libDirectoryProvides the location of grammars and tokens files.- Parameters:
- directory- the lib directory
- Returns:
- this operation instance
- Since:
- 1.4
 
- 
libDirectoryProvides the location of grammars and tokens files.- Parameters:
- directory- the lib directory
- Returns:
- this operation instance
- Since:
- 1.4
 
- 
grammarEncodingProvides grammar file encoding; e.g., euc-jp.- Parameters:
- encoding- the encoding
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
msgFormatSpecify output style for messages in antlr, gnu, vs2005.- Parameters:
- format- the output styke
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
longMessagesShow exception details when available for errors and warnings.- Returns:
- this operation instance
- Since:
- 1.0
 
- 
listenerGenerate parse tree listener (default).- Returns:
- this operation instance
- Since:
- 1.0
 
- 
noListenerDon't generate parse tree listener.- Returns:
- this operation instance
- Since:
- 1.0
 
- 
visitorGenerate parse tree visitor.- Returns:
- this operation instance
- Since:
- 1.0
 
- 
noVisitorDon't generate parse tree visitor (default).- Returns:
- this operation instance
- Since:
- 1.0
 
- 
pkgSpecify a package/namespace for the generated code- Parameters:
- pkg- the package name
- Returns:
- this operation instance
- Since:
- 1.0
 
- 
dependGenerate file dependencies.- Returns:
- this operation instance
- Since:
- 1.0
 
- 
argumentsRetrieves the list of arguments that will be used for the antlr operation.This is a modifiable list that can be retrieved and changed. - Returns:
- the arguments
- Since:
- 1.0
 
- 
sourceDirectoriesRetrieves the list of source directories that will be used for the antlr operation.This is a modifiable list that can be retrieved and changed. - Returns:
- the source directories
- Since:
- 1.0
 
- 
sourceFilesRetrieves the list of source files that will be used for the antlr operation.This is a modifiable list that can be retrieved and changed. - Returns:
- the source files
- Since:
- 1.0
 
- 
outputDirectoryRetrieves the output directory where all output is generated.- Returns:
- the output directory; or
 * nullif the directory wasn't specified
- Since:
- 1.0
 
- 
libDirectoryRetrieves the location of grammars and tokens files.- Returns:
- the lib directory; or
 nullif the directory wasn't specified
- Since:
- 1.0
 
 
-