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

Side by Side Diff: net/url_request/url_fetcher_impl.cc

Issue 2405483002: Make the request initiator Optional (Closed)
Patch Set: Addressed comments + rebase Created 4 years, 1 month 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/url_fetcher_impl.h ('k') | net/url_request/url_request.h » ('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 #include "net/url_request/url_fetcher_impl.h" 5 #include "net/url_request/url_fetcher_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/sequenced_task_runner.h" 10 #include "base/sequenced_task_runner.h"
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 85
86 void URLFetcherImpl::AddExtraRequestHeader(const std::string& header_line) { 86 void URLFetcherImpl::AddExtraRequestHeader(const std::string& header_line) {
87 core_->AddExtraRequestHeader(header_line); 87 core_->AddExtraRequestHeader(header_line);
88 } 88 }
89 89
90 void URLFetcherImpl::SetRequestContext( 90 void URLFetcherImpl::SetRequestContext(
91 URLRequestContextGetter* request_context_getter) { 91 URLRequestContextGetter* request_context_getter) {
92 core_->SetRequestContext(request_context_getter); 92 core_->SetRequestContext(request_context_getter);
93 } 93 }
94 94
95 void URLFetcherImpl::SetInitiatorURL(const GURL& initiator) { 95 void URLFetcherImpl::SetInitiator(
96 core_->SetInitiatorURL(initiator); 96 const base::Optional<url::Origin>& initiator) {
97 core_->SetInitiator(initiator);
97 } 98 }
98 99
99 void URLFetcherImpl::SetURLRequestUserData( 100 void URLFetcherImpl::SetURLRequestUserData(
100 const void* key, 101 const void* key,
101 const CreateDataCallback& create_data_callback) { 102 const CreateDataCallback& create_data_callback) {
102 core_->SetURLRequestUserData(key, create_data_callback); 103 core_->SetURLRequestUserData(key, create_data_callback);
103 } 104 }
104 105
105 void URLFetcherImpl::SetStopOnRedirect(bool stop_on_redirect) { 106 void URLFetcherImpl::SetStopOnRedirect(bool stop_on_redirect) {
106 core_->SetStopOnRedirect(stop_on_redirect); 107 core_->SetStopOnRedirect(stop_on_redirect);
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 URLFetcherFactory* URLFetcherImpl::factory() { 226 URLFetcherFactory* URLFetcherImpl::factory() {
226 return g_factory; 227 return g_factory;
227 } 228 }
228 229
229 // static 230 // static
230 void URLFetcherImpl::set_factory(URLFetcherFactory* factory) { 231 void URLFetcherImpl::set_factory(URLFetcherFactory* factory) {
231 g_factory = factory; 232 g_factory = factory;
232 } 233 }
233 234
234 } // namespace net 235 } // namespace net
OLDNEW
« no previous file with comments | « net/url_request/url_fetcher_impl.h ('k') | net/url_request/url_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698