We have implemented NSUrlSessionDataDelegate and getting response of GET and POST requests in that delegate.
We need to start 3 NSUrlRequests simultaneously. In DidCompleteWithError callback how can we identify that the response corresponds to a particular request of those 3 requests made. We need to identify this because we have written a common class as network request manager.
We have sent header parameters for inside requests like request.Headers.SetValueForKey(new NSString("OurEndpointName"), new NSString("API"));
In DidCompleteWithError callback we try to retrieve the header parameters sent .But we are not getting those parameters.We tried following 2 ways to read header back
1.NSString strHeader = (NSString)task.CurrentRequest.Headers.ValueForKey(new NSString("API"));
2.NSString strHeader = (NSString)task.OriginalRequest.Headers.ValueForKey(new NSString("API"));
Both of these ways return null.
We have thought of url, absolutepath, relative path parameters in response, but some of the requests have common url structure and they differ only in request parameters.
Thanks & best regards,