-
1. Re: XmlSeeAlso
heiko.braun Mar 20, 2008 2:44 PM (in response to dlofthouse)Hi Darran,
here is what i came up with.
We got two problems:
a) Type substitution at runtime
b) Tooling support for inheritance
The first one is supported since we introduced JAXB 2.1.
Please see the following JIRA as reference.
http://jira.jboss.org/jira/browse/JBWS-1591
It's basically there since 2.0.
The tooling is not available and will come with JAX-WS 2.1,
which we currently don't support. However the tests have shown that manually adding the @XmlSeeAlso annotation to your samples does work as expected.
Please see the following references for further explanations:
https://jax-ws.dev.java.net/roadmap/jaxws21-plan.html
http://weblogs.java.net/blog/kohlert/archive/community_java_web_services_and_xml/index.html -
2. Re: XmlSeeAlso
heiko.braun Apr 1, 2008 10:34 AM (in response to dlofthouse)I've tested the scenario with both Metro and Native. I had to put the XmlSeeAlso annotation manually (tooling issue):
@XmlSeeAlso(USAddressType.class)
public class AddressResponse {
...
}
Both Native and Metro handle request and response in the same way.
They receive a USAddress instance (requires casting though) and respond with a correct xsd:type attribute on the AddressResponse super element.
IMO, everything is fine and works as expected, besides the tooling problem.
But that's something we cannot easily fix without going to JAXWS 2.1.
Here's is a quick oveview how JAXB handles xsd:any types:
https://jaxb.dev.java.net/guide/Mapping_of__xs_any___.html