| OLD | NEW |
| 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_core.h" | 5 #include "net/url_request/url_fetcher_core.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 DCHECK(request_context_getter); | 240 DCHECK(request_context_getter); |
| 241 request_context_getter_ = request_context_getter; | 241 request_context_getter_ = request_context_getter; |
| 242 } | 242 } |
| 243 | 243 |
| 244 void URLFetcherCore::SetFirstPartyForCookies( | 244 void URLFetcherCore::SetFirstPartyForCookies( |
| 245 const GURL& first_party_for_cookies) { | 245 const GURL& first_party_for_cookies) { |
| 246 DCHECK(first_party_for_cookies_.is_empty()); | 246 DCHECK(first_party_for_cookies_.is_empty()); |
| 247 first_party_for_cookies_ = first_party_for_cookies; | 247 first_party_for_cookies_ = first_party_for_cookies; |
| 248 } | 248 } |
| 249 | 249 |
| 250 void URLFetcherCore::SetRequestorOrigin(const url::Origin& requestor_origin) { |
| 251 requestor_origin_ = requestor_origin; |
| 252 } |
| 253 |
| 250 void URLFetcherCore::SetURLRequestUserData( | 254 void URLFetcherCore::SetURLRequestUserData( |
| 251 const void* key, | 255 const void* key, |
| 252 const URLFetcher::CreateDataCallback& create_data_callback) { | 256 const URLFetcher::CreateDataCallback& create_data_callback) { |
| 253 DCHECK(key); | 257 DCHECK(key); |
| 254 DCHECK(!create_data_callback.is_null()); | 258 DCHECK(!create_data_callback.is_null()); |
| 255 url_request_data_key_ = key; | 259 url_request_data_key_ = key; |
| 256 url_request_create_data_callback_ = create_data_callback; | 260 url_request_create_data_callback_ = create_data_callback; |
| 257 } | 261 } |
| 258 | 262 |
| 259 void URLFetcherCore::SetStopOnRedirect(bool stop_on_redirect) { | 263 void URLFetcherCore::SetStopOnRedirect(bool stop_on_redirect) { |
| (...skipping 669 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 929 } | 933 } |
| 930 | 934 |
| 931 void URLFetcherCore::AssertHasNoUploadData() const { | 935 void URLFetcherCore::AssertHasNoUploadData() const { |
| 932 DCHECK(!upload_content_set_); | 936 DCHECK(!upload_content_set_); |
| 933 DCHECK(upload_content_.empty()); | 937 DCHECK(upload_content_.empty()); |
| 934 DCHECK(upload_file_path_.empty()); | 938 DCHECK(upload_file_path_.empty()); |
| 935 DCHECK(upload_stream_factory_.is_null()); | 939 DCHECK(upload_stream_factory_.is_null()); |
| 936 } | 940 } |
| 937 | 941 |
| 938 } // namespace net | 942 } // namespace net |
| OLD | NEW |