Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [TENEO] Support for Inheritance by Teneo (How to use Annotations with Ecore model)
[TENEO] Support for Inheritance by Teneo [message #657479] Wed, 02 March 2011 22:25 Go to next message
Robert Lario is currently offline Robert LarioFriend
Messages: 8
Registered: February 2011
Junior Member
I have an ecore model that has inheritance, I want to use Teneo.

It looks like I should use Annotations to support this. Is there a good reference explaining how to do this? I found a reference to @MappedSuperClass and http://wiki.eclipse.org/Teneo/Hibernate/ModelRelational/Anno tations_Support

But it is not clear to me how to add these annotations to my ecore model.

Thanks for your help.
Re: [TENEO] Support for Inheritance by Teneo [message #657531 is a reply to message #657479] Thu, 03 March 2011 08:15 Go to previous message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Hi Robert,
Hmm most information should be here (which you already found I guess):
http://wiki.eclipse.org/Teneo/Hibernate#Model_Relational_Map ping_with_EJB3.2FJPA_Annotations

annotations are either added to the ecore directly or in a separate xml document.

this page specifically discusses inheritance mapping:
http://wiki.eclipse.org/Teneo/Hibernate/ModelRelational/Inhe ritance_Mapping

I use MappedSuperclass in combination with a root super class which has the id and version eattributes. MappedSuperclass
makes it possible flatten the generated table structure so that not all tables are joined to one root table.

gr. Martin

On 03/02/2011 11:25 PM, Robert Lario wrote:
> I have an ecore model that has inheritance, I want to use Teneo.
> It looks like I should use Annotations to support this. Is there a good reference explaining how to do this? I found a
> reference to @MappedSuperClass and http://wiki.eclipse.org/Teneo/Hibernate/ModelRelational/Anno tations_Support
>
> But it is not clear to me how to add these annotations to my ecore model.
>
> Thanks for your help.
>


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
Previous Topic:UnsupportedOperationException in DocumentRootImpl
Next Topic:how to enumerate all subclasses in genmodel JET templates
Goto Forum:
  


Current Time: Mon Oct 14 22:56:11 GMT 2019

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

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

Back to the top