|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.eigenbase.xom.MetaTester
public class MetaTester
The MetaTester class is a utility class for testing generated models. The tester reads a model file in XML, validates it against its DTD, converts it to its corresponding model definition class (always a subclass of ElementDef), and displays the results. The MetaTester may be used to test a model against a suite of input files to verify the model's correctness.

| Constructor Summary | |
|---|---|
MetaTester(String modelFile,
String fileDirectory,
int parserType)
Constructs a new MetaTester using the given model file, the given test file, and the directory containing all support files. |
|
| Method Summary | |
|---|---|
static void |
main(String[] args)
The MetaTester tests a suite of test model files against a compiled model. |
void |
testFile(String testFile,
String fileDirectory)
Tests a specific instance of the given model, as described by testFile. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MetaTester(String modelFile,
String fileDirectory,
int parserType)
throws XOMException,
IOException
XOMException - if the model file is corrupted or if any
of its compiled components cannot be loaded.
IOExceptionmodelFile - an XML file describing the model to be tested.
This model should have already been compiled using the MetaGenerator
utility.fileDirectory - the directory containing all output files
(Java classes, dtds, etc) from the model compilation. The model
and its associated java class must be compiled.| Method Detail |
|---|
public void testFile(String testFile,
String fileDirectory)
throws XOMException
XOMException - if the test fails for any reason.testFile - the XML file to be tested.fileDirectory - directory containing files.
public static void main(String[] args)
throws XOMException,
IOException
Arguments:
All other arguments are the names of the test model files. Each of these will be tested and displayed in turn.
XOMException
IOException
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||