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 CONTENT_PUBLIC_BROWSER_BROWSER_CONTEXT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_BROWSER_CONTEXT_H_ |
6 #define CONTENT_PUBLIC_BROWSER_BROWSER_CONTEXT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_BROWSER_CONTEXT_H_ |
7 | 7 |
8 #include "base/callback_forward.h" | 8 #include "base/callback_forward.h" |
9 #include "base/containers/hash_tables.h" | 9 #include "base/containers/hash_tables.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 // BrowserContext initializs the corresponding getters when its objects are | 100 // BrowserContext initializs the corresponding getters when its objects are |
101 // created, but if the embedder wants to pass the ResourceContext to another | 101 // created, but if the embedder wants to pass the ResourceContext to another |
102 // thread before they use BrowserContext, they should call this to make sure | 102 // thread before they use BrowserContext, they should call this to make sure |
103 // that the ResourceContext is ready. | 103 // that the ResourceContext is ready. |
104 static void EnsureResourceContextInitialized(BrowserContext* browser_context); | 104 static void EnsureResourceContextInitialized(BrowserContext* browser_context); |
105 | 105 |
106 // Tells the HTML5 objects on this context to persist their session state | 106 // Tells the HTML5 objects on this context to persist their session state |
107 // across the next restart. | 107 // across the next restart. |
108 static void SaveSessionState(BrowserContext* browser_context); | 108 static void SaveSessionState(BrowserContext* browser_context); |
109 | 109 |
110 virtual ~BrowserContext(); | 110 ~BrowserContext() override; |
111 | 111 |
112 // Returns the path of the directory where this context's data is stored. | 112 // Returns the path of the directory where this context's data is stored. |
113 virtual base::FilePath GetPath() const = 0; | 113 virtual base::FilePath GetPath() const = 0; |
114 | 114 |
115 // Return whether this context is incognito. Default is false. | 115 // Return whether this context is incognito. Default is false. |
116 virtual bool IsOffTheRecord() const = 0; | 116 virtual bool IsOffTheRecord() const = 0; |
117 | 117 |
118 // Returns the request context information associated with this context. Call | 118 // Returns the request context information associated with this context. Call |
119 // this only on the UI thread, since it can send notifications that should | 119 // this only on the UI thread, since it can send notifications that should |
120 // happen on the UI thread. | 120 // happen on the UI thread. |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 virtual PushMessagingService* GetPushMessagingService() = 0; | 162 virtual PushMessagingService* GetPushMessagingService() = 0; |
163 | 163 |
164 // Returns the SSL host state decisions for this context. The context may | 164 // Returns the SSL host state decisions for this context. The context may |
165 // return NULL, implementing the default exception storage strategy. | 165 // return NULL, implementing the default exception storage strategy. |
166 virtual SSLHostStateDelegate* GetSSLHostStateDelegate() = 0; | 166 virtual SSLHostStateDelegate* GetSSLHostStateDelegate() = 0; |
167 }; | 167 }; |
168 | 168 |
169 } // namespace content | 169 } // namespace content |
170 | 170 |
171 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_CONTEXT_H_ | 171 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_CONTEXT_H_ |
OLD | NEW |