Plugins (1059)


Training and Consulting (44)



EPIC Poll

What is your favourite developer portal?

[ Results | Polls ]

Votes: 541
Comments: 0

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
koreth
9 Post subject: composite-element causes invalid generic  PostPosted: Aug 19, 2005 - 06:54 PM



Joined: Aug 19, 2005
Posts: 3

I have a list defined something like this:

Code:
<class name="com.me.Foo" table="foo">
  <list name="items" table="items">
    <key column="foo_id">
    <list-index column="item_num">
    <composite-element class="com.me.Item">
      <property name="xyz" type="string"/>
    </composite-element>
  </list>
</class>

Hibernate Synchronizer generates the com.me.Foo and com.me.Item classes. However, the Foo class contains the following:

Code:
// collections
private java.util.List<null> items;


Which is obviously not right. If I change the <list> tag to

Code:
<list name="items" table="items" class="com.me.Item">


then Hibernate Synchronizer generates the correct output, but unfortunately <list> doesn't take a "class" argument according to the Hibernate 3 DTD, so I can't leave that in there.

Is there a way to make this work, or do I have to let my mapping file and the generated code go out of sync?
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits