Subweb Home
Overview
OOA of OOA
Metamodel
PARSEC
Templates
Converter
Architecture
PULSAR
Demonstrator
Downloads
Code Generation with Templates
Walking the Metamodel

Code templates in PLASMA are written in an Archetype Language called PARSEC. They are essentially the code format definitions required by the generation engine.

All Metadata in the tool is organized on relational principles and implemented using tables. This allows templates written in PARSEC to perform relational queries on the Metamodel. A typical query will involve many objects and may cross several domain boundaries.

The source code generated from the Metamodel is closely related to the Software Architecture Virtual Machine. The application source code depends on the various services it provides to run.

PARSEC Code Templates

A package of templates has been developed to generate ANSI C source code files for objects, domains and system configuration. Also, a number of templates create scripts to provide for object and domain compilation. There are about 100 template files which amount to over 180 KB.

Templates for target languages such as C++ or Java may be less complex to implement because the Software Architecture design can incorporate their object oriented features.

Template Advantages

A typical suite of templates can be fairly large. Templates don't just have to generate source code, but can also be used to create build command files for object and domain level compiling and linking.

In addition, templates may be written to write scripts to be executed in the operating system environment. For example, creating and deleting directories.

As long as the Metadata and templates are correct, the code generated will be free from syntactic coding errors. Any errors in the templates themselves will show up very quickly since these errors are systemic in nature.

With automation via templates, source code is more systematically organized and can be better documented.

MON-10-NOV-2003