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

Unified Diff: components/cronet/url_request_context_config.h

Issue 2952653002: Make ParseAndSetExperimentalOptions() a member of URLRequestContextConfig (Closed)
Patch Set: oops Created 3 years, 6 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
« no previous file with comments | « no previous file | components/cronet/url_request_context_config.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/cronet/url_request_context_config.h
diff --git a/components/cronet/url_request_context_config.h b/components/cronet/url_request_context_config.h
index 6e55a92a29e665e6ed0626039ef1f67316ff76f2..41ba045d92c0f32175c079e5f504e984cb0aa74d 100644
--- a/components/cronet/url_request_context_config.h
+++ b/components/cronet/url_request_context_config.h
@@ -12,11 +12,11 @@
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_vector.h"
#include "base/time/time.h"
+#include "base/values.h"
#include "net/base/hash_value.h"
#include "net/cert/cert_verifier.h"
namespace base {
-class DictionaryValue;
class SequencedTaskRunner;
} // namespace base
@@ -30,6 +30,8 @@ namespace cronet {
// Common configuration parameters used by Cronet to configure
// URLRequestContext.
+// TODO(mgersh): This shouldn't be a struct, and experimental option parsing
+// should be kept more separate from applying the configuration.
struct URLRequestContextConfig {
// Type of HTTP cache.
// GENERATED_JAVA_ENUM_PACKAGE: org.chromium.net.impl
@@ -166,9 +168,17 @@ struct URLRequestContextConfig {
ScopedVector<Pkp> pkp_list;
// Experimental options that are recognized by the config parser.
- std::unique_ptr<base::DictionaryValue> effective_experimental_options;
+ std::unique_ptr<base::DictionaryValue> effective_experimental_options =
+ nullptr;
private:
+ // Parses experimental options and makes appropriate changes to settings in
+ // the URLRequestContextConfig and URLRequestContextBuilder.
+ void ParseAndSetExperimentalOptions(
+ net::URLRequestContextBuilder* context_builder,
+ net::NetLog* net_log,
+ const scoped_refptr<base::SequencedTaskRunner>& file_task_runner);
+
DISALLOW_COPY_AND_ASSIGN(URLRequestContextConfig);
};
« no previous file with comments | « no previous file | components/cronet/url_request_context_config.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698