|
|
||
Jitendra Kotamraju's BlogControl Over JAXBContext in JAX-WS RI/MetroPosted by jitu on August 29, 2008 at 04:20 PM | Comments (0)Thanks to Kohsuke who created @UsesJAXBContext feature(after many reminders!! yeah, yeah he is busy with many other things like hudson, Brazil trip!!). Basically, this feature provides a JAXBRIContext that needs to be used in the runtime. Here is an endpoint sample that uses this feature:
@WebService
@UsesJAXBContext(ServerJAXBContextFactory.class)
public class EchoImpl {
...
}
public class ServerJAXBContextFactory implements JAXBContextFactory {
public JAXBRIContext createJAXBContext(...) throws JAXBException {
...
}
}
I added two test cases:
custom_client_jaxbcontext,
custom_server_jaxbcontext. Both these test cases create their own JAXBRIContext to do type substitution(but doesn't use @XmlSeeAlso). I think that it is also possible to influence (Un)Marshallers that are used by JAX-WS RI runtime using this feature.
Try the 2.1.x nightly and let us know your feedback. The feature will be part of JAX-WS RI 2.1.5/Metro 1.4.
Bookmark blog post: CommentsComments are listed in date ascending order (oldest first) | Post Comment | ||
|
|