| 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 // This class gathers state related to a single user profile. | 5 // This class gathers state related to a single user profile. |
| 6 | 6 |
| 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_IMPL_H_ | 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_IMPL_H_ |
| 8 #define CHROME_BROWSER_PROFILES_PROFILE_IMPL_H_ | 8 #define CHROME_BROWSER_PROFILES_PROFILE_IMPL_H_ |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 public: | 55 public: |
| 56 // Value written to prefs when the exit type is EXIT_NORMAL. Public for tests. | 56 // Value written to prefs when the exit type is EXIT_NORMAL. Public for tests. |
| 57 static const char* const kPrefExitTypeNormal; | 57 static const char* const kPrefExitTypeNormal; |
| 58 | 58 |
| 59 virtual ~ProfileImpl(); | 59 virtual ~ProfileImpl(); |
| 60 | 60 |
| 61 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); | 61 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); |
| 62 | 62 |
| 63 // content::BrowserContext implementation: | 63 // content::BrowserContext implementation: |
| 64 virtual base::FilePath GetPath() const OVERRIDE; | 64 virtual base::FilePath GetPath() const OVERRIDE; |
| 65 virtual bool IsOffTheRecord() const OVERRIDE; |
| 66 virtual content::CookieStoreConfig GetCookieStoreConfig() OVERRIDE; |
| 65 virtual content::DownloadManagerDelegate* | 67 virtual content::DownloadManagerDelegate* |
| 66 GetDownloadManagerDelegate() OVERRIDE; | 68 GetDownloadManagerDelegate() OVERRIDE; |
| 67 virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE; | 69 virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE; |
| 68 virtual net::URLRequestContextGetter* GetRequestContextForRenderProcess( | 70 virtual net::URLRequestContextGetter* GetRequestContextForRenderProcess( |
| 69 int renderer_child_id) OVERRIDE; | 71 int renderer_child_id) OVERRIDE; |
| 70 virtual net::URLRequestContextGetter* GetMediaRequestContext() OVERRIDE; | 72 virtual net::URLRequestContextGetter* GetMediaRequestContext() OVERRIDE; |
| 71 virtual net::URLRequestContextGetter* GetMediaRequestContextForRenderProcess( | 73 virtual net::URLRequestContextGetter* GetMediaRequestContextForRenderProcess( |
| 72 int renderer_child_id) OVERRIDE; | 74 int renderer_child_id) OVERRIDE; |
| 73 virtual net::URLRequestContextGetter* | 75 virtual net::URLRequestContextGetter* |
| 74 GetMediaRequestContextForStoragePartition( | 76 GetMediaRequestContextForStoragePartition( |
| 75 const base::FilePath& partition_path, | 77 const base::FilePath& partition_path, |
| 76 bool in_memory) OVERRIDE; | 78 bool in_memory) OVERRIDE; |
| 77 virtual void RequestMIDISysExPermission( | 79 virtual void RequestMIDISysExPermission( |
| 78 int render_process_id, | 80 int render_process_id, |
| 79 int render_view_id, | 81 int render_view_id, |
| 80 const GURL& requesting_frame, | 82 const GURL& requesting_frame, |
| 81 const MIDISysExPermissionCallback& callback) OVERRIDE; | 83 const MIDISysExPermissionCallback& callback) OVERRIDE; |
| 82 virtual content::ResourceContext* GetResourceContext() OVERRIDE; | 84 virtual content::ResourceContext* GetResourceContext() OVERRIDE; |
| 83 virtual content::GeolocationPermissionContext* | 85 virtual content::GeolocationPermissionContext* |
| 84 GetGeolocationPermissionContext() OVERRIDE; | 86 GetGeolocationPermissionContext() OVERRIDE; |
| 85 virtual quota::SpecialStoragePolicy* GetSpecialStoragePolicy() OVERRIDE; | 87 virtual quota::SpecialStoragePolicy* GetSpecialStoragePolicy() OVERRIDE; |
| 88 virtual void OverrideCookieStoreMap( |
| 89 bool in_memory, |
| 90 const base::FilePath& partition_path, |
| 91 bool is_default, |
| 92 content::CookieStoreMap* cookie_store_map) OVERRIDE; |
| 86 | 93 |
| 87 // Profile implementation: | 94 // Profile implementation: |
| 88 virtual scoped_refptr<base::SequencedTaskRunner> GetIOTaskRunner() OVERRIDE; | 95 virtual scoped_refptr<base::SequencedTaskRunner> GetIOTaskRunner() OVERRIDE; |
| 89 // Note that this implementation returns the Google-services username, if any, | 96 // Note that this implementation returns the Google-services username, if any, |
| 90 // not the Chrome user's display name. | 97 // not the Chrome user's display name. |
| 91 virtual std::string GetProfileName() OVERRIDE; | 98 virtual std::string GetProfileName() OVERRIDE; |
| 92 virtual bool IsOffTheRecord() const OVERRIDE; | |
| 93 virtual Profile* GetOffTheRecordProfile() OVERRIDE; | 99 virtual Profile* GetOffTheRecordProfile() OVERRIDE; |
| 94 virtual void DestroyOffTheRecordProfile() OVERRIDE; | 100 virtual void DestroyOffTheRecordProfile() OVERRIDE; |
| 95 virtual bool HasOffTheRecordProfile() OVERRIDE; | 101 virtual bool HasOffTheRecordProfile() OVERRIDE; |
| 96 virtual Profile* GetOriginalProfile() OVERRIDE; | 102 virtual Profile* GetOriginalProfile() OVERRIDE; |
| 97 virtual bool IsManaged() OVERRIDE; | 103 virtual bool IsManaged() OVERRIDE; |
| 98 virtual history::TopSites* GetTopSites() OVERRIDE; | 104 virtual history::TopSites* GetTopSites() OVERRIDE; |
| 99 virtual history::TopSites* GetTopSitesWithoutCreating() OVERRIDE; | 105 virtual history::TopSites* GetTopSitesWithoutCreating() OVERRIDE; |
| 100 virtual ExtensionService* GetExtensionService() OVERRIDE; | 106 virtual ExtensionService* GetExtensionService() OVERRIDE; |
| 101 virtual ExtensionSpecialStoragePolicy* | 107 virtual ExtensionSpecialStoragePolicy* |
| 102 GetExtensionSpecialStoragePolicy() OVERRIDE; | 108 GetExtensionSpecialStoragePolicy() OVERRIDE; |
| 103 virtual PrefService* GetPrefs() OVERRIDE; | 109 virtual PrefService* GetPrefs() OVERRIDE; |
| 104 virtual PrefService* GetOffTheRecordPrefs() OVERRIDE; | 110 virtual PrefService* GetOffTheRecordPrefs() OVERRIDE; |
| 105 virtual net::URLRequestContextGetter* | |
| 106 GetRequestContextForExtensions() OVERRIDE; | |
| 107 virtual net::SSLConfigService* GetSSLConfigService() OVERRIDE; | 111 virtual net::SSLConfigService* GetSSLConfigService() OVERRIDE; |
| 108 virtual HostContentSettingsMap* GetHostContentSettingsMap() OVERRIDE; | 112 virtual HostContentSettingsMap* GetHostContentSettingsMap() OVERRIDE; |
| 109 virtual bool IsSameProfile(Profile* profile) OVERRIDE; | 113 virtual bool IsSameProfile(Profile* profile) OVERRIDE; |
| 110 virtual base::Time GetStartTime() const OVERRIDE; | 114 virtual base::Time GetStartTime() const OVERRIDE; |
| 111 virtual net::URLRequestContextGetter* CreateRequestContext( | 115 virtual net::URLRequestContextGetter* CreateRequestContext( |
| 112 content::ProtocolHandlerMap* protocol_handlers) OVERRIDE; | 116 content::ProtocolHandlerMap* protocol_handlers) OVERRIDE; |
| 113 virtual net::URLRequestContextGetter* CreateRequestContextForStoragePartition( | 117 virtual net::URLRequestContextGetter* CreateRequestContextForStoragePartition( |
| 114 const base::FilePath& partition_path, | 118 const base::FilePath& partition_path, |
| 115 bool in_memory, | 119 bool in_memory, |
| 116 content::ProtocolHandlerMap* protocol_handlers) OVERRIDE; | 120 content::ProtocolHandlerMap* protocol_handlers) OVERRIDE; |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 247 scoped_ptr<chromeos::Preferences> chromeos_preferences_; | 251 scoped_ptr<chromeos::Preferences> chromeos_preferences_; |
| 248 | 252 |
| 249 scoped_ptr<chromeos::EnterpriseExtensionObserver> | 253 scoped_ptr<chromeos::EnterpriseExtensionObserver> |
| 250 chromeos_enterprise_extension_observer_; | 254 chromeos_enterprise_extension_observer_; |
| 251 | 255 |
| 252 scoped_ptr<chromeos::LocaleChangeGuard> locale_change_guard_; | 256 scoped_ptr<chromeos::LocaleChangeGuard> locale_change_guard_; |
| 253 #endif | 257 #endif |
| 254 | 258 |
| 255 scoped_ptr<PrefProxyConfigTracker> pref_proxy_config_tracker_; | 259 scoped_ptr<PrefProxyConfigTracker> pref_proxy_config_tracker_; |
| 256 | 260 |
| 261 scoped_refptr<net::CookieMonsterDelegate> cookie_delegate_; |
| 262 |
| 257 // STOP!!!! DO NOT ADD ANY MORE ITEMS HERE!!!! | 263 // STOP!!!! DO NOT ADD ANY MORE ITEMS HERE!!!! |
| 258 // | 264 // |
| 259 // Instead, make your Service/Manager/whatever object you're hanging off the | 265 // Instead, make your Service/Manager/whatever object you're hanging off the |
| 260 // Profile use our new BrowserContextKeyedServiceFactory system instead. | 266 // Profile use our new BrowserContextKeyedServiceFactory system instead. |
| 261 // You can find the design document here: | 267 // You can find the design document here: |
| 262 // | 268 // |
| 263 // https://sites.google.com/a/chromium.org/dev/developers/design-documents/p
rofile-architecture | 269 // https://sites.google.com/a/chromium.org/dev/developers/design-documents/p
rofile-architecture |
| 264 // | 270 // |
| 265 // and you can read the raw headers here: | 271 // and you can read the raw headers here: |
| 266 // | 272 // |
| 267 // components/browser_context_keyed_service/browser_context_dependency_manag
er.{h,cc} | 273 // components/browser_context_keyed_service/browser_context_dependency_manag
er.{h,cc} |
| 268 // components/browser_context_keyed_service/browser_context_keyed_service.h | 274 // components/browser_context_keyed_service/browser_context_keyed_service.h |
| 269 // components/browser_context_keyed_service/browser_context_keyed_service_fa
ctory.{h,cc} | 275 // components/browser_context_keyed_service/browser_context_keyed_service_fa
ctory.{h,cc} |
| 270 | 276 |
| 271 Profile::Delegate* delegate_; | 277 Profile::Delegate* delegate_; |
| 272 | 278 |
| 273 chrome_browser_net::Predictor* predictor_; | 279 chrome_browser_net::Predictor* predictor_; |
| 274 | 280 |
| 275 DISALLOW_COPY_AND_ASSIGN(ProfileImpl); | 281 DISALLOW_COPY_AND_ASSIGN(ProfileImpl); |
| 276 }; | 282 }; |
| 277 | 283 |
| 278 #endif // CHROME_BROWSER_PROFILES_PROFILE_IMPL_H_ | 284 #endif // CHROME_BROWSER_PROFILES_PROFILE_IMPL_H_ |
| OLD | NEW |