ModelAnt as an extension of Apache ANT to create, load, update and query models and meta-models, through industry standard technologies and Java APIs as:

  • a JMI 1.0, MOF 1.4 compliant model and meta-model repository (a feature provided by NetBeans MetaData Repository (MDR))
  • an extension of ANT scripting language to create, modify, query, query, print and process MOF 1.4 meta-models and resulting models with import from XMI 1.1 / 1.2 and export in XMI 1.2 format
  • a template engine to generate text artifacts (including code) out of models and meta-models, using object-oriented JSP-like templates. ModelAnt provides completely extensible examples of
    • generating java code  (POJO) from a domain model in UML 1.3
    • generating SQL statements to create an [Oracle] database schema from a domain model in UML 1.3 where an ORM tool could store corresponding java (POJO) objects (see above)
  • a system of classes that are wrappers around the model-specific JMI API forming a middle tier between the model and the templates, providing practical and non-trivial methods for model query and processing used in the artifacts generation
  • a platform that provides core reverse engineering features as:
    • reverse engineering ANT scripts and libraries
    • reverse engineering XSD
    • reverse engineering Java sources to reveal their packages, classes, attributes and methods
    • reverse engineering databases through standard JDBC API, revealing their tables, columns, primary keys, foreign keys and relationships
    • further conditional model processing and transformation
  • a meta-model-agnostic models comparison
  • a meta-model-specific comparison of models treated as:
    • database structures
    • UML 1.3 models
  • a meta-model-agnostic transformation/copy of models between different meta-models
  • a complete transformation of UML 1.3 models to UML 1.4 models
  • an ANT script documentation macro ant.doc (i.e. reverse engineering + text generation) quite similar to the Java standard javaDoc tool
  • an open platform for building more ModelAnt scripts and components to solve more practical problems.

The documentation of ModelAnt by itself is a demonstration of the ant.doc ANT  macro involving the features of ModelAnt for:

  • reverse engineering ANT scripts and antlib.xml definitions revealing the tasks, macros, types and targets in them together with the XML comments, descriptions and javaDoc documentation of the implementation tasks
  • reverse engineering Java source files revealing their attributes and methods together with their javaDoc documentation
  • template-based artifacts generation using a simple and effective object-oriented approach
  • model creation, query, walk-through and  import/export using ModelAnt scripts
  • general and UML 1.3 models comparison and detection of added, deleted and changed model elements

ModelAnt distributions are published in the distributions repository.

See also the ModelAnt documentation.

One thought on “ModelAnt

  1. your post is an excellent example of why i keep coming back to read your excellent quality content that is forever updated.

Leave a Reply

Your email address will not be published.