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

Side by Side Diff: components/cronet/url_request_context_config.cc

Issue 2567093002: [cronet] Add a Builder class for UrlRequestContextConfig (Closed)
Patch Set: try fixing build (per #19) Created 3 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 unified diff | Download patch
« no previous file with comments | « components/cronet/url_request_context_config.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/cronet/url_request_context_config.h" 5 #include "components/cronet/url_request_context_config.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/json/json_reader.h" 9 #include "base/json/json_reader.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after
385 cert_verifier = base::MakeUnique<net::CachingCertVerifier>( 385 cert_verifier = base::MakeUnique<net::CachingCertVerifier>(
386 std::move(mock_cert_verifier)); 386 std::move(mock_cert_verifier));
387 } else { 387 } else {
388 // net::CertVerifier::CreateDefault() returns a CachingCertVerifier. 388 // net::CertVerifier::CreateDefault() returns a CachingCertVerifier.
389 cert_verifier = net::CertVerifier::CreateDefault(); 389 cert_verifier = net::CertVerifier::CreateDefault();
390 } 390 }
391 context_builder->SetCertVerifier(std::move(cert_verifier)); 391 context_builder->SetCertVerifier(std::move(cert_verifier));
392 // TODO(mef): Use |config| to set cookies. 392 // TODO(mef): Use |config| to set cookies.
393 } 393 }
394 394
395 URLRequestContextConfigBuilder::URLRequestContextConfigBuilder() {}
396 URLRequestContextConfigBuilder::~URLRequestContextConfigBuilder() {}
397
398 std::unique_ptr<URLRequestContextConfig>
399 URLRequestContextConfigBuilder::Build() {
400 return base::MakeUnique<URLRequestContextConfig>(
401 enable_quic, quic_user_agent_id, enable_spdy, enable_sdch, http_cache,
402 http_cache_max_size, load_disable_cache, storage_path, user_agent,
403 experimental_options, data_reduction_proxy_key,
404 data_reduction_primary_proxy, data_reduction_fallback_proxy,
405 data_reduction_secure_proxy_check_url, std::move(mock_cert_verifier),
406 enable_network_quality_estimator,
407 bypass_public_key_pinning_for_local_trust_anchors, cert_verifier_data);
408 }
409
395 } // namespace cronet 410 } // namespace cronet
OLDNEW
« no previous file with comments | « components/cronet/url_request_context_config.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698