| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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_ACTIONS_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_ACTIONS_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_ACTIONS_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_ACTIONS_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 std::string SerializePageUrl() const; | 116 std::string SerializePageUrl() const; |
| 117 void ParsePageUrl(const std::string& url); | 117 void ParsePageUrl(const std::string& url); |
| 118 std::string SerializeArgUrl() const; | 118 std::string SerializeArgUrl() const; |
| 119 void ParseArgUrl(const std::string& url); | 119 void ParseArgUrl(const std::string& url); |
| 120 | 120 |
| 121 // Number of merged records for this action. | 121 // Number of merged records for this action. |
| 122 int count() const { return count_; } | 122 int count() const { return count_; } |
| 123 void set_count(int count) { count_ = count; } | 123 void set_count(int count) { count_ = count; } |
| 124 | 124 |
| 125 // Flatten the activity's type-specific fields into an ExtensionActivity. | 125 // Flatten the activity's type-specific fields into an ExtensionActivity. |
| 126 scoped_ptr<api::activity_log_private::ExtensionActivity> | 126 api::activity_log_private::ExtensionActivity ConvertToExtensionActivity(); |
| 127 ConvertToExtensionActivity(); | |
| 128 | 127 |
| 129 // Print an action as a regular string for debugging purposes. | 128 // Print an action as a regular string for debugging purposes. |
| 130 virtual std::string PrintForDebug() const; | 129 virtual std::string PrintForDebug() const; |
| 131 | 130 |
| 132 protected: | 131 protected: |
| 133 virtual ~Action(); | 132 virtual ~Action(); |
| 134 | 133 |
| 135 private: | 134 private: |
| 136 friend class base::RefCountedThreadSafe<Action>; | 135 friend class base::RefCountedThreadSafe<Action>; |
| 137 | 136 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 165 // comparisons. | 164 // comparisons. |
| 166 struct ActionComparatorExcludingTimeAndActionId { | 165 struct ActionComparatorExcludingTimeAndActionId { |
| 167 // Evaluates the comparison lhs < rhs. | 166 // Evaluates the comparison lhs < rhs. |
| 168 bool operator()(const scoped_refptr<Action>& lhs, | 167 bool operator()(const scoped_refptr<Action>& lhs, |
| 169 const scoped_refptr<Action>& rhs) const; | 168 const scoped_refptr<Action>& rhs) const; |
| 170 }; | 169 }; |
| 171 | 170 |
| 172 } // namespace extensions | 171 } // namespace extensions |
| 173 | 172 |
| 174 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_ACTIONS_H_ | 173 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_ACTIVITY_ACTIONS_H_ |
| OLD | NEW |