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

Unified Diff: net/url_request/url_fetcher_core.h

Issue 863253002: Update from https://crrev.com/312600 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: net/url_request/url_fetcher_core.h
diff --git a/net/url_request/url_fetcher_core.h b/net/url_request/url_fetcher_core.h
index 6bf449f5671ea4abeb666b1aaf867114941cf1f9..193edb46528d837529dad147e39fb6c8bfab00f6 100644
--- a/net/url_request/url_fetcher_core.h
+++ b/net/url_request/url_fetcher_core.h
@@ -68,6 +68,9 @@ class URLFetcherCore
uint64 range_offset,
uint64 range_length,
scoped_refptr<base::TaskRunner> file_task_runner);
+ void SetUploadStreamFactory(
+ const std::string& upload_content_type,
+ const URLFetcher::CreateUploadStreamCallback& callback);
void SetChunkedUpload(const std::string& upload_content_type);
// Adds a block of data to be uploaded in a POST body. This can only be
// called after Start().
@@ -203,6 +206,9 @@ class URLFetcherCore
void InformDelegateDownloadProgressInDelegateThread(int64 current,
int64 total);
+ // Check if any upload data is set or not.
+ void AssertHasNoUploadData() const;
+
URLFetcher* fetcher_; // Corresponding fetcher object
GURL original_url_; // The URL we were asked to fetch
GURL url_; // The URL we eventually wound up at
@@ -239,6 +245,8 @@ class URLFetcherCore
// to be uploaded.
uint64 upload_range_length_; // The length of the part of file to be
// uploaded.
+ URLFetcher::CreateUploadStreamCallback
+ upload_stream_factory_; // Callback to create HTTP POST payload.
std::string upload_content_type_; // MIME type of POST payload
std::string referrer_; // HTTP Referer header value and policy
URLRequest::ReferrerPolicy referrer_policy_;

Powered by Google App Engine
This is Rietveld 408576698