Previous UML Classes Table of Contents UML Packages Next


13.3.21 OpaqueExpression

BasicBehaviors


*Generalizations

   

    OpaqueExpression (from Kernel ) on page 103 (merge increment)

   Description

   Provides a mechanism for precisely defining the behavior of an opaque expression. An opaque expression is defined by a behavior restricted to return one result.

   Attributes

   No additional attributes

   Associations

   Constraints

Issue 8312 - modify first constraint and add OCL to both constraints

   [1] The behavior can only have return result parameters.

   self.behavior.notEmpty() implies(self.behavior.ownedParameters->select(p | p.direction <> ParameterDirectionKind ::return))->isEmpty()

   [2] The behavior must have exactly one return result parameter.

   self.behavior.notEmpty() implies(self.behavior.ownedParameter->select(p | p.direction = ParameterDirectionKind ::return))->size() = 1

   Semantics

   An opaque expression is invoked by the execution of its owning element. An opaque expression does not have formal parameters and thus cannot be passed data upon invocation. It accesses its input data through elements of its behavioral description. Upon completion of its execution, a single value or a single set of values is returned to its owner.