|Re: Building UML2-approximated Model in EMF [message #627036]
||Wed, 15 October 2008 20:22
Originally posted by: cdamus.zeligsoft.com|
All of this is implemented by the UML2 project in a layer on top of the
EMF run-time and code-generation components.
The UML2 project defines a custom EList mini-framework, in the
org.eclipse.uml2 plug-in, for subsetting, derived unions, and derived
subsets. See, for example, the SubsetSupersetEObjectEList and
For redefinitions, there are two cases. In the case that the redefining
property has has a different name than all of the redefined properties,
UML2's conversion to Ecore can create a corresponding EStructuralFeature
in the specializing EClass. This EStructuralFeature is decorated with
an EAnnotation that references the EStructuralFeatures corresponding to
the redefined properties.
In the case that the redefining property does have the same name as any
of the redefined properties, UML2 cannot create a corresponding
EStructuralFeature in the specializing EClass. Instead, it creates an
EAnnotation and adds the EStructuralFeature to it, in its contents list.
The annotation referencing the redefined features is as in the first
I think I got this right ... I am including the UML2 newsgroup in my
reply for their input.
Timothy Marc wrote:
> Hi all,
> i've a question concerning the generation of an Ecore model from an UML
> model. How are features like Subsets and Union realized during the
> converting mechanism from UML to Ecore?
> Here is a concrete scenario:
> In my department, i have to adopt a complete UML Class model, defined in
> MagicDraw with subsets, unions and redefinitions, and have to create an
> EMF-Model out of it. MagicDraw provides a good exporter to EMF, that's not
> the problem. But how are the subsets and union features are treated during
> the process of converting it to an Ecore and generating an genmodel and of
> course the sources. I hoped, that the converte would produce something
> similiar to the UML2-API for my specific metamodel.
> In the wonderful article from Ken Hussey
> https://bugs.eclipse.org/bugs/attachment.cgi?id=55337 there is explained,
> that EMF doesn't support these concepts. However, fro the UML2-Project, it
> seems, that the subsets/union-things are working. Currently, i'm a bit
> confusing of the topic.
Powered by FUDForum
. Page generated in 0.02280 seconds