You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@xml.apache.org by Prasad Badkas <pr...@mahindrabt.com> on 2002/05/18 18:31:59 UTC
2-d Arrays as method argument and return type
Hi
I am trying to invoke a method which accepts 2-d arrays as input parameters
and return type is also a 2-d array. I am using MS SOAP toolkit on server
side and Apache SOAP on client side. I was successful to invoke methods
accepting and returning 1 - dimensional arrays by using the default
serializer (ArraySerializer) provided in the API. I tried to extend same
logic to cover multi-dimensional arrays. I modified the .wsdl file to define
the 2-d array as follows to indicate that ArrayOfString2d is composed of 2
data types of ArrayOfString type. The complex type for "ArrayOfString" is
auto generated by the WSDL generator of MS SOAP Toolkit.
****
<complexType name ='ArrayOfstring'>
<complexContent>
<restriction base='SOAP-ENC:Array'>
<attribute ref='SOAP-ENC:arrayType' wsdl:arrayType='string[]'/>
</restriction>
</complexContent>
</complexType>
<complexType name ="ArrayOfstring2d">
<sequence>
<element name = 'arr0' type = 'ArrayOfstring'/>
<element name = 'arr1' type = 'ArrayOfstring'/>
</sequence>
</complexType>
****
The request gets generated successfully but I get following error :
Fault Code = SOAP-ENV:Server
Fault String = WSDLOperation: The SoapMapper name had a type which could
not be converted during IDispatch::Invoke
Any workaround for above ?
Thanks,
Prasad