Using Soap Web Services in iPhone with wsdl2objc?

人走茶凉 提交于 2020-01-01 00:47:27

问题


I do realize this is a duplicate question, however the only other question is quite old, so I would like to know if anyone has had any recent experience with the latest version of wsdl2objc.

I am doing an application that will communicate with SOAP Web services exposed by a third party application (it only exposes them this way unfortunately). As far as I understand all wsdl2objc does is convert the WSDL to something useful in objective C code. I have also done the tutorial icodeblog intro to soap

So has anyone used the latest version of wsdl2objc?, what is your experience with it?, did you run into any problems with it?. Please let me know. Also some code sample would be really great.

Any information available on using SOAP Web Services with iPhone would be appreciated. Thank you.

-Oscar


回答1:


My most recent experiences with wsdl2objc is that it's on the right road, but not really there yet. It's definitely the kind of program you'd want. It just may or may not be able to handle the WSDLs you actually have.

Short answer: try it and see if it works for your WSDLs. If it does, hooray. If it doesn't, you have two options. For reasonably simple WSDLs, write the SOAP by hand. This often is actually the easiest approach. If the WSDL is complex, then use gSOAP to get to C++ and then wrap the C++ in Objective-C++ (or use the -c option to gSOAP and wrap the resulting C, whichever you're more comfortable with).




回答2:


I think this gives a good example of how to configure your environment (for noobs like me) http://blog.futurebytez.com/2010/05/calling-web-services-using-wsdl2objc.html

The official wiki for wsdl2objc (linked in the article) has a code snippet which gives you the basics.



来源:https://stackoverflow.com/questions/2223199/using-soap-web-services-in-iphone-with-wsdl2objc

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!