tags:

views:

43

answers:

2

i want to parse WCF type web service how can i parse it?it contains some different kind of data i have used GET method for that.Data looks like this.

wsdl:definitions

wsp:Policy wsp:ExactlyOne wsp:All

sp:SymmetricBinding

wsp:Policy

sp:ProtectionToken

wsp:Policy sp:SecureConversationToken

wsp:Policy sp:RequireDerivedKeys

sp:BootstrapPolicy wsp:Policy sp:SignedParts sp:Body sp:Header sp:Header sp:Header sp:Header sp:Header sp:Header sp:EncryptedParts sp:Body sp:SymmetricBinding wsp:Policy sp:ProtectionToken wsp:Policy sp:SpnegoContextToken wsp:Policy sp:RequireDerivedKeys sp:AlgorithmSuite wsp:Policy sp:Basic256 sp:Layout wsp:Policy sp:Strict sp:IncludeTimestamp sp:EncryptSignature sp:OnlySignEntireHeadersAndBody sp:Wss11 wsp:Policy sp:MustSupportRefKeyIdentifier sp:MustSupportRefIssuerSerial sp:MustSupportRefThumbprint sp:MustSupportRefEncryptedKey sp:Trust10 wsp:Policy sp:MustSupportIssuedTokens

alt text

A: 

Your given code is in the format of .wsdl file which is api of web service. You have first call the web service using HTTP REST method. After that you will get response of your calling web service, which is in the format of .xml file. After that you will going to parse that xml file using XMLParser class.

Please go through the given link you will get better idea how to be work exactly. http://icodeblog.com/2008/11/03/iphone-programming-tutorial-intro-to-soap-web-services/

RRB
NSURL *url = [NSURL URLWithString:@"http://abcd.svc?wsdl"]; NSMutableURLRequest *theRequest = [NSMutableURLRequest requestWithURL:url]; [theRequest setHTTPMethod:@"GET"]; NSURLConnection *theConnection = [[NSURLConnection alloc] initWithRequest:theRequest delegate:self]; if(theConnection) { webData = [[NSMutableData data] retain]; NSLog( @"connection established"); } else { NSLog(@"theConnection is NULL"); }i have done this way is it ok?what should i do for this?
Ankit Vyas
i don't have soap message just have one url which is like this:http://abcd.svc?wsdl then how it is parsed?
Ankit Vyas
+1  A: 

http://brismith66.blogspot.com/2010/05/iphone-development-accesing-soap.html

Take Reference From this blog it's really helpful.

Ankit Vyas