Could anyone help me out with this? I don't know how to tell which XML binding is being used (though it looks like Aegis in the generated source?)

Thanks

John Wright wrote:
Is there a way to force XFire to return an instance of a subclass from a method defined as returning the superclass?

I've seen a few posts on this topic, but couldn't seem to find any definite workarounds or a patch. Unfortunately, I have no control over the server end and the client I'm writing *must* pass an instance of the subclass. I'm using version 1.2.4.
Which XML binding are you using?
Aegis: http://xfire.codehaus.org/Aegis+Inheritance
JAXB 2.0: http://xfire.codehaus.org/JAXB+2.0 (scroll down to "JAXB 2 and inheritance")

-Øyvind

I don't know - the model and client classes were generated from WSDL. In the generated source of the client implementation, the Service objects are created like this:

TransportManager tm = (org.codehaus.xfire.XFireFactory.newInstance().getXFire().getTransportManager());
HashMap props = new HashMap();
props.put("annotations.allow.interface", true);
AnnotationServiceFactory asf = new AnnotationServiceFactory(new Jsr181WebAnnotations(), tm, new AegisBindingProvider(new JaxbTypeRegistry()));
//...

Thanks for the links - in either case, it looks I'll have to get access to the raw Service object to apply a fix. Does this mean that I can't use the generated client stub, or is it possible to navigate to the Service object somehow (via getEndpoint() maybe?)

---------------------------------------------------------------------
To unsubscribe from this list please visit:

   http://xircles.codehaus.org/manage_email

Reply via email to