You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cxf.apache.org by TonyTheFish <to...@gamesys.co.uk> on 2008/01/22 18:49:36 UTC
Is it possible to use polymorphic types in a REST endpoint?
I am working on a proof of concept application that uses cxf and jaxb. What
I want to do is feed parameters of type FooA, FooB, FooC to an endpoint that
accepts Foo (superclass) objects. Something like this:
@HttpMethod("POST")
@ProduceMime("application/xml")
@UriTemplate("/foo/")
public Response addFoo(Foo foo) { ... stuff ... }
No matter how I manipulate the jaxb annotations on the Foo hierarchy I
cannot persuade addFoo() to accept a FooA object. Is this even possible?
--
View this message in context: http://www.nabble.com/Is-it-possible-to-use-polymorphic-types-in-a-REST-endpoint--tp15024314p15024314.html
Sent from the cxf-dev mailing list archive at Nabble.com.