The input file is needed to generate a class model for the class to be generated. Since the model must suffice some simple rules (implementing the right interfaces) it is easy to see that there are many domain specific languages (DSL) to describe a model. In this plug-in one is implemented: DataBaseTable But the good news is you can supply your own through the extension point "ch.sahits.codegen.java.inputdbparser" We will come back to how this integrates and what restrictions there are, but first lets have a look at what is already in the plug-in.
The DSLs are separated by the file extension. There are two file types implemented:
As mentioned above the DSLs are separated by the file extension. So you can take an existing file format (e.g. *.txt) or create on of your own and supply a model generator for this input model. If you decide to go with an XML file you probably want your own model generator. In the plug-in a basic parser is used that can be extended to fullfill your needs. It is the XMLJDomParser
Last modified: