| 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 #ifndef ANDROID_WEBVIEW_BROWSER_NET_AW_URL_REQUEST_CONTEXT_GETTER_H_ | 5 #ifndef ANDROID_WEBVIEW_BROWSER_NET_AW_URL_REQUEST_CONTEXT_GETTER_H_ |
| 6 #define ANDROID_WEBVIEW_BROWSER_NET_AW_URL_REQUEST_CONTEXT_GETTER_H_ | 6 #define ANDROID_WEBVIEW_BROWSER_NET_AW_URL_REQUEST_CONTEXT_GETTER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 // AwBrowserContext::CreateRequestContext() call this method. | 62 // AwBrowserContext::CreateRequestContext() call this method. |
| 63 // This method is necessary because the passed in objects are created | 63 // This method is necessary because the passed in objects are created |
| 64 // on the UI thread while |job_factory_| must be created on the IO thread. | 64 // on the UI thread while |job_factory_| must be created on the IO thread. |
| 65 void SetHandlersAndInterceptors( | 65 void SetHandlersAndInterceptors( |
| 66 content::ProtocolHandlerMap* protocol_handlers, | 66 content::ProtocolHandlerMap* protocol_handlers, |
| 67 content::URLRequestInterceptorScopedVector request_interceptors); | 67 content::URLRequestInterceptorScopedVector request_interceptors); |
| 68 | 68 |
| 69 void InitializeURLRequestContext(); | 69 void InitializeURLRequestContext(); |
| 70 | 70 |
| 71 // This is called to create a HttpAuthHandlerFactory that will handle | 71 // This is called to create a HttpAuthHandlerFactory that will handle |
| 72 // negotiate challenges for the new URLRequestContext | 72 // auth challenges for the new URLRequestContext |
| 73 scoped_ptr<net::HttpAuthHandlerFactory> | 73 scoped_ptr<net::HttpAuthHandlerFactory> CreateAuthHandlerFactory( |
| 74 CreateNegotiateAuthHandlerFactory(net::HostResolver* resolver); | 74 net::HostResolver* resolver); |
| 75 | 75 |
| 76 const base::FilePath cache_path_; | 76 const base::FilePath cache_path_; |
| 77 | 77 |
| 78 scoped_ptr<net::NetLog> net_log_; | 78 scoped_ptr<net::NetLog> net_log_; |
| 79 scoped_ptr<net::ProxyConfigService> proxy_config_service_; | 79 scoped_ptr<net::ProxyConfigService> proxy_config_service_; |
| 80 scoped_refptr<net::CookieStore> cookie_store_; | 80 scoped_refptr<net::CookieStore> cookie_store_; |
| 81 scoped_ptr<net::URLRequestJobFactory> job_factory_; | 81 scoped_ptr<net::URLRequestJobFactory> job_factory_; |
| 82 scoped_ptr<net::HttpUserAgentSettings> http_user_agent_settings_; | 82 scoped_ptr<net::HttpUserAgentSettings> http_user_agent_settings_; |
| 83 // http_auth_preferences_ holds the preferences for the negotiate | 83 // http_auth_preferences_ holds the preferences for the negotiate |
| 84 // authenticator. | 84 // authenticator. |
| 85 scoped_ptr<net::HttpAuthPreferences> http_auth_preferences_; | 85 scoped_ptr<net::HttpAuthPreferences> http_auth_preferences_; |
| 86 scoped_ptr<net::URLRequestContext> url_request_context_; | 86 scoped_ptr<net::URLRequestContext> url_request_context_; |
| 87 | 87 |
| 88 // Store HTTP Auth-related policies in this thread. | 88 // Store HTTP Auth-related policies in this thread. |
| 89 std::string auth_android_negotiate_account_type_; | 89 std::string auth_android_negotiate_account_type_; |
| 90 std::string auth_server_whitelist_; | 90 std::string auth_server_whitelist_; |
| 91 | 91 |
| 92 // ProtocolHandlers and interceptors are stored here between | 92 // ProtocolHandlers and interceptors are stored here between |
| 93 // SetHandlersAndInterceptors() and the first GetURLRequestContext() call. | 93 // SetHandlersAndInterceptors() and the first GetURLRequestContext() call. |
| 94 content::ProtocolHandlerMap protocol_handlers_; | 94 content::ProtocolHandlerMap protocol_handlers_; |
| 95 content::URLRequestInterceptorScopedVector request_interceptors_; | 95 content::URLRequestInterceptorScopedVector request_interceptors_; |
| 96 | 96 |
| 97 DISALLOW_COPY_AND_ASSIGN(AwURLRequestContextGetter); | 97 DISALLOW_COPY_AND_ASSIGN(AwURLRequestContextGetter); |
| 98 }; | 98 }; |
| 99 | 99 |
| 100 } // namespace android_webview | 100 } // namespace android_webview |
| 101 | 101 |
| 102 #endif // ANDROID_WEBVIEW_BROWSER_NET_AW_URL_REQUEST_CONTEXT_GETTER_H_ | 102 #endif // ANDROID_WEBVIEW_BROWSER_NET_AW_URL_REQUEST_CONTEXT_GETTER_H_ |
| OLD | NEW |