public class XOMGenTask
extends Task
XOMGenTask
is an ANT task with which to invoke MetaGenerator
.
Invokes the MetaGenerator
.
This task only invokes XOMGen if the grammar file is newer than the generated Java files.
Attribute | Description | Required |
model | The name of the XML file which holds the XOM model. | Yes |
destdir | The name of the output directory. Default is the current directory. | No |
classname | The full name of the class to generate. | Yes |
dtdname | The name of the DTD file to generate. The path may be
either absolute, or relative to destdir . |
Yes |
<xomgen model="src/org/eigenbase/xom/Meta.xml" destdir="src" classname="org.eigenbase.xom.MetaDef"/>
This invokes XOMGen on the model file
src/org/eigenbase/xom/Meta.xml
, and generates
src/org/eigenbase/xom/MetaDef.java
and
src/org/eigenbase/xom/meta.dtd
.
Modifier and Type | Field and Description |
---|---|
(package private) String |
className |
(package private) String |
destDir |
(package private) String |
dtdFileName |
(package private) String |
modelFileName |
Constructor and Description |
---|
XOMGenTask() |
Modifier and Type | Method and Description |
---|---|
(package private) static File |
classNameToFile(File dir,
String className)
Creates the File that a java class will live in.
|
void |
execute() |
void |
setClassname(String classname)
See parameter
classname . |
void |
setDestdir(String destdir)
See parameter
destdir . |
void |
setDtdname(String dtdname)
See parameter
dtdname . |
void |
setModel(String model)
See parameter
model . |