[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.modeling.mdt.uml2.ocl] Re: Using OCL to specify derived References (NOT attributes)

Kenn,

Kenn Hussey wrote:
> 
> The derived list implementations are in org.eclipse.uml2.common (which only 
> has dependencies on basic EMF plug-ins), so you could implement your methods 
> by hand to use them. If you want partial generator support for subsets like 
> this, you would need to use a UML model as the source for your EMF project 
> (it is possibe to convert an Ecore model to a UML model).

I don't like the idea to manually implement such a thing.
Can you give a pointer or two on documentation on how to convert from
Ecore to UML (or directly from Rose to UML). I have access to Omondo
EclipseUML (Studio edition) if this helps. I have been looking around
but cannot seem to find documentation regarding that topic.
I am especially interested in ways how to specify in a UML2 model that a
relationship is derived.

> The code snippet I showed was only partially generated by the UML2 code 
> generator. That is, the subset information (the constant) was generated, but 
> the body was not. This is because, without better integration between the 
> UML2 code generator and OCL, it's difficult to tell the generator what code 
> it should generate for derived features... mind you, deriving values by type 
> is, as I mentioned, a common occurrence in UML, so we hope to provide 
> automated for that at some point (perhaps in response to 
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=105199).

Okay, so even if I did convert to a UML2 model, I still would have to
manually modify the accessors for the derived features. So maybe I will
built them by hand after all. But first I will figure out how to
properly use the derived ELists.


Regards

Jürgen