MagicDraw/Cameo v19SP3: UML/SysML: HOWTO Set an OpaqueExpression on a Slot that seems to be stuck on a numerical value.

Icon class
icon_class
far fa-sticky-note
icon_class_computed
far fa-sticky-note
Note kind
Policy level
Specification keywords
UML keywords
SysMLv1.x keywords
Keywords
Click on the image to view it full size
It can sometimes be useful to use an OpaqueExpression to specify the value of a Slot. But if you do this with a value property typed, say, by a Real, you might find the value getting "stuck" on 0.0 in the inline Slot editor for an InstanceSpecification. One way to handle it is:
  1. Via the InstanceSpecification dialog select the Slot name (under Slots).
  2. If it does not already have a value you MUST first use the Create Value button to create one, which if it is a Real will by default create a LiteralReal 0.0.
  3. Click the small - button at the bottom right to remove the Slot value row (do NOT use the Remove Value button).
  4. Hold your mouse over the name of the Slot then access Open Specification via the context menu, which brings up the entire Slot specification dialog.
  5. Select value in the Slot specification dialog then click the small + button.
  6. Select Opaque Expression from the expanding menu right.
  7. Enter an OpaqueExpression that refers to names of value properties known to the final context in which the Slot will be used, then click Close then Close then Close.
  8. There is a related tool problem:
    If you are working with SysML Extension for Physical Interaction and Signal Flow Simulation (SysPhS) and Modelica, you might also encounter this:
Relates to
Related notes
Related notes (backlinks)
Related snippets (extracts)
Visit also
Visit also (backlinks)