-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: <subclass> in <joined-subclass> not supported?
PostPosted: Wed Jan 02, 2008 5:09 pm 
Regular
Regular

Joined: Thu Nov 30, 2006 10:48 am
Posts: 59
Just want to confirm -- nHibernate doesn't support <subclass> in <joined-subclass>?

What do people do when a class a) implements an interface and b) is the base class of an inheritance hierarchy? E.g. Domain Classes: We have classes B and C that are subclasses of A (abstract class). And we have classes A and D (concrete class) implement the interface, iE. Database: We treat the iE interface and the classes (A and D) that implement it as table-per-subclass inheritance; this gives us tblE, tblA, and tblD, with tblA and tblD w/ FK_E_ID. The A-B,C inheritance hierarchy is implemented as table-per-class-hierarchy; therefore, we have tblA or A, B, and C w/ TypeName as discriminator. Class mapping: Initially, I had the interface class mapping as the primary mapping with <class name="iE">. It had <joined-subclass name="A"> and, under this joined-subclass, the A-B-C inheritance hierarchy was implemented as table-per-class-hierarchy with <subclass> elements. This didn't work, though.

Thanks,
Bill

_________________
metazone


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.