Previous UML Classes Table of Contents UML Packages Next


17.5.15 Operation

Templates


*Generalizations

   

    ParameterableElement (from Templates) on page 647

   

    Operation (from Kernel , Interfaces ) on page 105 (merge increment)

   Description

   Operation specializes ParameterableElement to specify that an operation can be exposed as a formal template parameter, and provided as an actual parameter in a binding of a template.

   Attributes

   No additional attributes

   Associations

   Issue 8588 -fix type to ‘OperationTemplateParameter’ 9110 - rename ‘parameter’ to ‘templateParameter’ and fix constraint

   • templateParameter : OperationTemplateParameter [0..1]The template parameter that exposes this element as a formal parameter. Redefines ParameterableElement::templateParameter.

   Constraints

   No additional constraints

   Semantics

   An Operation may be exposed by a template as a formal template parameter. Within a template classifier an operation template parameter may be used as any other operation defined in an enclosing namespace. Any references to the operation template parameter within the template will end up being a reference to the actual operation in the bound classifier. For example, a call to the operation template parameter will be a call to the actual operation.

   Notation

   See OperationTemplateParameter for a description of the general notation that is defined to support these added capabilities.Within the notation for formal template parameters and template parameter bindings, an operation is shown as <operation-name> ‘(‘ [<operation-parameter> [‘,’ <operation-parameter>]*] ‘)’.