-->
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.  [ 3 posts ] 
Author Message
 Post subject: Question on composite-element
PostPosted: Tue Aug 10, 2004 11:25 am 
Newbie

Joined: Mon Aug 09, 2004 10:53 am
Posts: 19
Hibernate version: 2.1

Mapping documents:

Code between sessionFactory.openSession() and session.close():

Full stack trace of any exception that occurs:

Name and version of the database you are using:

Debug level Hibernate log excerpt:

I have a few questions about composite-element
In chap 6 of the reference docs, it says that we can specify a list of components like this:

<list name="carComponents" table="car_components">
<key column="car_id"/>
<index column="posn"/>
<composite-element class="org.hibernate.car.CarComponent">
<property name="price" type="float"/>
<property name="type" type="org.hibernate.car.ComponentType"/>
<property name="serialNumber" column="serial_no" type="string"/>
</composite-element>
</list>

1. My first question is this, would this be possible for a Map, i.e.

<map name="carComponents" table="car_components">
<key column="car_id"/>
<index column="posn"/>
<composite-element class="org.hibernate.car.CarComponent">
<property name="price" type="float"/>
<property name="type" type="org.hibernate.car.ComponentType"/>
<property name="serialNumber" column="serial_no" type="string"/>
</composite-element>
</map>

2. My 2nd question is, how would we specify the above using XDoclet tags?

Thanks in advance for your help,
Femi


Top
 Profile  
 
 Post subject:
PostPosted: Thu Aug 12, 2004 3:38 pm 
Expert
Expert

Joined: Thu Jan 29, 2004 2:31 am
Posts: 362
Location: Switzerland, Bern
Question 1:
According to the DTD this is fine.

Question 2:
In http://www.hibernate.org/72.html you can find the following statement
Quote:
Note that XDoclet will not be able to support the new composite features.


HTH
Ernst


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 16, 2004 10:57 am 
Newbie

Joined: Mon Aug 09, 2004 10:53 am
Posts: 19
Ok, so XDoclet doesn't support the new composite features now, but are there plans to do so in the future?


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

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.