I have a wsdl that I have written that describes an rpc style web service. When I generate the code using WSDL2Java I get some strange results. Or at least it looks strange to me. the first thing I notice is that I get the following classes:
Item - This represents the complex type I have defined in the WSDL.
Item0 - This seems to be a wrapper class that just has a setItem and getItem method
ItemManagerServiceStub - has a createItem method that takes and Item0
This seems odd to me, I would have expected to see the ItemManagerServiceStub class to have a method called createItem( Item param1 ). Meaning that the client could create a Item object and submit it to the service without having to wrap it in an Item0 object first. If there is a way to achieve this I would like to know how.
Another thing I noticed is that in the ItemManagerServiceStub class that I have submitted I see the following code:
//Style is Doc.
env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), param2, optimizeContent(new javax.xml.namespace.QName("", "createItem")));
This seems strange because the comment says style is doc, when I have set the style to rpc. This code was in the createItem method.
Basically, it just doesn't look like I am really getting a client that looks like a RPC client. The generated API that uses the Item0 class and the //Style is Doc comment are both making me suspicious. Just want to know if I am looking at a defect and/or if there is a way to get what I want. Thanks
Michael MacFadden
Tomax Corp - http://www.tomax.com
[EMAIL PROTECTED]
The views or opinions expressed here are not endorsed by Tomax Corp. They are purely the opinions of the email author.
ItemManagerServiceStub.java
Description: Binary data
example-item.wsdl
Description: Binary data
