Added -rewriteRequestURL:withMethod:headers: hook

This commit is contained in:
Pierre-Olivier Latour
2014-04-28 14:09:15 -07:00
parent f01307b2a7
commit 3b75f9dd20
2 changed files with 17 additions and 1 deletions
@@ -117,6 +117,14 @@
*/
- (void)didWriteBytes:(const void*)bytes length:(NSUInteger)length;
/**
* This method is called after the HTTP headers have been received to
* allow replacing the request URL by another one.
*
* The default implementation returns the original URL.
*/
- (NSURL*)rewriteRequestURL:(NSURL*)url withMethod:(NSString*)method headers:(NSDictionary*)headers;
/**
* Assuming a valid HTTP request was received, this method is called before
* the request is processed.