Overriding JET templates in other JET transformations

You can specify that a JET transformation override the templates of another JET transformation. By overriding the JET templates in another transformation, you can customize the behavior of an existing JET transformation by replacing only specific templates.

Before you begin

You must create a JET transformation to override an existing JET transformation.

About this task

The overriding JET transformation can invoke any template that it defines, or any template that the JET transformation that you want to override defines. When the sample template is defined in both transformations, the template that is defined in the overriding JET transformation is evaluated. Templates are identified by their project-relative path. The c:include tag includes an attribute named super, which, when set to true, runs a template in the overridden JET transformation.

A JET transformation can only override one other JET transformation.

To specify which JET transformation the current JET transformation overrides:

Procedure

  1. In the Project Explorer view, right-click the plugin.xml file in a JET transformation project; then click Open.
  2. In the editor, click the Extensions tab.
  3. On the Extensions page, expand the org.eclipse.jet.transform extension and click (transform).
  4. In the Extension Element Details area, in the overrides field, specify the unique ID of the JET transformation to override.
  5. Click File > Save.

Feedback