Hi tenwit,
Thanks for the quick reply.
tenwit wrote:
There is no direct support for that.
I somewhat assumed and feared that. :(
tenwit wrote:
The only solution that I can think of that doesn't require you to change your java code is to put a <component> in your map, and the list in the component.
I also thought that sounded feasible, but looking at the DTD below, you can see that <component> is not a supported sub-element of <map>.
http://hibernate.sourceforge.net/hibern ... ng-3.0.dtdHere are the supported sub-elements:
(element|one-to-many|many-to-many|composite-element|many-to-any)
If you read further, you will notice the following information for the composite-element, with emphasis on "
Composite elements may not hold nested collections":
Quote:
A composite element allows a collection to hold instances of an arbitrary
class, without the requirement of joining to an entity table. Composite elements
have component semantics - no shared references and ad hoc null value semantics.
Composite elements may not hold nested collections.
So, it does not appear that I can achieve a mapping of nested collections. Instead, I assume I will actually have to modify my Java code.
Do you see any other way around this issue? Am I missing something?
Thanks,
Sam