Chromium Code Reviews| Index: components/offline_pages/core/prefetch/prefetch_request_fetcher.h |
| diff --git a/components/offline_pages/core/prefetch/prefetch_request_fetcher.h b/components/offline_pages/core/prefetch/prefetch_request_fetcher.h |
| index 09c543ab0bbfd0352ad4bda17e6792013e2043f6..0134510f3c8fe6afd7b285e29fb2b6b1e1e9e24e 100644 |
| --- a/components/offline_pages/core/prefetch/prefetch_request_fetcher.h |
| +++ b/components/offline_pages/core/prefetch/prefetch_request_fetcher.h |
| @@ -11,19 +11,21 @@ |
| #include "components/offline_pages/core/prefetch/prefetch_types.h" |
| #include "net/url_request/url_fetcher_delegate.h" |
| -class GURL; |
| namespace net { |
| class URLRequestContextGetter; |
| } |
| namespace offline_pages { |
| +// Asynchronously fetches the offline prefetch related data from the server. |
| class PrefetchRequestFetcher : public net::URLFetcherDelegate { |
| public: |
| using FinishedCallback = base::Callback<void(PrefetchRequestStatus status, |
| const std::string& data)>; |
| - PrefetchRequestFetcher(const GURL& url, |
| + // If |message| is empty, the GET request is sent. Otherwise, the POST request |
| + // is sent with |message| as post data. |
| + PrefetchRequestFetcher(const std::string& url_path, |
|
dewittj
2017/05/16 18:30:20
Can you make two constructors, one that is for pos
jianli
2017/05/16 22:44:40
Changed to 2 static creator methods since their na
|
| const std::string& message, |
| net::URLRequestContextGetter* request_context_getter, |
| const FinishedCallback& callback); |