1- How do i create soap messages to communicate with a web service? Let’s say my client needs to send a request to a web service, Do i generate the FULL soap string and then send it to the web service, including header, body, envelop etc?
2- Let’s say the web service sends me back a SOAP response, the response contains information about 4 different users info in my database?
How do i convert the soap message to 4 “objects of User”?
Do i need to loop through the message and read each parameter 1 by 1, and create my “User” objects? or is there an easier way of matching the parameters in the soap message with parameters in my class and create the objects automatically?
If you have the
WSDLof thatwebservice, manyIDE‘s have the ability to import theWSDLand auto generate a client program for the bindings.So, if the
webservicereturns manyUSERobjects, yourIDE‘ will generate them back. If not, it will generateobjectsfor the kind of response yourwebservicereturns.With those
objects, i think will be easier to extract theusersfrom it than from the rawenvelope