Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » Derived Relations in Ecore(Derived Relations in Ecore)
Derived Relations in Ecore [message #1859078] Wed, 10 May 2023 15:06 Go to next message
Issam Al-Azzoni is currently offline Issam Al-AzzoniFriend
Messages: 7
Registered: June 2022
Junior Member
In the basicfamily example, a person can have a father and a mother. Both properties are derived. In addition, there are also parents and children properties. What I do not understand is the following scenario:
There is a person named John. Alex and Joanne are the parents of John. When using a model editor, why is Alex set as the father of John and Joanne as the mother. There is nothing in the ecore file defining this relationship.
Re: Derived Relations in Ecore [message #1859481 is a reply to message #1859078] Fri, 09 June 2023 19:07 Go to previous message
Pierre-Charles David is currently offline Pierre-Charles DavidFriend
Messages: 705
Registered: July 2009
Senior Member
You're right that there is nothing in the Ecore itself.
It's defined directly in the Java implementation through custom "@generated NOT" versions of "getMother", "setMother", "getFather" and "setFather".
You can see the code here: https://github.com/pcdavid/org.eclipse.sirius/blob/master/plugins/org.eclipse.sirius.samples.family/samples/org.eclipse.sirius.sample.basicfamily/src/org/eclipse/sirius/sample/basicfamily/impl/PersonImpl.java#L187


Pierre-Charles David - Obeo

Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Previous Topic:"List Mode" check box and "Shape" drop-down menu in Sirius web?
Next Topic:Can't Undo Sirius deletion in RCP
Goto Forum:
  


Current Time: Fri Oct 04 09:04:02 GMT 2024

Powered by FUDForum. Page generated in 0.03724 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top