| 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 CHROME_BROWSER_IO_THREAD_H_ | 5 #ifndef CHROME_BROWSER_IO_THREAD_H_ |
| 6 #define CHROME_BROWSER_IO_THREAD_H_ | 6 #define CHROME_BROWSER_IO_THREAD_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 void SetGlobalsForTesting(Globals* globals); | 215 void SetGlobalsForTesting(Globals* globals); |
| 216 | 216 |
| 217 net_log::ChromeNetLog* net_log(); | 217 net_log::ChromeNetLog* net_log(); |
| 218 | 218 |
| 219 // Handles changing to On The Record mode, discarding confidential data. | 219 // Handles changing to On The Record mode, discarding confidential data. |
| 220 void ChangedToOnTheRecord(); | 220 void ChangedToOnTheRecord(); |
| 221 | 221 |
| 222 // Returns a getter for the URLRequestContext. Only called on the UI thread. | 222 // Returns a getter for the URLRequestContext. Only called on the UI thread. |
| 223 net::URLRequestContextGetter* system_url_request_context_getter(); | 223 net::URLRequestContextGetter* system_url_request_context_getter(); |
| 224 | 224 |
| 225 // Clears the host cache. Intended to be used to prevent exposing recently | 225 // Clears the host cache. Intended to be used to prevent exposing recently |
| 226 // visited sites on about:net-internals/#dns and about:dns pages. Must be | 226 // visited sites on about:net-internals/#dns and about:dns pages. Must be |
| 227 // called on the IO thread. | 227 // called on the IO thread. If |host_filter| is not null, only hosts matched |
| 228 void ClearHostCache(); | 228 // by it are deleted from the cache. |
| 229 void ClearHostCache( |
| 230 const base::Callback<bool(const std::string&)>& host_filter); |
| 229 | 231 |
| 230 const net::HttpNetworkSession::Params& NetworkSessionParams() const; | 232 const net::HttpNetworkSession::Params& NetworkSessionParams() const; |
| 231 | 233 |
| 232 base::TimeTicks creation_time() const; | 234 base::TimeTicks creation_time() const; |
| 233 | 235 |
| 234 // Returns the callback for updating data use prefs. | 236 // Returns the callback for updating data use prefs. |
| 235 const metrics::UpdateUsagePrefCallbackType& GetMetricsDataUseForwarder(); | 237 const metrics::UpdateUsagePrefCallbackType& GetMetricsDataUseForwarder(); |
| 236 | 238 |
| 237 // Registers the |observer| for new STH notifications. | 239 // Registers the |observer| for new STH notifications. |
| 238 void RegisterSTHObserver(net::ct::STHObserver* observer); | 240 void RegisterSTHObserver(net::ct::STHObserver* observer); |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 391 // Callback for updating data use prefs which needs to be initialized on UI | 393 // Callback for updating data use prefs which needs to be initialized on UI |
| 392 // thread and passed to |ChromeNetworkDelegate|. | 394 // thread and passed to |ChromeNetworkDelegate|. |
| 393 metrics::UpdateUsagePrefCallbackType metrics_data_use_forwarder_; | 395 metrics::UpdateUsagePrefCallbackType metrics_data_use_forwarder_; |
| 394 | 396 |
| 395 base::WeakPtrFactory<IOThread> weak_factory_; | 397 base::WeakPtrFactory<IOThread> weak_factory_; |
| 396 | 398 |
| 397 DISALLOW_COPY_AND_ASSIGN(IOThread); | 399 DISALLOW_COPY_AND_ASSIGN(IOThread); |
| 398 }; | 400 }; |
| 399 | 401 |
| 400 #endif // CHROME_BROWSER_IO_THREAD_H_ | 402 #endif // CHROME_BROWSER_IO_THREAD_H_ |
| OLD | NEW |