[umbrello] [Bug 73847] support for UML tagged values

Oliver Kellogg bugzilla_noreply at kde.org
Sun Sep 20 21:59:03 BST 2020


--- Comment #20 from Oliver Kellogg <okellogg at users.sourceforge.net> ---
(In reply to Ralf Habacker from comment #8)
> [...]
> To support uml 1.4 tagged values, it is required
> 1. to add a key/value map to class UMLStereotype

IMHO stereotype definition needs to be separated from stereotype application.
This means that the stereotype definition would declare e.g.
" this stereotype has an attribute named 'foo' of type String and an attribute
'bar' of type Double "
and the stereotype application would define the concrete values of the 'foo'
and 'bar' attributes.
Example in XMI:

1) Stereotype definition
<UML:Stereotype xmi.id="theStereoID" name="mystereo" namespace="m1">
  <UML:Attribute xmi.id="fooID" type="String" name="foo"/>
  <UML:Attribute xmi.id="barID" type="Double" name="bar"/>

2) Stereotype application
<UML:Class [...] name="MyClass">
  <UML:StereoApp [...] type="theStereoID">
    <foo value="fidget widget"/>
    <bar value="12345.67"/>

We need the separation between definition and application because different
classes will apply the same stereotype but with different concrete values for
the stereotype attributes.
Stereotype attributes cannot be of arbitrary type but they can use the UML
primitive types, see
I.e. the possible attribute types are:
- Boolean
- UnlimitedNatural
- Integer
- Real
- String

The stereotype definition attributes from the example,
  <UML:Attribute xmi.id="fooID" type="String" name="foo"/>
  <UML:Attribute xmi.id="barID" type="Double" name="bar"/>
use the xmi.id given at "type" to be equal to the primitive type name.

You are receiving this mail because:
You are the assignee for the bug.

More information about the umbrello-devel mailing list