public class BeanCodeGen
extends java.lang.Object
This reads in a .java file, parses it, and writes out an updated version.
| Constructor | Description |
|---|---|
BeanCodeGen(java.util.List<java.io.File> files,
BeanGenConfig config,
int verbosity,
boolean write) |
Creates the generator for a single bean.
|
| Modifier and Type | Method | Description |
|---|---|---|
static BeanCodeGen |
createFromArgs(java.lang.String[] args) |
Creates an instance of
BeanCodeGen from arguments. |
static void |
main(java.lang.String[] args) |
Main method.
|
int |
process() |
Processes the file, recursing as necessary, generating the source code.
|
java.util.List<java.io.File> |
processFiles() |
Processes the file, recursing as necessary, generating the source code.
|
public BeanCodeGen(java.util.List<java.io.File> files,
BeanGenConfig config,
int verbosity,
boolean write)
To generate, use process().
files - the files to process, not nullconfig - the configuration to use, not nullverbosity - the verbosity, from 0 to 3write - whether to write or notpublic static void main(java.lang.String[] args)
This calls System.exit.
args - the arguments, not nullpublic static BeanCodeGen createFromArgs(java.lang.String[] args)
BeanCodeGen from arguments.
This is intended for tools and does not call System.exit.
args - the arguments, not nulljava.lang.RuntimeException - if unable to createpublic int process()
throws java.lang.Exception
The number of altered files is returned.
java.lang.Exception - if an error occurspublic java.util.List<java.io.File> processFiles()
throws java.lang.Exception
The list of altered files is returned.
java.lang.Exception - if an error occursCopyright © 2007–2018 Joda.org. All rights reserved.