OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 EXTENSIONS_BROWSER_CONTENT_VERIFIER_H_ | 5 #ifndef EXTENSIONS_BROWSER_CONTENT_VERIFIER_H_ |
6 #define EXTENSIONS_BROWSER_CONTENT_VERIFIER_H_ | 6 #define EXTENSIONS_BROWSER_CONTENT_VERIFIER_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 const base::FilePath& extension_root, | 49 const base::FilePath& extension_root, |
50 const base::FilePath& relative_path); | 50 const base::FilePath& relative_path); |
51 | 51 |
52 // Called (typically by a verification job) to indicate that verification | 52 // Called (typically by a verification job) to indicate that verification |
53 // failed while reading some file in |extension_id|. | 53 // failed while reading some file in |extension_id|. |
54 void VerifyFailed(const std::string& extension_id, | 54 void VerifyFailed(const std::string& extension_id, |
55 ContentVerifyJob::FailureReason reason); | 55 ContentVerifyJob::FailureReason reason); |
56 | 56 |
57 // ExtensionRegistryObserver interface | 57 // ExtensionRegistryObserver interface |
58 virtual void OnExtensionLoaded(content::BrowserContext* browser_context, | 58 virtual void OnExtensionLoaded(content::BrowserContext* browser_context, |
59 const Extension* extension) OVERRIDE; | 59 const Extension* extension) override; |
60 virtual void OnExtensionUnloaded( | 60 virtual void OnExtensionUnloaded( |
61 content::BrowserContext* browser_context, | 61 content::BrowserContext* browser_context, |
62 const Extension* extension, | 62 const Extension* extension, |
63 UnloadedExtensionInfo::Reason reason) OVERRIDE; | 63 UnloadedExtensionInfo::Reason reason) override; |
64 | 64 |
65 private: | 65 private: |
66 DISALLOW_COPY_AND_ASSIGN(ContentVerifier); | 66 DISALLOW_COPY_AND_ASSIGN(ContentVerifier); |
67 | 67 |
68 friend class base::RefCountedThreadSafe<ContentVerifier>; | 68 friend class base::RefCountedThreadSafe<ContentVerifier>; |
69 virtual ~ContentVerifier(); | 69 virtual ~ContentVerifier(); |
70 | 70 |
71 void OnFetchComplete(const std::string& extension_id, | 71 void OnFetchComplete(const std::string& extension_id, |
72 bool success, | 72 bool success, |
73 bool was_force_check, | 73 bool was_force_check, |
(...skipping 23 matching lines...) Expand all Loading... |
97 // For observing the ExtensionRegistry. | 97 // For observing the ExtensionRegistry. |
98 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> observer_; | 98 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> observer_; |
99 | 99 |
100 // Data that should only be used on the IO thread. | 100 // Data that should only be used on the IO thread. |
101 scoped_refptr<ContentVerifierIOData> io_data_; | 101 scoped_refptr<ContentVerifierIOData> io_data_; |
102 }; | 102 }; |
103 | 103 |
104 } // namespace extensions | 104 } // namespace extensions |
105 | 105 |
106 #endif // EXTENSIONS_BROWSER_CONTENT_VERIFIER_H_ | 106 #endif // EXTENSIONS_BROWSER_CONTENT_VERIFIER_H_ |
OLD | NEW |