Next >

Create model-to-text transformations with JET

You can author Java™ Emitter Templates (JET) transformations to quickly create template-based model-to-text transformations.

When you author a JET transformation, you start with an example of the application code that you want to produce, which is typically one or more Eclipse projects. This example application is called the exemplar. You then use the authoring editor to identify the parts in the exemplar that vary from one application to the next. This identification process produces a data model that represents the variable aspects of the exemplar. You can also associate code-generation actions with elements in the model. Finally, you use the editor to create JET templates from exemplar files, and replace text with references to the model that is developed.

After the model-to-text transformation and corresponding metamodel are created, you can use basic XML input models to validate the transformation. In addition, other Java code can use the transformation by using tools such as the model-to-model mapping transformation tools.

Learning objectives

  • Create JET transformation projects
  • Understand the creation of JET data models
  • Understand JET model navigation with XPath
  • Understand JET actions
  • Account for exemplar artifacts in the transformation model
  • Understand JET-derived attributes and XPath functions
The first two modules of the tutorial take approximately 45 minutes to complete. The entire tutorial requires 60 minutes.

Skill level



This tutorial is intended for architects and developers of software or systems

System requirements

To perform the tasks in this tutorial, you must have the following tools and components installed:
  • Adobe Shockwave Player
  • Transformation authoring component
Next >