Verifying UML profiled models
By Freddy Allilaire (INRIA), Rémi Schnekenburger (CEA LIST)
May 2007
This use case shows how to integrate a model transformation service in a UML Modeler to verify a UML profiled model.
Keywords
UML Modeler, UML 2, UML Profile, Verification, Naming convention, Error reporting.
Overview
Papyrus is a dedicated tool for UML2 graphical modelling mainly developed by CEA LIST. It integrates the ATL engine. This use case shows how the coupling of ATL and Papyrus may allow to verify UML profiled models.
In the context of this use case, a sample UML profile and a sample UML model applying this profile have been modeled with Papyrus. For this UML profiled model, we provide a service that will check if the UML model complies to some conventions. The conventions are defined by the ATL transformation “SampleUMLProfile to Problem”. The figures below present the profile and the UML model used here:
For all the models using the sample profile, we want to check some properties (e.g. naming convention). To do this, we will define an ATL model transformation to check these conventions associated to the Sample profile. If an element of a UML model does not respect a convention, a problem element (e.g. warning, error) will be created. For example, if we want to forbid the value “value1” for the property “myProperty” this could be done by the following ATL code:
The following ATL rule will verify if all the classes with stereotype MyStereotype have a name starting by ‘Sample_’. If not, a warning problem will be created with the following text “Class name should start with Sample_ to respect sample convention”.
To see how to configure and run the “Verification UML Profiled Model” ATL service, please take a look to the User Guide.
This resulting model contains all the problems of the UML model. So, if this model is not empty (i.e. there are problems in the UML model) the problems will be displayed in the Eclipse Problems view.
Related Use Cases
None at the current time.
References
- Hoare, C.A.R Monitors: An Operating System Structuring Concept Communications of the ACM, Vol. 17, No. 10. October 1974, pp. 549-557
- Dijkstra, E. W. Cooperating Sequential Processes. In programming Languages (Ed. F. Genuys), Academic Press, New York.
Download
Acknowledgement
The present work is being supported by the Usine Logicielle project of the System@tic Paris Region Cluster.