Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(975)

Unified Diff: chrome/browser/extensions/activity_log/counting_policy.h

Issue 21646004: Compressed activity log database storage (Closed) Base URL: http://git.chromium.org/chromium/src.git@refactor-cleanups
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/activity_log/counting_policy.h
diff --git a/chrome/browser/extensions/activity_log/counting_policy.h b/chrome/browser/extensions/activity_log/counting_policy.h
new file mode 100644
index 0000000000000000000000000000000000000000..2fc8c2e566f2068fd37c048b9078c5ccb27132aa
--- /dev/null
+++ b/chrome/browser/extensions/activity_log/counting_policy.h
@@ -0,0 +1,40 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_
+#define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_
+
+#include <string>
+
+#include "base/containers/hash_tables.h"
+#include "chrome/browser/extensions/activity_log/stream_noargs_ui_policy.h"
+
+namespace extensions {
+
+// A policy for logging the stream of actions, but without arguments.
+class CountingPolicy : public StreamWithoutArgsUIPolicy {
felt 2013/08/02 16:36:28 Is there a reason to keep the StreamWithoutArgsUIP
mvrable 2013/08/02 17:16:58 Probably not. I need to do some cleanup work here
+ public:
+ explicit CountingPolicy(Profile* profile);
+ virtual ~CountingPolicy();
+
+ /*virtual void ProcessAction(scoped_refptr<Action> action) OVERRIDE;*/
+
+ static const char* kTableName;
+ static const char* kTableContentFields[];
+ static const char* kTableFieldTypes[];
+
+ protected:
+ // Implementing ActivityDatabase::Delegate.
+ virtual bool InitDatabase(sql::Connection* db) OVERRIDE;
+ virtual bool FlushDatabase(sql::Connection* db) OVERRIDE;
+
+ private:
+ /*void QueueAction(scoped_refptr<Action> action);*/
+
+ /*base::hash_set<std::string> arg_whitelist_api_;*/
+};
+
+} // namespace extensions
+
+#endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_COUNTING_POLICY_H_

Powered by Google App Engine
This is Rietveld 408576698