NSUrlRequest: where an app can find the default headers for HTTP request?

后端 未结 3 1407
有刺的猬
有刺的猬 2020-12-15 14:28

Does anybody know where an iOS app can see the default headers that NSUrlRequest sets for an HTTP request?

Just creating NSUrlRequest with

3条回答
  •  感情败类
    2020-12-15 15:00

    hmm... maybe you might want to try within

    - (NSURLRequest *)connection:(NSURLConnection *)connection willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)redirectResponse
    

    method in your custom nsurlconnection class. although the documentation mentions something about redirects, this is certainly worth looking into.

提交回复
热议问题