Chromium Code Reviews| Index: chrome/service/cloud_print/cloud_print_url_fetcher.h |
| =================================================================== |
| --- chrome/service/cloud_print/cloud_print_url_fetcher.h (revision 107156) |
| +++ chrome/service/cloud_print/cloud_print_url_fetcher.h (working copy) |
| @@ -38,6 +38,7 @@ |
| STOP_PROCESSING, |
| RETRY_REQUEST, |
| }; |
| + |
| class Delegate { |
| public: |
| virtual ~Delegate() { } |
| @@ -80,10 +81,20 @@ |
| virtual void OnRequestGiveUp() { } |
| // Invoked when the request returns a 403 error (applicable only when |
| // HandleRawResponse returns CONTINUE_PROCESSING). |
| - virtual void OnRequestAuthError() = 0; |
| + // Returning RETRY_REQUEST will retry current request. (auth information |
| + // may have been updated and new info is available through the |
| + // Authenticator interface). |
| + // Returning CONTINUE_PROCESSING will treat auth error as a netwrok error. |
|
Scott Byer
2011/10/27 22:22:50
nit: spelling
|
| + virtual ResponseAction OnRequestAuthError() = 0; |
| + |
| + // Authentication information may change between retries. |
| + // CloudPrintURLFetcher will request auth info before sending any request. |
| + virtual std::string GetAuthHeader() = 0; |
| }; |
| CloudPrintURLFetcher(); |
| + bool IsSameRequest(const content::URLFetcher* source); |
| + |
| void StartGetRequest(const GURL& url, |
| Delegate* delegate, |
| int max_retries, |