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_RESOURCE_CONTEXT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_RESOURCE_CONTEXT_H_ |
6 #define CONTENT_PUBLIC_BROWSER_RESOURCE_CONTEXT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_RESOURCE_CONTEXT_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/scoped_ptr.h" | |
9 #include "base/supports_user_data.h" | 10 #include "base/supports_user_data.h" |
10 #include "build/build_config.h" | 11 #include "build/build_config.h" |
11 #include "content/common/content_export.h" | 12 #include "content/common/content_export.h" |
12 | 13 |
13 class GURL; | 14 class GURL; |
14 | 15 |
15 namespace appcache { | 16 namespace appcache { |
16 class AppCacheService; | 17 class AppCacheService; |
17 } | 18 } |
18 | 19 |
19 namespace net { | 20 namespace net { |
21 class ClientCertStore; | |
20 class HostResolver; | 22 class HostResolver; |
21 class URLRequestContext; | 23 class URLRequestContext; |
22 } | 24 } |
23 | 25 |
24 namespace content { | 26 namespace content { |
25 | 27 |
26 // ResourceContext contains the relevant context information required for | 28 // ResourceContext contains the relevant context information required for |
27 // resource loading. It lives on the IO thread, although it is constructed on | 29 // resource loading. It lives on the IO thread, although it is constructed on |
28 // the UI thread. It must be destructed on the IO thread. | 30 // the UI thread. It must be destructed on the IO thread. |
29 class CONTENT_EXPORT ResourceContext : public base::SupportsUserData { | 31 class CONTENT_EXPORT ResourceContext : public base::SupportsUserData { |
(...skipping 13 matching lines...) Expand all Loading... | |
43 | 45 |
44 // Returns true if microphone access is allowed for |origin|. Used to | 46 // Returns true if microphone access is allowed for |origin|. Used to |
45 // determine what level of authorization is given to |origin| to access | 47 // determine what level of authorization is given to |origin| to access |
46 // resource metadata. | 48 // resource metadata. |
47 virtual bool AllowMicAccess(const GURL& origin) = 0; | 49 virtual bool AllowMicAccess(const GURL& origin) = 0; |
48 | 50 |
49 // Returns true if web camera access is allowed for |origin|. Used to | 51 // Returns true if web camera access is allowed for |origin|. Used to |
50 // determine what level of authorization is given to |origin| to access | 52 // determine what level of authorization is given to |origin| to access |
51 // resource metadata. | 53 // resource metadata. |
52 virtual bool AllowCameraAccess(const GURL& origin) = 0; | 54 virtual bool AllowCameraAccess(const GURL& origin) = 0; |
55 | |
56 // Get platform ClientCertStore. May return NULL. | |
57 virtual scoped_ptr<net::ClientCertStore> GetClientCertStore() = 0; | |
jam
2013/10/25 15:33:58
This isn't your fault, but this interface doesn't
mattm
2013/10/25 19:34:36
Oh yeah, that's much nicer. Done.
| |
53 }; | 58 }; |
54 | 59 |
55 } // namespace content | 60 } // namespace content |
56 | 61 |
57 #endif // CONTENT_PUBLIC_BROWSER_RESOURCE_CONTEXT_H_ | 62 #endif // CONTENT_PUBLIC_BROWSER_RESOURCE_CONTEXT_H_ |
OLD | NEW |