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 CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 virtual void OnAppsReordered() OVERRIDE {} | 103 virtual void OnAppsReordered() OVERRIDE {} |
104 virtual void OnAppInstalledToAppList( | 104 virtual void OnAppInstalledToAppList( |
105 const std::string& extension_id) OVERRIDE {} | 105 const std::string& extension_id) OVERRIDE {} |
106 virtual void OnShutdown() OVERRIDE {} | 106 virtual void OnShutdown() OVERRIDE {} |
107 | 107 |
108 // BrowserContextKeyedService | 108 // BrowserContextKeyedService |
109 virtual void Shutdown() OVERRIDE; | 109 virtual void Shutdown() OVERRIDE; |
110 | 110 |
111 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); | 111 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); |
112 | 112 |
| 113 // Clean up URLs from the activity log database. |
| 114 // If restrict_urls is empty then all URLs in the activity log database are |
| 115 // removed, otherwise only those in restrict_urls are removed. |
| 116 virtual void RemoveURLs(const std::vector<GURL>& restrict_urls); |
| 117 virtual void RemoveURLs(const std::set<GURL>& restrict_urls); |
| 118 virtual void RemoveURL(const GURL& url); |
| 119 |
113 private: | 120 private: |
114 friend class ActivityLogFactory; | 121 friend class ActivityLogFactory; |
115 friend class ActivityLogTest; | 122 friend class ActivityLogTest; |
116 friend class RenderViewActivityLogTest; | 123 friend class RenderViewActivityLogTest; |
117 | 124 |
118 explicit ActivityLog(Profile* profile); | 125 explicit ActivityLog(Profile* profile); |
119 virtual ~ActivityLog(); | 126 virtual ~ActivityLog(); |
120 | 127 |
121 // Delayed initialization of Install Tracker which waits until after the | 128 // Delayed initialization of Install Tracker which waits until after the |
122 // ExtensionSystem/ExtensionService are done with their own setup. | 129 // ExtensionSystem/ExtensionService are done with their own setup. |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
198 virtual content::BrowserContext* GetBrowserContextToUse( | 205 virtual content::BrowserContext* GetBrowserContextToUse( |
199 content::BrowserContext* context) const OVERRIDE; | 206 content::BrowserContext* context) const OVERRIDE; |
200 | 207 |
201 DISALLOW_COPY_AND_ASSIGN(ActivityLogFactory); | 208 DISALLOW_COPY_AND_ASSIGN(ActivityLogFactory); |
202 }; | 209 }; |
203 | 210 |
204 | 211 |
205 } // namespace extensions | 212 } // namespace extensions |
206 | 213 |
207 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_H_ | 214 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_H_ |
OLD | NEW |