Creating capabilities to show or hide transformations
You can create capabilities to which you can bind transformations.
You should create capabilities in a different plug-in from the transformations
that you create. You can bind more than one transformation to a capability.
By using this feature, you can show or hide the transformations in
the list of available transformations in the New Transformation Configuration
wizard or on transformation pop-up menus.
Before you begin
About this task
In addition to creating capabilities, you can create new capability categories, which are groupings of capabilities. For example, you might create a capability category that contains a capability for each model-to-model transformation that you write.
You can also create capabilities for the language-specific transformations in IBM® DevOps Model Architect.
Procedure
Results
Example
The following example creates a capability category called "My transformations," two capabilities, and a binding between the transformations and the appropriate capability. In this example, you create a capability for a custom UML-to-Java transformation and a capability for a group of model-to-model transformations.
<extension point="org.eclipse.ui.activities">
<activity description="This capability references the transformation called MyUMLToJavaTransformation." id="myCapability.activity1" name="My UML-to-Java transformation">
</activity>
<activity description="This capability references my model-to-model transformations." id="myCapability.activity2" name="My model-to-model transformations">
</activity>
<category id="myCapability.category1" description="My transformations" name="My transformations">
</category>
<categoryActivityBinding activityId="myCapability.activity1" categoryId="myCapability.category1">
</categoryActivityBinding>
<categoryActivityBinding activityId="myCapability.activity2" categoryId="myCapability.category1">
</categoryActivityBinding>
<activityPatternBinding activityId="myCapability.activity1" pattern="com\.myCompany\.myPlugin/com\.myCompany\.myTransformation\.MyUMLToJavaTransformationIdentifier">
</activityPatternBinding>
<activityPatternBinding activityId="myCapability.activity2" pattern="com\.myCompany\.myPlugin/com\.myCompany\.myTransformation\.modeltomodel.*">
</activityPatternBinding>
</extension>
