public abstract class GeneratorBase extends Object implements ClassGenerator
Modifier and Type | Field and Description |
---|---|
protected Pattern |
keyPattern |
protected File |
outputDirectory |
protected String |
outputEncoding |
protected Reporter |
reporter |
protected boolean |
strictTypes |
Constructor and Description |
---|
GeneratorBase(GeneratorConfig config) |
Modifier and Type | Method and Description |
---|---|
protected void |
assertKeyPatternMatched(String key) |
protected int |
countArgs(String formatString)
Counts the number of arguments.
|
void |
generate(File baseDir,
org.apache.tools.ant.DirectoryScanner ds) |
void |
generate(File baseDir,
org.apache.tools.ant.DirectoryScanner ds,
FileFilter filter) |
void |
generate(File propertyFile,
String relPath) |
protected abstract void |
generateImpl(String className,
Properties props) |
protected Pattern |
getKeyPattern() |
protected File |
getOutputDirectory() |
protected String |
getOutputEncoding() |
protected Reporter |
getReporter() |
protected Class<?> |
inferType(Format format) |
protected String |
toClassName(String relPath) |
protected String |
toJavaIdentifier(String key) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
build
protected final File outputDirectory
protected final String outputEncoding
protected final Reporter reporter
protected final Pattern keyPattern
protected final boolean strictTypes
public GeneratorBase(GeneratorConfig config)
public void generate(File baseDir, org.apache.tools.ant.DirectoryScanner ds, FileFilter filter) throws IOException
generate
in interface ClassGenerator
IOException
public void generate(File baseDir, org.apache.tools.ant.DirectoryScanner ds) throws IOException
generate
in interface ClassGenerator
IOException
public void generate(File propertyFile, String relPath) throws IOException
generate
in interface ClassGenerator
IOException
protected abstract void generateImpl(String className, Properties props)
protected void assertKeyPatternMatched(String key)
protected int countArgs(String formatString)
protected File getOutputDirectory()
protected String getOutputEncoding()
protected Reporter getReporter()
protected Pattern getKeyPattern()
Copyright © 2019. All rights reserved.