Hi, I have a general question about Hibernate. I tried the original hibernate forum, but after several days on the forum without an answer, I thought I try my luck here....
The original post can be found here: http://forum.hibernate.org/viewtopic.php?t=989385 The introduction code, and the "shortest" problem description is: public class Order { private IDestination destination; // or, perhaps more complicated // a list of IDestinationObjects IList<IDestination> LotsOfTargets } public interface IDestination { Long getId(); void setId(Long id); } public class Destination1 implements IDestination { private Long id; } public class Destination2 implements IDestination { private Long id; } I think you all get the problem: Is it possible to map two classes which have nothing in common then the interface (no common base class). I read everything in the Hibernate in Action, and there is a lot of stuff about Inheritance and table structures, but nothing about interfaces... It would be really helpful if somebody at least tells me "Impossible.." or "Will be complicated".. or even RTFM at page XYZ :-) Tried so search for interface and mapping.. You can imagine, not the best search tearms... Chris --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "nhusers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~----------~----~----~----~------~----~------~--~---
