Re: When to use undocumented wsdl2java --wrapArrays?
Jarmo, Please go thru the old commits. It's a hairy situation trying to support all kinds of stuff. Yes, if we get support from you all in terms of patches, we can do things better. Please remember this is a open source, volunteer project :( http://marc.theaimsgroup.com/?l=axis-devw=2r=1s=unwrapArraysq=b http://marc.theaimsgroup.com/?l=axis-devw=2r=1s=wrapArraysq=b thanks, dims On 11/10/05, Pete Hendry [EMAIL PROTECTED] wrote: -Original Message- From: Jarmo Doc [mailto:[EMAIL PROTECTED] Sent: Thursday, 10 November 2005 5:52 p.m. To: axis-user@ws.apache.org Subject: RE: When to use undocumented wsdl2java --wrapArrays? Thanks for the comprehensive answer Pete. Having switched to using wrapped arrays (and changing server code, client code, and WSDL!) my code now works. I was surprised to find that I had to change the server-side code so that each class contained an ArrayOfXXX rather than XXX []. Without this (seemingly unnecessary) layer of indirection I couldn't get the code to work at all. For example: using simple document/literal rather than wrapped caused me to lose all 2nd and subsequent parameters to all my operations. This is an issue with Axis. I believe .NET and others (including ours) recognize a wrapped array and map to [] accordingly without the wrapping Java class. This is obviously a drawback which may want you to try to get it working without wrapping if that makes the code easier. rantWho would specify an interface where this kind of mess was even a possibility never mind a likelihood? If you want to surround arrays with array ... /array or something else then that's fine but surely you don't have to involve me (and my server-side code, client-side code, and WSDL!) in the decision. We've had arrays since about the Stone Age so it's not as if the people specifying these interfaces didn't know about them./rant There is, unfortunately, a number of areas in schema that map poorly to some (all in some cases) programming languages, or present alternatives (such as arrays) which each have different benefits/drawbacks. Don't hold your breath for this to be resolved as schema 1.1 is not touching on these problems I don't believe. Pete -- Davanum Srinivas : http://wso2.com/blogs/
RE: When to use undocumented wsdl2java --wrapArrays?
Thanks for the comprehensive answer Pete. Having switched to using wrapped arrays (and changing server code, client code, and WSDL!) my code now works. I was surprised to find that I had to change the server-side code so that each class contained an ArrayOfXXX rather than XXX []. Without this (seemingly unnecessary) layer of indirection I couldn't get the code to work at all. For example: using simple document/literal rather than wrapped caused me to lose all 2nd and subsequent parameters to all my operations. rantWho would specify an interface where this kind of mess was even a possibility never mind a likelihood? If you want to surround arrays with array ... /array or something else then that's fine but surely you don't have to involve me (and my server-side code, client-side code, and WSDL!) in the decision. We've had arrays since about the Stone Age so it's not as if the people specifying these interfaces didn't know about them./rant That said, I appreciate your answer. Very helpful. From: Pete Hendry [EMAIL PROTECTED] Reply-To: axis-user@ws.apache.org To: axis-user@ws.apache.org CC: [EMAIL PROTECTED] Subject: RE: When to use undocumented wsdl2java --wrapArrays? Date: Thu, 10 Nov 2005 16:58:34 +1300 [snip long useful post] _ FREE pop-up blocking with the new MSN Toolbar get it now! http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/
RE: When to use undocumented wsdl2java --wrapArrays?
-Original Message- From: Jarmo Doc [mailto:[EMAIL PROTECTED] Sent: Thursday, 10 November 2005 5:52 p.m. To: axis-user@ws.apache.org Subject: RE: When to use undocumented wsdl2java --wrapArrays? Thanks for the comprehensive answer Pete. Having switched to using wrapped arrays (and changing server code, client code, and WSDL!) my code now works. I was surprised to find that I had to change the server-side code so that each class contained an ArrayOfXXX rather than XXX []. Without this (seemingly unnecessary) layer of indirection I couldn't get the code to work at all. For example: using simple document/literal rather than wrapped caused me to lose all 2nd and subsequent parameters to all my operations. This is an issue with Axis. I believe .NET and others (including ours) recognize a wrapped array and map to [] accordingly without the wrapping Java class. This is obviously a drawback which may want you to try to get it working without wrapping if that makes the code easier. rantWho would specify an interface where this kind of mess was even a possibility never mind a likelihood? If you want to surround arrays with array ... /array or something else then that's fine but surely you don't have to involve me (and my server-side code, client-side code, and WSDL!) in the decision. We've had arrays since about the Stone Age so it's not as if the people specifying these interfaces didn't know about them./rant There is, unfortunately, a number of areas in schema that map poorly to some (all in some cases) programming languages, or present alternatives (such as arrays) which each have different benefits/drawbacks. Don't hold your breath for this to be resolved as schema 1.1 is not touching on these problems I don't believe. Pete