Hi,

 

I have implemented the rendering, setting, and saving of TagDefinition
types, 

in full agreement with UML 1.4.

I describe what I have done below.

 

New classes:

-
org.argouml.uml.ui.foundation.extension_mechanisms.ActionSetTagDefinitionTyp
e

  (the existing is just a rename refactoring of
org.argouml.uml.ui.foundation

  .core.ActionSetStructuralFeatureType)

- org.argouml.uml.ui.foundation.extension_mechanisms

  .UMLTagDefinitionTypeComboBoxModel

 

Changed classes:

- org.argouml.uml.ui.foundation.extension_mechanisms.PropPanelTagDefinition

  (minor changes to introduce the TagDefinition Type comboBox model, and 

  activate it, and change the action to ActionSetTagDefinitionType)

-
org.argouml.uml.ui.foundation.extension_mechanisms.ActionSetTagDefinitionTyp
e

  (to handle TagDefinitions instead of StructuralFeatures)

- org.argouml.uml.ui.UMLListCellRenderer2

  (to support the rendering of metatype names)

- Correct UML 1.4 XMI model (issue 4934)

 

Required new features:

 - ModelManagementHelper.findElement(List<String>)

   (finds an element by full-path in all roots; request in another thread)

 - two utility methods that handle the translation between model elements
and

   names for tagdefinition types. Currently they are static and placed in a 

   helper class (the goal is to concentrate the code that depends on the 

   adopted solution for formating the names of tagdefinition types saved in 

   the model XMI file), but they can be put where they are used 

   (ActionSetTagDefinitionType and UMLTagDefinitionTypeComboBoxModel).

 

Decisions I took myself (in the absence of further feedback):

1- String format for saving types:

   [ns1, ..., nsn, name] where ns1 is a root of model elements (UML 1.4 

   allows Stereotypes and DataTypes only) or, in the case of UML metatype 

   names, a specific tag. The requirement is that it uniquely identifies

   model elements and UML metatypes.

4- Display preferences for metatypes:

   distinguishing icon (class symbol with UML overwritten) and root path tag


   ("UML" + Model.getFacade().getUmlVersion()), this is independent from the

   previous.

 

If you are interested in adding this functionality to Argo, just let me know


how should I share the code.

Now, I have already started working on how the support for setting the value
of 

tagged values can be improved, namely providing some visual form of doing
it,

instead of typing plain text.

 

Regards,

Sergio Lopes.

 



Reply via email to