Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(196)

Side by Side Diff: net/url_request/url_fetcher_core.h

Issue 2378173002: Precache per-resource cap should be applied on network bytes used (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « net/url_request/test_url_fetcher_factory.cc ('k') | net/url_request/url_fetcher_core.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 NET_URL_REQUEST_URL_FETCHER_CORE_H_ 5 #ifndef NET_URL_REQUEST_URL_FETCHER_CORE_H_
6 #define NET_URL_REQUEST_URL_FETCHER_CORE_H_ 6 #define NET_URL_REQUEST_URL_FETCHER_CORE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 void DidWriteBuffer(scoped_refptr<DrainableIOBuffer> data, int result); 213 void DidWriteBuffer(scoped_refptr<DrainableIOBuffer> data, int result);
214 214
215 // Read response bytes from the request. 215 // Read response bytes from the request.
216 void ReadResponse(); 216 void ReadResponse();
217 217
218 // Notify Delegate about the progress of upload/download. 218 // Notify Delegate about the progress of upload/download.
219 void InformDelegateUploadProgress(); 219 void InformDelegateUploadProgress();
220 void InformDelegateUploadProgressInDelegateThread(int64_t current, 220 void InformDelegateUploadProgressInDelegateThread(int64_t current,
221 int64_t total); 221 int64_t total);
222 void InformDelegateDownloadProgress(); 222 void InformDelegateDownloadProgress();
223 void InformDelegateDownloadProgressInDelegateThread(int64_t current, 223 void InformDelegateDownloadProgressInDelegateThread(
224 int64_t total); 224 int64_t current,
225 int64_t total,
226 int64_t current_network_bytes);
225 227
226 // Check if any upload data is set or not. 228 // Check if any upload data is set or not.
227 void AssertHasNoUploadData() const; 229 void AssertHasNoUploadData() const;
228 230
229 URLFetcher* fetcher_; // Corresponding fetcher object 231 URLFetcher* fetcher_; // Corresponding fetcher object
230 GURL original_url_; // The URL we were asked to fetch 232 GURL original_url_; // The URL we were asked to fetch
231 GURL url_; // The URL we eventually wound up at 233 GURL url_; // The URL we eventually wound up at
232 URLFetcher::RequestType request_type_; // What type of request is this? 234 URLFetcher::RequestType request_type_; // What type of request is this?
233 URLRequestStatus status_; // Status of the request 235 URLRequestStatus status_; // Status of the request
234 URLFetcherDelegate* delegate_; // Object to notify on completion 236 URLFetcherDelegate* delegate_; // Object to notify on completion
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 int64_t total_response_bytes_; 347 int64_t total_response_bytes_;
346 348
347 static base::LazyInstance<Registry> g_registry; 349 static base::LazyInstance<Registry> g_registry;
348 350
349 DISALLOW_COPY_AND_ASSIGN(URLFetcherCore); 351 DISALLOW_COPY_AND_ASSIGN(URLFetcherCore);
350 }; 352 };
351 353
352 } // namespace net 354 } // namespace net
353 355
354 #endif // NET_URL_REQUEST_URL_FETCHER_CORE_H_ 356 #endif // NET_URL_REQUEST_URL_FETCHER_CORE_H_
OLDNEW
« no previous file with comments | « net/url_request/test_url_fetcher_factory.cc ('k') | net/url_request/url_fetcher_core.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698