OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_PUBLIC_COMMON_URL_FETCHER_H_ | 5 #ifndef CONTENT_PUBLIC_COMMON_URL_FETCHER_H_ |
6 #define CONTENT_PUBLIC_COMMON_URL_FETCHER_H_ | 6 #define CONTENT_PUBLIC_COMMON_URL_FETCHER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 | 181 |
182 // Start the request. After this is called, you may not change any other | 182 // Start the request. After this is called, you may not change any other |
183 // settings. | 183 // settings. |
184 virtual void Start() = 0; | 184 virtual void Start() = 0; |
185 | 185 |
186 // Restarts the URLFetcher with a new URLRequestContextGetter. | 186 // Restarts the URLFetcher with a new URLRequestContextGetter. |
187 virtual void StartWithRequestContextGetter( | 187 virtual void StartWithRequestContextGetter( |
188 net::URLRequestContextGetter* request_context_getter) = 0; | 188 net::URLRequestContextGetter* request_context_getter) = 0; |
189 | 189 |
190 // Return the URL that we were asked to fetch. | 190 // Return the URL that we were asked to fetch. |
191 virtual const GURL& GetOriginalUrl() const = 0; | 191 virtual const GURL& GetOriginalURL() const = 0; |
192 | 192 |
193 // Return the URL that this fetcher is processing. | 193 // Return the URL that this fetcher is processing. |
194 virtual const GURL& GetUrl() const = 0; | 194 virtual const GURL& GetURL() const = 0; |
195 | 195 |
196 // The status of the URL fetch. | 196 // The status of the URL fetch. |
197 virtual const net::URLRequestStatus& GetStatus() const = 0; | 197 virtual const net::URLRequestStatus& GetStatus() const = 0; |
198 | 198 |
199 // The http response code received. Will return RESPONSE_CODE_INVALID | 199 // The http response code received. Will return RESPONSE_CODE_INVALID |
200 // if an error prevented any response from being received. | 200 // if an error prevented any response from being received. |
201 virtual int GetResponseCode() const = 0; | 201 virtual int GetResponseCode() const = 0; |
202 | 202 |
203 // Cookies recieved. | 203 // Cookies recieved. |
204 virtual const net::ResponseCookies& GetCookies() const = 0; | 204 virtual const net::ResponseCookies& GetCookies() const = 0; |
(...skipping 16 matching lines...) Expand all Loading... |
221 // true, caller takes responsibility for the temp file, and it will not | 221 // true, caller takes responsibility for the temp file, and it will not |
222 // be removed once the URLFetcher is destroyed. User should not take | 222 // be removed once the URLFetcher is destroyed. User should not take |
223 // ownership more than once, or call this method after taking ownership. | 223 // ownership more than once, or call this method after taking ownership. |
224 virtual bool GetResponseAsFilePath(bool take_ownership, | 224 virtual bool GetResponseAsFilePath(bool take_ownership, |
225 FilePath* out_response_path) const = 0; | 225 FilePath* out_response_path) const = 0; |
226 }; | 226 }; |
227 | 227 |
228 } // namespace content | 228 } // namespace content |
229 | 229 |
230 #endif // CONTENT_PUBLIC_COMMON_URL_FETCHER_H_ | 230 #endif // CONTENT_PUBLIC_COMMON_URL_FETCHER_H_ |
OLD | NEW |