dcsimg
try to treat the SOAP enveloppe response in my class
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   tyris_d
Posted On:   Wednesday, February 20, 2002 06:41 AM

hi all i have a simple class that call a webservice and gets back an xml response, with SOAP. here is a sample : HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8 Content-Length: length <?xml version="1.0" encoding="utf-8"?> Bonjour string i just want to get the string sent in the response (between the tags) what should i do to treat this xml ? for the moment i retrieve this xml this way : URL endpoint = new URL("http://myserver/myapp/SynchronizeProfiles.asmx"); URLConnection con = endpoint.openConnection (); con.setDoInput (tr   More>>

hi all
i have a simple class that call a webservice and gets back an xml response, with SOAP.

here is a sample :

			

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>



Bonjour string






i just want to get the string sent in the response (between the tags)
what should i do to treat this xml ?
for the moment i retrieve this xml this way :


			

URL endpoint = new URL("http://myserver/myapp/SynchronizeProfiles.asmx");
URLConnection con = endpoint.openConnection ();
con.setDoInput (true);
con.setDoOutput (true);
con.setUseCaches (false);
con.setAllowUserInteraction(false);
con.setRequestProperty ("Content-Length", Integer.toString (request.length));
con.setRequestProperty ("Content-Type", "text/xml; charset=utf-8");
con.setRequestProperty ("SOAPAction", ""http://tempuri.org/Bonjour"");
OutputStream out = con.getOutputStream ();
out.write (request);
out.flush ();
out.close();
InputStream in = con.getInputStream();



regards,    <<Less
About | Sitemap | Contact