nsurlsession in soap

NSURLSession *session = [NSURLSession sessionWithConfiguration: [NSURLSessionConfiguration defaultSessionConfiguration] delegate:self delegateQueue:[NSOperationQueue mainQueue]];
NSURLSessionDataTask *task = [session dataTaskWithRequest:_theRequest completionHandler:^(NSData * _Nullable data, NSURLResponse * _Nullable response, NSError * _Nullable error) {
if (error == nil)
{
NSXMLParser *xmlparser = [[NSXMLParser alloc]initWithData:data];
xmlparser.delegate = self;
[xmlparser parse];
[_webResponseData appendData:data];

}

}];

[task resume];
Previous
Next Post »