On 16/04/2008, at 12:16 AM, Paul Sandoz wrote:
> Hi Tom,
>
> I think it is due to JAXB marshalling rather than anything specific
> to Jersey. Is an @XmlRootElement present on classes that extend
> RepositoryData?
>
> See the JavaDoc of XmlRootElement [1].
>
Thanks Paul,
I do have @XmlRoot Element on the subclasses.
I think this blog post answers my question:
http://weblogs.java.net/blog/kohsuke/archive/2006/04/why_doesnt_jaxb.html
-- I believe that it applies as much to marshalling to XML as
unmarshalling to Java.
My subclasses aren't statically reachable from the base class, so JAXB
doesn't know about them.
One way to fix this would be to install my own subclass of
XMLJAXBElementProvider which would create a JAXBContext which was
initialised differently -- what's the best way to substitute my
implementation?
Thanks,
Tom
--
ATLASSIAN - http://www.atlassian.com
Our products help over 8,500 customers in more than 95 countries to
collaborate