I have two simple EntityBeans: ImageBean and ImageVariantBean, where ImageBean just holds an image's name and references to many ImageVariantBeans that hold the actual image-data in different variants. I can create perfectly well working ValueObjects for this 1:n relation using XDoclet. But I also have another relation between those two, that's called PrimaryVariant and it's a 1:1 relation.

I don't have any clue on how to model this using XDoclet. I started with just adding the @ejb.value-object to my getPrimaryVariant() method, but this resulted in a broken ImageBeanData-object beeing created by XDoclet. After that, I tried to copy the whole composition settings that worked for the 1:n-relation between ImageBean and ImageVariantBean, but I can't set the type to anything else than Collection or Set.

ValueObjects for 1:1-Relations: How is this to be done?

Thanks for any help,
Alexander


------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ xdoclet-user mailing list xdoclet-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to