OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_POLICY_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_POLICY_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_POLICY_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_POLICY_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 virtual void ReadFilteredData( | 170 virtual void ReadFilteredData( |
171 const std::string& extension_id, | 171 const std::string& extension_id, |
172 const Action::ActionType type, | 172 const Action::ActionType type, |
173 const std::string& api_name, | 173 const std::string& api_name, |
174 const std::string& page_url, | 174 const std::string& page_url, |
175 const std::string& arg_url, | 175 const std::string& arg_url, |
176 const int days_ago, | 176 const int days_ago, |
177 const base::Callback | 177 const base::Callback |
178 <void(scoped_ptr<Action::ActionVector>)>& callback) = 0; | 178 <void(scoped_ptr<Action::ActionVector>)>& callback) = 0; |
179 | 179 |
| 180 // Remove actions (rows) which IDs are in the action_ids array. |
| 181 virtual void RemoveActions(const std::vector<int64>& action_ids) = 0; |
| 182 |
180 // Clean the relevant URL data. The cleaning may need to be different for | 183 // Clean the relevant URL data. The cleaning may need to be different for |
181 // different policies. If restrict_urls is empty then all URLs are removed. | 184 // different policies. If restrict_urls is empty then all URLs are removed. |
182 virtual void RemoveURLs(const std::vector<GURL>& restrict_urls) = 0; | 185 virtual void RemoveURLs(const std::vector<GURL>& restrict_urls) = 0; |
183 | 186 |
184 // Remove all rows relating to a given extension. | 187 // Remove all rows relating to a given extension. |
185 virtual void RemoveExtensionData(const std::string& extension_id) = 0; | 188 virtual void RemoveExtensionData(const std::string& extension_id) = 0; |
186 | 189 |
187 // Deletes everything in the database. | 190 // Deletes everything in the database. |
188 virtual void DeleteDatabase() = 0; | 191 virtual void DeleteDatabase() = 0; |
189 | 192 |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
226 private: | 229 private: |
227 // See the comments for the ActivityDatabase class for a discussion of how | 230 // See the comments for the ActivityDatabase class for a discussion of how |
228 // database cleanup runs. | 231 // database cleanup runs. |
229 ActivityDatabase* db_; | 232 ActivityDatabase* db_; |
230 base::FilePath database_path_; | 233 base::FilePath database_path_; |
231 }; | 234 }; |
232 | 235 |
233 } // namespace extensions | 236 } // namespace extensions |
234 | 237 |
235 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_POLICY_H_ | 238 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_LOG_POLICY_H_ |
OLD | NEW |