| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_PROFILES_PROFILE_IO_DATA_H_ | 5 #ifndef CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
| 6 #define CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 6 #define CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <set> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
| 12 #include "base/callback.h" | 12 #include "base/callback.h" |
| 13 #include "base/file_path.h" | 13 #include "base/file_path.h" |
| 14 #include "base/memory/ref_counted.h" | 14 #include "base/memory/ref_counted.h" |
| 15 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
| 16 #include "base/memory/weak_ptr.h" | 16 #include "base/memory/weak_ptr.h" |
| 17 #include "base/synchronization/lock.h" | 17 #include "base/synchronization/lock.h" |
| 18 #include "chrome/browser/net/chrome_url_request_context.h" | 18 #include "chrome/browser/net/chrome_url_request_context.h" |
| 19 #include "chrome/browser/prefs/pref_member.h" | 19 #include "chrome/browser/prefs/pref_member.h" |
| 20 #include "content/browser/resource_context.h" | 20 #include "content/browser/resource_context.h" |
| 21 #include "net/base/cookie_monster.h" | 21 #include "net/base/cookie_monster.h" |
| 22 | 22 |
| 23 class CommandLine; | |
| 24 class ChromeAppCacheService; | 23 class ChromeAppCacheService; |
| 25 class ChromeBlobStorageContext; | 24 class ChromeBlobStorageContext; |
| 26 class CookieSettings; | 25 class CookieSettings; |
| 27 class DesktopNotificationService; | 26 class DesktopNotificationService; |
| 28 class DownloadIdFactory; | 27 class DownloadIdFactory; |
| 29 class ExtensionInfoMap; | 28 class ExtensionInfoMap; |
| 30 class HostContentSettingsMap; | 29 class HostContentSettingsMap; |
| 31 class HostZoomMap; | 30 class HostZoomMap; |
| 32 class IOThread; | 31 class IOThread; |
| 33 class Profile; | 32 class Profile; |
| 34 class ProtocolHandlerRegistry; | 33 class ProtocolHandlerRegistry; |
| 35 class TransportSecurityPersister; | 34 class TransportSecurityPersister; |
| 36 | 35 |
| 37 namespace fileapi { | 36 namespace fileapi { |
| 38 class FileSystemContext; | 37 class FileSystemContext; |
| 39 } // namespace fileapi | 38 } // namespace fileapi |
| 40 | 39 |
| 41 namespace media_stream { | 40 namespace media_stream { |
| 42 class MediaStreamManager; | 41 class MediaStreamManager; |
| 43 } // namespace media_stream | 42 } // namespace media_stream |
| 44 | 43 |
| 45 namespace net { | 44 namespace net { |
| 46 class CookieStore; | 45 class CookieStore; |
| 47 class DnsCertProvenanceChecker; | 46 class DnsCertProvenanceChecker; |
| 48 class FraudulentCertificateReporter; | 47 class FraudulentCertificateReporter; |
| 49 class HttpTransactionFactory; | 48 class HttpTransactionFactory; |
| 50 class NetLog; | |
| 51 class OriginBoundCertService; | 49 class OriginBoundCertService; |
| 52 class ProxyConfigService; | 50 class ProxyConfigService; |
| 53 class ProxyService; | 51 class ProxyService; |
| 54 class SSLConfigService; | 52 class SSLConfigService; |
| 55 class TransportSecurityState; | 53 class TransportSecurityState; |
| 56 } // namespace net | 54 } // namespace net |
| 57 | 55 |
| 58 namespace policy { | 56 namespace policy { |
| 59 class URLBlacklistManager; | 57 class URLBlacklistManager; |
| 60 } // namespace policy | 58 } // namespace policy |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 DesktopNotificationService* notification_service; | 161 DesktopNotificationService* notification_service; |
| 164 scoped_refptr<ProtocolHandlerRegistry> protocol_handler_registry; | 162 scoped_refptr<ProtocolHandlerRegistry> protocol_handler_registry; |
| 165 // We need to initialize the ProxyConfigService from the UI thread | 163 // We need to initialize the ProxyConfigService from the UI thread |
| 166 // because on linux it relies on initializing things through gconf, | 164 // because on linux it relies on initializing things through gconf, |
| 167 // and needs to be on the main thread. | 165 // and needs to be on the main thread. |
| 168 scoped_ptr<net::ProxyConfigService> proxy_config_service; | 166 scoped_ptr<net::ProxyConfigService> proxy_config_service; |
| 169 // The profile this struct was populated from. It's passed as a void* to | 167 // The profile this struct was populated from. It's passed as a void* to |
| 170 // ensure it's not accidently used on the IO thread. Before using it on the | 168 // ensure it's not accidently used on the IO thread. Before using it on the |
| 171 // UI thread, call ProfileManager::IsValidProfile to ensure it's alive. | 169 // UI thread, call ProfileManager::IsValidProfile to ensure it's alive. |
| 172 void* profile; | 170 void* profile; |
| 173 | |
| 174 }; | 171 }; |
| 175 | 172 |
| 176 explicit ProfileIOData(bool is_incognito); | 173 explicit ProfileIOData(bool is_incognito); |
| 177 | 174 |
| 178 void InitializeOnUIThread(Profile* profile); | 175 void InitializeOnUIThread(Profile* profile); |
| 179 void ApplyProfileParamsToContext(ChromeURLRequestContext* context) const; | 176 void ApplyProfileParamsToContext(ChromeURLRequestContext* context) const; |
| 180 | 177 |
| 181 // Lazy initializes the ProfileIOData object the first time a request context | 178 // Lazy initializes the ProfileIOData object the first time a request context |
| 182 // is requested. The lazy logic is implemented here. The actual initialization | 179 // is requested. The lazy logic is implemented here. The actual initialization |
| 183 // is done in LazyInitializeInternal(), implemented by subtypes. Static helper | 180 // is done in LazyInitializeInternal(), implemented by subtypes. Static helper |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 319 // One AppRequestContext per isolated app. | 316 // One AppRequestContext per isolated app. |
| 320 mutable AppRequestContextMap app_request_context_map_; | 317 mutable AppRequestContextMap app_request_context_map_; |
| 321 | 318 |
| 322 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. | 319 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. |
| 323 bool initialized_on_UI_thread_; | 320 bool initialized_on_UI_thread_; |
| 324 | 321 |
| 325 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); | 322 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); |
| 326 }; | 323 }; |
| 327 | 324 |
| 328 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 325 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
| OLD | NEW |