users@jaxb.java.net

Re: IDREF

From: Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_Sun.COM>
Date: Wed, 15 Nov 2006 18:06:59 -0800

Which version of the JAXB RI do you use? If it's a recent enough version
  (let's say >=2.0.3) and you still see this problem, please file a bug
with a test case.

Mark Emeny wrote:
> Hi,
>
>
>
> I have the following field:
>
>
>
> @XmlIDREF
>
> @XmlElement(name = "OwnedItem")
>
> private Set<OwnedItem> ownedItems;
>
>
>
> and I'm expecting an element named "OwnedItem" with a type of xs:IDREF.
> Instead, the IDREF annotation is ignored and I am left with a simple
> element named OwnedItem.
>
>
>
> The documentation says these two annotations are compatible. I can only
> get it working the way I want if I omit the XmlElement annotation (but
> then I have no control over the name of the element).
>
>
>
> Any ideas?
>
>
>
> Many thanks,
>
>
>
> Mark Emeny.
>
>
>
>
>


-- 
Kohsuke Kawaguchi
Sun Microsystems                   kohsuke.kawaguchi_at_sun.com