To create a transformation extension, you must create a transformation
extension point in a plug-in, and create a TransformationExtension element
that defines the target transformation.
To create a transformation extension:
- Create an Eclipse plug-in project:
- Click .
- In the New Project wizard, on the Select a wizard page, in the
Wizards pane, click Plug-in Project.
- Click Next.
- In the New Plug-in Project wizard, on the Plug-in Project page,
in the Project name field, specify a project name.
On the remaining pages of the wizard, if you specify a name that contains
spaces, the spaces are converted to underscores in the plug-in identifier
(ID) and plug-in name. Accept the default values for the other fields on this
page.
- Click Next.
- On the Plug-in Content page, accept the default values, and click Next.
- Click Finish. If you are prompted to switch
to the Plug-in Development perspective, click Yes.
- Create a TransformationExtension element in the plug-in manifest
file:
- In the navigation view, in the plug-in project that you created
in step 1, in the META-INF
folder, double-click MANIFEST.MF.
- In the plug-in manifest editor, on the Extensions tab,
click Add.
- In the New Extension wizard, on the Extension Point Selection
page, on the Extension Wizards tab, click Transformation
Templates, click Transformation Extensions,
and click Next.
- On the New Transformation Extension page, specify values for the
following fields:
- In the ID field, specify a unique value that
identifies the transformation extension to the transformation service.
- In the Name field, specify a name for the transformation
extension.
- In the Transformation target ID field, type
the identifier for the transformation that you are extending. This identifier
should follow Java™ naming conventions, as in this example: the.extended.transformation.
Note: For
more information about the other fields on this page and the remaining pages
in the wizard, see the context-sensitive help by pressing F1 when
that page is displayed in the product. If
you are using the Linux® platform, for more information about the other
fields on this page and the remaining pages in the wizard, see the context-sensitive
help by pressing Shift+F1 when that page is displayed
in the product.
- Click Next.
- Optional: On the New Transformation Extension page,
click Insert or Delete to define
the rules, extractors, and transforms of the extension, and click Next.
- Optional: On the next New Transformation Extension
page, associate the rules, transforms, or extractors in the extension to the
transforms or transformation that you are extending, and click Next.
After you specify the extended transformation and transforms,
and the elements that they contain, when you click an item in the Extended
transforms table, the rules, transforms, and extractors associated with that
item are displayed in the Additions to selected extended transforms table.
- Optional: On the next New Transformation Extension
page, define the properties of the transformation extension, and click Next.
- Click Finish.
After you complete the pages in the wizard, a plugin.xml file is generated
that contains an extension point named com.ibm.xtools.transform.core.transformationExtensions.
This extension point contains a TransformationExtension element that defines
a transformation extension. The targetTransformation attribute in the TransformationExtension
element specifies the name of the transformation to extend.