I checked the Xdoclet source and I was mistaken. I really thought this was taken care of - sorry :-).
It should not be hard to fix - edit the hibernate.xdt file. You will find about 1/3 the way down the entry for the id tag. You need to add the inclusion of the hibernate-property/xdt file. For example the lines to add will look something like:
Code:
<XDtHibernate:setCurrentTag name="hibernate.id" mappingElement="id">
<XDtMerge:merge file="xdoclet/modules/hibernate/resources/hibernate-column.xdt">
</XDtMerge:merge>
</XDtHibernate:setCurrentTag>
This will go into the following hibernate.xdt section like this (changes are towards the end):
Code:
<XDtHibernate:ifHasPrimitiveId>
<id
name="<XDtMethod:propertyName/>"
column="<XDtMethod:methodTagValue tagName="hibernate.id" paramName="column" default="<XDtMethod:propertyName/>" />"
type="<XDtMethod:methodTagValue tagName="hibernate.id" paramName="type" default="<XDtMethod:methodType/>" />"
<XDtMethod:ifHasMethodTag tagName="hibernate.id" paramName="length">
length="<XDtMethod:methodTagValue tagName="hibernate.id" paramName="length" />"
</XDtMethod:ifHasMethodTag>
<XDtMethod:ifHasMethodTag tagName="hibernate.id" paramName="unsaved-value">
unsaved-value="<XDtMethod:methodTagValue tagName="hibernate.id" paramName="unsaved-value" />"
</XDtMethod:ifHasMethodTag>
>
<generator class="<XDtMethod:methodTagValue tagName="hibernate.id" paramName="generator-class" />">
<XDtMethod:forAllMethodTags tagName="hibernate.generator-param" >
<param<XDtConfig:ifConfigParamEquals paramName="version" value="2.0"> name="<XDtMethod:methodTagValue tagName="hibernate.generator-param" paramName="name" />"</XDtConfig:ifConfigParamEquals>><XDtMethod:methodTagValue tagName="hibernate.generator-param" paramName="value" /></param>
</XDtMethod:forAllMethodTags>
<XDtMethod:ifHasMethodTag tagName="hibernate.id" paramName="generator-parameter-1">
<param><XDtMethod:methodTagValue tagName="hibernate.id" paramName="generator-parameter-1" /></param>
</XDtMethod:ifHasMethodTag>
<XDtMethod:ifHasMethodTag tagName="hibernate.id" paramName="generator-parameter-2">
<param><XDtMethod:methodTagValue tagName="hibernate.id" paramName="generator-parameter-2" /></param>
</XDtMethod:ifHasMethodTag>
<XDtMethod:ifHasMethodTag tagName="hibernate.id" paramName="generator-parameter-3">
<param><XDtMethod:methodTagValue tagName="hibernate.id" paramName="generator-parameter-3" /></param>
</XDtMethod:ifHasMethodTag>
</generator>
<XDtHibernate:setCurrentTag name="hibernate.id" mappingElement="id">
<XDtMerge:merge file="xdoclet/modules/hibernate/resources/hibernate-column.xdt">
</XDtMerge:merge>
</XDtHibernate:setCurrentTag>
</id>
</XDtHibernate:ifHasPrimitiveId>
I have not tried it. If you don't go ahead and try it out please tell me as I will follow this up and make sure that this works (or make it work) and submit to JIRA for someone to commit (I don't have commit rights for Xdoclet).
Hope this helps.