axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sagi Mann <>
Subject @XmlSeeAlso and/or parameter polymorphism
Date Tue, 30 Sep 2008 18:30:32 GMT

Is there an axis2-equivalent for the JAXWS 2.1 @XmlSeeAlso annotation? I'm
trying to pass a polymorphic parameter to an axis2 web service, but
unfortunately I'm unable to find a way to get the web service to "publish"
the subclasses in its WSDL.

Assuming I have an AbstractBean, and a derived SubBean class, in JAXWS I
would be able to get the web service to "publish" the SubBean class in the
WSDL using the @XmlSeeAlso annotation:

public class Hello {
   // also correctly accepts subclasses of AbstractBean:
   public String testAbstractBeanArg(@WebParam AbstractBean bean) {
      return bean.toString(); 

The resulting WSDL will contain both AbstractBean and SubBean in its schema:

    <xs:complexType name="subBean">
            <xs:extension base="tns:abstractBean">
                    <xs:element name="desc" type="xs:string"
    <xs:complexType name="abstractBean" abstract="true">
            <xs:element name="color" type="xs:string"

How do I do this in axis2? @XmlSeeAlso seems be ignored by axis2 web


View this message in context:
Sent from the Axis - User mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message