axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Schwanke, Kai" <>
Subject axis soap inheritance question
Date Wed, 15 Feb 2006 13:37:34 GMT
Hi there!


I got a problem with axis concerning inheritance. Here's a section of my


<xsd:complexType name="Item">


<xsd:element name="name" type="xsd:string"></xsd:element>




<xsd:complexType name="SubItem">


    <xsd:extension base="stp:Item">


        <xsd:element name="length" type="xsd:int"></xsd:element>






The files are generated correctly by wsdl2java with ant.


Then in the implementation I create a new Sub_Item:


SubItem subItem = new SubItem();




I add this subItem to my response object by using.


response.setItems(new Item[] {subItem})


But the result checked with the soap monitor only shows my SubItem as
usual Item:








Hence my SubItem has been downcasted to a usual Item, loosing the
specific SubItem information.


Shouldn't this work different? Is there something I understand terribly


Thanks for your answers.




View raw message