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_COUNTING_POLICY_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/containers/hash_tables.h" | 10 #include "base/containers/hash_tables.h" |
| 11 #include "base/gtest_prod_util.h" |
11 #include "chrome/browser/extensions/activity_log/activity_database.h" | 12 #include "chrome/browser/extensions/activity_log/activity_database.h" |
12 #include "chrome/browser/extensions/activity_log/activity_log_policy.h" | 13 #include "chrome/browser/extensions/activity_log/activity_log_policy.h" |
13 #include "chrome/browser/extensions/activity_log/database_string_table.h" | 14 #include "chrome/browser/extensions/activity_log/database_string_table.h" |
14 | 15 |
15 namespace extensions { | 16 namespace extensions { |
16 | 17 |
17 // A policy for logging the stream of actions, but with most arguments stripped | 18 // A policy for logging the stream of actions, but with most arguments stripped |
18 // out (to improve privacy and reduce database size) and with multiple | 19 // out (to improve privacy and reduce database size) and with multiple |
19 // identical rows combined together using a count column to track the total | 20 // identical rows combined together using a count column to track the total |
20 // number of repetitions. Identical rows within the same day are merged, but | 21 // number of repetitions. Identical rows within the same day are merged, but |
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 | 149 |
149 friend class CountingPolicyTest; | 150 friend class CountingPolicyTest; |
150 FRIEND_TEST_ALL_PREFIXES(CountingPolicyTest, EarlyFlush); | 151 FRIEND_TEST_ALL_PREFIXES(CountingPolicyTest, EarlyFlush); |
151 FRIEND_TEST_ALL_PREFIXES(CountingPolicyTest, MergingAndExpiring); | 152 FRIEND_TEST_ALL_PREFIXES(CountingPolicyTest, MergingAndExpiring); |
152 FRIEND_TEST_ALL_PREFIXES(CountingPolicyTest, StringTableCleaning); | 153 FRIEND_TEST_ALL_PREFIXES(CountingPolicyTest, StringTableCleaning); |
153 }; | 154 }; |
154 | 155 |
155 } // namespace extensions | 156 } // namespace extensions |
156 | 157 |
157 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_ | 158 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_ |
OLD | NEW |