Please note : This help page is not for the latest version of Enterprise Architect. The latest help can be found here.
Transform Template Parameter Substitution
If you want to provide access in a transformation template to data concerning the transformation of a Template Binding connector's binding parameter substitution in the model, you can use the Template Parameter substitution macros.
Factors in the Transformation
Factor |
Detail |
See also |
||||
---|---|---|---|---|---|---|
Intermediary Language |
Template Parameter Substitutions are represented in the Intermediary language as: TemplateParameterSubstitution { Formal { FormalProperties } Actual { ActualProperties } }
For example: TemplateParameterSubstitution { Formal { name=%qt%%parameterSubstitutionFormal%%qt% } Actual { name=%qt%%parameterSubstitutionActual%%qt% %TRANSFORM_CLASSIFIER("Class", parameterSubstitutionActualClassifier)% } }
|
|
||||
Formal Properties or Actual Properties
|
FormalProperties and ActualProperties are zero, or one instance of one of the following properties:
|
|
||||
Transform of Parameter Substitution Actual parameter |
If the Actual parameter is assigned a String Expression, it will transform as Actual name. You can assign the Actual Classifier if you know the GUID: TemplateParameterSubstitution ( Formal { name=%qt%%parameterSubstitutionFormal%%qt% } Actual { name=%qt%%parameterSubstitutionActual%%qt% classifier=%qt%%parameterSubstitutionActualClassifier%%qt% } }
If you want the Actual parameter to be transformed so that its Classifier is assigned with an element that is transformed, then use TRANSFORM_CLASSIFIER or TRANSFORM_REFERENCE, as shown: TemplateParameterSubstitution Formal { name=%qt%%parameterSubstitutionFormal%%qt% } Actual { name=%qt%%parameterSubstitutionActual%%qt% %TRANSFORM_CLASSIFIER("Class", parameterSubstitutionActualClassifier)% } }
Or
TemplateParameterSubstitution { Formal { name=%qt%%parameterSubstitutionFormal%%qt% } Actual { name=%qt%%parameterSubstitutionActual%%qt% %TRANSFORM_REFERENCE("Class", parameterSubstitutionActualClassifier)% } }
|
|
Learn more