How SOAP and REST work with XML/JSON response?
SOAP - "Simple Object Access Protocol"
SOAP is a method of transferring messages, or small amounts of information,
over the Internet. SOAP messages are formatted in XML and are typically sent using HTTP (hypertext transfer protocol).
So SOAP has a standard how a message has to be sent.
Each soap web service can be defined with a WSDL(Web Service Definition Language)
which is kind of a schema for the SOAP XML transferred.
There are many tools available to convert WSDL(your webservice definition) to
native code.
One of the tool available for ObjC is Sudz-C (http://sudzc.com/) which
convert the WDSL of any webservice to ObjC code to access the Web service.
Rest - Representational state transfer
Rest is a simple way of sending and receiving data between client and server and it don't
have any much standards defined , You can send and receive data as JSON,XML or even a Text. Its Light weighted compared to SOAP.
To handle Rest in iOS there are many tools available, I would recommend RestKit http://restkit.org/, for handling XML and JSON both.
I would suggest you to go with Rest for mobile development, since its light weight
|
Nice stuffs to understand clear about SOAP and REST
ReplyDelete