Hi,
I was working with ActionWebService when i noticed it wasn't WS-I compliant in the way it generates WSDL for arrays.
So i fixed it. I also changed the tag containing the elements from xsd:all to xsd:sequence. The latter enables you to keep the parameters in order.
The former makes it possible to use the WSDL in other WS-I compl. products like axis.
Look here for some explanation on how array should be used in WS-I: http://www.ws-i.org/Profiles/BasicProfile-1.1.html#soapenc_Array
I have not been able to do much testing but i don't think i has any strange implications.
One thing that might seem a bit strange is creating a new type containing only an array of one type of element. This however is necessary so that the you can return an array without specifying a wrapper type orso.
i'll put the diff with the code change below. This is my first patch, and ticket for that matter, so tell me if i did something wrong :)
Arthur
actionwebservice/lib/action_web_service/dispatcher/action_controller_dispatcher.rb
219,223c219,223
< xm.xsd(:complexContent) do
< xm.xsd(:restriction, 'base' => 'soapenc:Array') do
< xm.xsd(:attribute, 'ref' => 'soapenc:arrayType',
< 'wsdl:arrayType' => binding.element_binding.qualified_type_name('typens') + '[]')
< end
---
> xm.xsd(:sequence) do
> xm.xsd(:element, 'type' => binding.element_binding.qualified_type_name('typens'),
> 'name' => binding.type.name,
> 'minOccurs' => '0',
> 'maxOccurs' => 'unbounded')
228c228
< xm.xsd(:all) do
---
> xm.xsd(:sequence) do